Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var StartBrokerServer = &command.AddCmd{ GeneratePID: false, LockProcess: false, ProcessName: "broker", EnableStartupServices: true, StartupCoreServices: command.StartupCoreServices{ BrokerClients: true, }, OnGetProcessName: func(cmd *command.AddCmd) string { brokerName := getInstanceName(cmd.Args) return cmd.ProcessName + "_" + brokerName }, Cmd: "broker:start", Name: "Start - Broker Server", OnExecute: func(cmd *command.AddCmd) { brokerName := getInstanceName(cmd.Args) brk, err := broker.GetBroker(_context.GetDefaultContext(), brokerName) if err != nil { log.Fatalln("failed to generate broker...", err) } err = brk.Start() if err != nil { log.Fatalln("failed to start broker...", err) } for { time.Sleep(time.Second) } }, OnCreate: func(cmd *command.AddCmd) { cmd.Command.Args = cobra.MaximumNArgs(1) }, }
View Source
var StopBrokerServer = &command.AddCmd{ OnExecute: func(cmd *command.AddCmd) { cmd.StopProcess() }, OnGetProcessName: func(cmd *command.AddCmd) string { brokerName := getInstanceName(cmd.Args) return cmd.ProcessName + "_" + brokerName }, OnCreate: func(cmd *command.AddCmd) { cmd.Command.Args = cobra.MaximumNArgs(1) }, ProcessName: "broker", Cmd: "broker:stop", Name: "Stop - Broker Server", }
Functions ¶
This section is empty.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.