Versions in this module Expand all Collapse all v0 v0.3.0 Aug 19, 2024 v0.2.0 Aug 19, 2024 v0.1.0 Dec 19, 2023 Changes in this version + const CLIVersion + const KVStoreClientIDLen + const SelectAnyEndpoints + const SelectDiscoveredEndpoints + const SelectSuppliedEndpoints + func ExecuteStandalone(cfg Config) error + func RegisterClientFactory(name string, factory ClientFactory) error + func Run(cli *CLIConfig) + type AggregateStats struct + AvgDataRate float64 + AvgTxRate float64 + TotalBytes int64 + TotalTimeSeconds float64 + TotalTxs int + func (s *AggregateStats) Compute() + func (s *AggregateStats) String() string + type CLIConfig struct + AppLongDesc string + AppName string + AppShortDesc string + DefaultClientFactory string + type ChannelStatus struct + ID byte + Priority JSONStrInt + RecentlySent JSONStrInt64 + SendQueueCapacity JSONStrInt + SendQueueSize JSONStrInt + type Client interface + GenerateTx func() ([]byte, error) + type ClientFactory interface + NewClient func(cfg Config) (Client, error) + ValidateConfig func(cfg Config) error + type Config struct + BroadcastTxMethod string + ClientFactory string + Connections int + Count int + EndpointSelectMethod string + Endpoints []string + ExpectPeers int + MaxEndpoints int + MinConnectivity int + NoTrapInterrupts bool + PeerConnectTimeout int + Rate int + SendPeriod int + Size int + StatsOutputFile string + Time int + func (c Config) MaxTxsPerEndpoint() uint64 + func (c Config) ToJSON() string + func (c Config) Validate() error + type ConnectionStatus struct + Channels []ChannelStatus + Duration JSONDuration + RecvMonitor FlowStatus + SendMonitor FlowStatus + type Coordinator struct + func NewCoordinator(cfg *Config, coordCfg *CoordinatorConfig) *Coordinator + func (c *Coordinator) ReceiveWorkerUpdate(msg workerMsg) + func (c *Coordinator) RegisterRemoteWorker(rw *remoteWorker) error + func (c *Coordinator) Run() error + func (c *Coordinator) UnregisterRemoteWorker(id string, err error) + type CoordinatorConfig struct + BindAddr string + ExpectWorkers int + LoadTestID int + ShutdownWait int + WorkerConnectTimeout int + func (c CoordinatorConfig) ToJSON() string + func (c CoordinatorConfig) Validate() error + type DefaultNodeInfo struct + Channels HexBytes + DefaultNodeID string + ListenAddr string + Moniker string + Network string + Other DefaultNodeInfoOther + ProtocolVersion ProtocolVersion + Version string + type DefaultNodeInfoOther struct + RPCAddress string + TxIndex string + type FlowStatus struct + Active bool + AvgRate JSONStrInt64 + Bytes JSONStrInt64 + BytesRem JSONStrInt64 + CurRate JSONStrInt64 + Duration JSONDuration + Idle JSONDuration + InstRate JSONStrInt64 + PeakRate JSONStrInt64 + Progress Percent + Samples JSONStrInt64 + Start time.Time + TimeRem JSONDuration + type HexBytes []byte + func (bz *HexBytes) UnmarshalJSON(data []byte) error + func (bz HexBytes) MarshalJSON() ([]byte, error) + type JSONDuration time.Duration + func (i *JSONDuration) UnmarshalJSON(data []byte) error + type JSONStrInt int + func (i *JSONStrInt) UnmarshalJSON(data []byte) error + type JSONStrInt64 int64 + func (i *JSONStrInt64) UnmarshalJSON(data []byte) error + type JSONStrUint64 uint64 + func (i *JSONStrUint64) UnmarshalJSON(data []byte) error + type KVStoreClient struct + func (c *KVStoreClient) GenerateTx() ([]byte, error) + type KVStoreClientFactory struct + func NewKVStoreClientFactory() *KVStoreClientFactory + func (f *KVStoreClientFactory) NewClient(cfg Config) (Client, error) + func (f *KVStoreClientFactory) ValidateConfig(cfg Config) error + type NetInfo struct + Listeners []string + Listening bool + NPeers JSONStrInt + Peers []Peer + type Peer struct + ConnectionStatus ConnectionStatus + IsOutbound bool + NodeInfo DefaultNodeInfo + RemoteIP string + type Percent uint32 + type ProtocolVersion struct + App JSONStrUint64 + Block JSONStrUint64 + P2P JSONStrUint64 + type RPCError struct + Code int + Data string + Message string + type RPCRequest struct + ID int + JSONRPC string + Method string + Params json.RawMessage + type RPCResponse struct + Error *RPCError + ID int + JSONRPC string + Result json.RawMessage + type Transactor struct + func NewTransactor(remoteAddr string, config *Config) (*Transactor, error) + func (t *Transactor) Cancel() + func (t *Transactor) GetTxBytes() int64 + func (t *Transactor) GetTxCount() int + func (t *Transactor) GetTxRate() float64 + func (t *Transactor) SetProgressCallback(id int, interval time.Duration, callback func(int, int, int64)) + func (t *Transactor) Start() + func (t *Transactor) Wait() error + type TransactorGroup struct + func NewTransactorGroup() *TransactorGroup + func (g *TransactorGroup) Add(remoteAddr string, config *Config) error + func (g *TransactorGroup) AddAll(cfg *Config) error + func (g *TransactorGroup) Cancel() + func (g *TransactorGroup) SetLogger(logger logging.Logger) + func (g *TransactorGroup) SetProgressCallback(interval time.Duration, callback func(*TransactorGroup, int, int64)) + func (g *TransactorGroup) Start() + func (g *TransactorGroup) Wait() error + func (g *TransactorGroup) WriteAggregateStats(filename string) error + type Worker struct + func NewWorker(cfg *WorkerConfig) (*Worker, error) + func (w *Worker) Config() Config + func (w *Worker) ID() string + func (w *Worker) Run() error + type WorkerConfig struct + CoordAddr string + CoordConnectTimeout int + ID string + func (c WorkerConfig) ToJSON() string + func (c WorkerConfig) Validate() error