You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Open-IM-Server/pkg/common/cmd/msg_transfer.go

26 lines
497 B

2 years ago
package cmd
import (
2 years ago
"github.com/OpenIMSDK/Open-IM-Server/internal/msgtransfer"
2 years ago
"github.com/spf13/cobra"
)
type MsgTransferCmd struct {
*RootCmd
}
func NewMsgTransferCmd() MsgTransferCmd {
2 years ago
return MsgTransferCmd{NewRootCmd("msgTransfer")}
2 years ago
}
func (m *MsgTransferCmd) addRunE() {
m.Command.RunE = func(cmd *cobra.Command, args []string) error {
return msgtransfer.StartTransfer(m.getPrometheusPortFlag(cmd))
}
}
func (m *MsgTransferCmd) Exec() error {
m.addRunE()
return m.Execute()
}