Files
open-im-server/tools/seq/main.go
T

27 lines
511 B
Go
Raw Normal View History

2024-07-16 10:46:21 +08:00
package main
import (
"flag"
"fmt"
"os"
2024-07-16 10:46:21 +08:00
"time"
"github.com/openimsdk/open-im-server/v3/tools/seq/internal"
2024-07-16 10:46:21 +08:00
)
func main() {
var (
config string
second int
)
flag.StringVar(&config, "c", "", "config directory")
2024-07-16 10:46:21 +08:00
flag.IntVar(&second, "sec", 3600*24, "delayed deletion of the original seq key after conversion")
flag.Parse()
if err := internal.Main(config, time.Duration(second)*time.Second); err != nil {
fmt.Println("seq task", err)
os.Exit(1)
return
2024-07-16 10:46:21 +08:00
}
fmt.Println("seq task success!")
}