commands

package
v1.0.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 26, 2020 License: MIT Imports: 27 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ClientIdentifier       = "cosd"
	TesterClientIdentifier = "testcosd"
)

Variables

View Source
var ClearCmd = func() *cobra.Command {
	cmd := &cobra.Command{
		Use:   "clear",
		Short: "Clear all tester data",
		Run:   clear,
	}
	return cmd
}
View Source
var InitCmd = func() *cobra.Command {
	cmd := &cobra.Command{
		Use:   "init count(default 4)",
		Short: "Initialize configuration files for multi cosd",
		Run:   initConf,
	}
	cmd.Flags().StringVarP(&chainName, "chain", "c", "", "chain name [main/test/dev], default is main")
	return cmd
}
View Source
var StartCmd = func() *cobra.Command {
	cmd := &cobra.Command{
		Use:   "start cosd-path count(default 3)",
		Short: "start multi cosd node",
		Run:   startNode,
	}
	return cmd
}
View Source
var StopCmd = func() *cobra.Command {
	cmd := &cobra.Command{
		Use:   "stop",
		Short: "force kill all cosd process ",
		Run:   stop,
	}
	return cmd
}
View Source
var TestCmd = func() *cobra.Command {
	cmd := &cobra.Command{
		Use:   "test count",
		Short: "start cosd nodes",
		Run:   startNodes,
	}
	cmd.Flags().IntVarP(&latency, "latency", "l", 1500, "test count -l 1500 (in ms)")
	cmd.Flags().BoolVarP(&shut, "random_shutdown", "s", false, "")
	cmd.Flags().BoolVarP(&testSync, "test_sync", "e", false, "")
	cmd.Flags().BoolVarP(&malicious, "malicious_node", "m", false, "")
	return cmd
}
View Source
var VERSION = "defaultVersion"

Functions

func RegisterService added in v1.0.2

func RegisterService(app *node.Node, cfg node.Config)

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL