WoopChain Node Installation
WoopChain Configuration.
WoopChain CLI Commands
WoopChain CLI commands and command flags list.
import Tabs from '@theme/Tabs'; import TabItem from '@theme/TabItem';
This section details the present commands, command flags in the WoopChain, and how they're used.
JSON output support. The --json flag is supported on some commands. This flag instructs the command
to print the output in JSON format
Startup Commands
Command | Description |
---|---|
server | The default command that starts the blockchain client, by bootstrapping all modules together |
genesis | Generates a genesis.json file, which is used to set a predefined chain state before starting the client. The structure of the genesis file is described below |
genesis predeploy | Predeploys a Smart Contract for fresh networks |
Server Flags
| All server flags | |------------------------------------------------|--------------------------------------------------|
| seal | data-dir | | jsonrpc | json-rpc-block-range-limit | grpc | libp2p | | prometheus | block-gas-target |
| max-peers | max-inbound-peers | | max-outbound-peers | max-enqueued | | log-level | log-to | | chain | join |
| nat | dns | | price-limit | max-slots | config | | secrets-config | dev | | dev-interval | no-discover | restore |
| block-time | access-control-allow-origins |
seal
server [--seal SHOULD_SEAL]
server --seal
Sets the flag indicating that the client should seal blocks. Default: true.
data-dir
server [--data-dir DATA_DIRECTORY]
data-dir
server --data-dir ./example-dir
Used to specify the data directory used for storing WoopChain client data. Default: ./test-chain.
jsonrpc
server [--jsonrpc JSONRPC_ADDRESS]
server --jsonrpc 127.0.0.1:10000
Sets the address and port for the JSON-RPC service address:port.
If only port is defined :10001 it will bind to all interfaces 0.0.0.0:10001.
If omitted the service will bind to the default address:port.
Default address: 0.0.0.0:8545.
json-rpc-block-range-limit
server [--json-rpc-block-range-limit BLOCK_RANGE]
server --json-rpc-block-range-limit 1500
Sets the maximum block range to be considered when executing json-rpc requests that include fromBlock/toBlock values (e.g. eth_getLogs). Default:1000.
json-rpc-batch-request-limit
server [--json-rpc-batch-request-limit MAX_LENGTH]
server --json-rpc-batch-request-limit 50
Sets the maximum length to be considered when handling json-rpc batch requests. Default: 20.
grpc
server [--grpc-address GRPC_ADDRESS]
server --grpc-address 127.0.0.1:10001
Sets the address and port for the gRPC service address:port. Default address: 127.0.0.1:9632.
libp2p
server [--libp2p LIBP2P_ADDRESS]
server --libp2p 127.0.0.1:10002
Sets the address and port for the libp2p service address:port. Default address: 127.0.0.1:1478.
prometheus
server [--prometheus PROMETHEUS_ADDRESS]
server --prometheus 127.0.0.1:10004
Sets the address and port for the prometheus server address:port.
If only port is defined :5001 the service will bind to all interfaces 0.0.0.0:5001.
If omitted the service will not be started.
block-gas-target
server [--block-gas-target BLOCK_GAS_TARGET]
server --block-gas-target 10000000
Sets the target block gas limit for the chain. Default (not enforced): 0.
max-peers
server [--max-peers PEER_COUNT]
server --max-peers 40
Sets the client's maximum peer count. Default: 40.
Peer limit should be specified either by using max-peers or max-inbound/outbound-peers flag.
max-inbound-peers
server [--max-inbound-peers PEER_COUNT]
server --max-inbound-peers 32
Sets the client's maximum inbound peer count. If max-peersis set, max-inbound-peer limit is calculated using the following formula.
max-inbound-peer = InboundRatio * max-peers, where InboundRatio is 0.8.
max-outbound-peers
server [--max-outbound-peers PEER_COUNT]
server --max-outbound-peers 8
Sets the client's maximum outbound peer count. If max-peersis set, max-outbound-peer count is calculated using the following formula.
max-outbound-peer = OutboundRatio * max-peers, where OutboundRatio is 0.2.
max-enqueued
server [--max-enqueued ENQUEUED_TRANSACTIONS]
server --max-enqueued 210
Sets the maximum number of enqueued transactions per account. Default: 128
log-level
server [--log-level LOG_LEVEL]
server --log-level DEBUG
Sets the log level for console output. Default: INFO.
log-to
log-to
server --log-to node.log
Defines log file name that will hold all log output from the server command. By default, all server logs will be outputted to console (stdout), but if the flag is set, there will be no output to the console when running server command.
chain
server [--chain GENESIS_FILE]
server --chain /home/ubuntu/genesis.json
Specifies the genesis file used for starting the chain. Default: ./genesis.json.
join
server [--join JOIN_ADDRESS]
server --join /ip4/127.0.0.1/tcp/10001/p2p/16Uiu2HAmJxxH1tScDX2rLGSU9exnuvZKNM9SoK3v315azp68DLPW
Specifies the address of the peer that should be joined.
nat
server [--nat NAT_ADDRESS]
server --nat 192.0.2.1
Sets the external IP address without the port, as it can be seen by peers.
dns
server [--dns DNS_ADDRESS]
server --dns dns4/example.io
Sets the host DNS address. This can be used to advertise an external DNS. Supports.dns,dns4,dns6
price-limit
server [--price-limit PRICE_LIMIT]
server --price-limit 10000
Sets minimum gas price limit to enforce for acceptance into the pool. Default: 1
max-slots
server [--max-slots MAX_SLOTS]
server --max-slots 1024
Sets maximum slots in the pool. Default: 4096
config
server [--config CLI_CONFIG_PATH]
server --config ./myConfig.json
Specifies the path to the CLI config. Supports .json
secrets-config
server [--secrets-config SECRETS_CONFIG]
server --secrets-config ./secretsManagerConfig.json
Sets the path to the SecretsManager config file. Used for Hashicorp Vault, AWS SSM and GCP Secrets Manager. If omitted, the local FS secrets manager is used.
dev
server [--dev DEV_MODE]
server --dev
Sets the client to dev mode. Default: false
dev-interval
server [--dev-interval DEV_INTERVAL]
server --dev-interval 20
Sets the client's dev notification interval in seconds. Default: 0
no-discover
server [--no-discover NO_DISCOVER]
server --no-discover
Prevents the client from discovering other peers. Default: false
restore
server [--restore RESTORE]
server --restore backup.dat
Restore blocks from the specified archive file
block-time
server [--block-time BLOCK_TIME]
server --block-time 1000
Sets block production time in seconds. Default: 0
access-control-allow-origins
server [--access-control-allow-origins ACCESS_CONTROL_ALLOW_ORIGINS]
server --access-control-allow-origins "https://wikiwoop.com/docs/getting-started"
Sets the authorized domains to be able to share responses from JSON-RPC requests.
Add multiple flags
--access-control-allow-origins "https://example1.com"
--access-control-allow-origins "https://example2.com"
If omitted Access-Control-Allow-Origins header will be set to * and all domains will be authorized
genesis flags
| All genesis flags | |---------------------------------------|---------------------------------------------|
| dir | name | | pos | epoch-size | | premine | chainid | | ibft-validator-type |
ibft-validators-prefix-path | | ibft-validator | block-gas-limit |
| consensus | bootnode | | max-validator-count | min-validator-count |
dir
genesis [--dir DIRECTORY]
genesis --dir ./genesis.json
Sets the directory for the WoopChain genesis data. Default ./genesis.json
name
genesis [--name NAME]
genesis --name test-chain
Sets the name for the chain. Default: polyton-woop
pos
genesis [--pos IS_POS]
genesis --pos
Sets the flag indicating that the client should use Proof of Stake IBFT. Defaults to Proof of Authority if
flag is not provided or false
epoch-size
genesis [--epoch-size EPOCH_SIZE]
genesis --epoch-size 50
Sets the epoch size for the chain. Default 100000
premine
genesis [--premine ADDRESS:VALUE]
genesis --premine 0x3956E90e632AEbBF34DEB49b71c28A83Bc029862:1000000000000000000000
Sets the premined accounts and balances in the format address:amount he amount can be in either decimal or hex. Default premined balance: 0xD3C21BCECCEDA1000000 (1 million native currency tokens).
chainid
genesis [--chain-id CHAIN_ID]
genesis --chain-id 140
Sets the ID of the chain. Default: 100
ibft-validator-type
genesis [--ibft-validator-type IBFT_VALIDATOR_TYPE]
genesis --ibft-validator-type ecdsa
Specifies the validation mode of block headers. Possible values: [ecdsa, bls] Default: bls
ibft-validators-prefix-path
genesis [--ibft-validators-prefix-path IBFT_VALIDATORS_PREFIX_PATH]
genesis --ibft-validators-prefix-path test-chain-
Prefix path for validator folder directory. Needs to be present if the flag ibft-validator is omitted.
ibft-validator
genesis [--ibft-validator IBFT_VALIDATOR_LIST]
genesis --ibft-validator 0xC12bB5d97A35c6919aC77C709d55F6aa60436900
Sets passed addresses as IBFT validators. Needs to be present if the flag ibft-validators-prefix-path is omitted.
1 . If the network is running with ECDSA, the format is --ibft-validator [ADDRESS]
2 . If the network is running with BLS, the format is --ibft-validator [ADDRESS] : [BLS_PUBLIC_KEY]
block-gas-limit
genesis [--block-gas-limit BLOCK_GAS_LIMIT]
genesis --block-gas-limit 5000000
Refers to the maximum amount of gas used by all operations in a block. Default: 5242880 is omitted.
consensus
genesis [--consensus CONSENSUS_PROTOCOL]
genesis --consensus ibft
Sets consensus protocol. Default: pow is omitted.
bootnode
genesis [--bootnode BOOTNODE_URL]
genesis --bootnode /ip4/127.0.0.1/tcp/10001/p2p/16Uiu2HAmJxxH1tScDX2rLGSU9exnuvZKNM9SoK3v315azp68DLPW
Multiaddr URL for p2p discovery bootstrap. This flag can be used multiple times. Instead of an IP address, the DNS address of the bootnode can be provided.
max-validator-count
genesis [--max-validator-count MAX_VALIDATOR_COUNT]
genesis --max-validator-count 42
The maximum number of stakers able to join the validator set in a PoS consensus. This number cannot exceed the value of MAX_SAFE_INTEGER (2^53 - 2).
min-validator-count
genesis [--min-validator-count MIN_VALIDATOR_COUNT]
genesis --min-validator-count 4
The minimum number of stakers needed to join the validator set in a PoS consensus. This number cannot exceed the value of max-validator-count. Defaults to 1.
genesis predeploy flags
artifacts-path
genesis predeploy [--artifacts-path PATH_TO_ARTIFACTS]
genesis predeploy --artifacts-path ./ArtifactsData.json
Sets the path to the contract artifacts JSON that contains the abi bytecode and deployedBytecode
chain
genesis predeploy [--chain PATH_TO_GENESIS]
genesis predeploy --chain ./genesis.json
Sets the path to the genesis.json file that should be updated. Defaul ./genesis.json
constructor-args
genesis predeploy [--constructor-args CONSTRUCTOR_ARGUMENT]
genesis predeploy --constructor-args 123
Sets the Smart Contract constructor arguments, if any.
predeploy-address
genesis predeploy [--predeploy-address PREDEPLOY_ADDRESS]
genesis predeploy --predeploy-address 0x5555
Sets the address to predeploy to. Default 0x0000000000000000000000000000000000001100
Operator Commands
Peer Commands
Command | Description |
---|---|
peers add | Adds a new peer using their libp2p address |
peers list | Lists all the peers the client is connected to through libp2p |
peers status | Returns the status of a specific peer from the peers list, using the libp2p address |
peers add flags
addr
peers add --addr PEER_ADDRESS
peers add --addr /ip4/127.0.0.1/tcp/10001/p2p/16Uiu2HAmJxxH1tScDX2rLGSU9exnuvZKNM9SoK3v315azp68DLPW
Peer's libp2p address in the multiaddr format.
grpc-address
peers add [--grpc-address GRPC_ADDRESS]
peers add --grpc-address 127.0.0.1:10003
Address of the gRPC API. Default: 127.0.0.1:9632
peers list flags
grpc-address
peers list [--grpc-address GRPC_ADDRESS]
peers list --grpc-address 127.0.0.1:10003
Address of the gRPC API. Default: 127.0.0.1:9632
peers status flags
peer-id
peers status --peer-id PEER_ID
peers status --peer-id 16Uiu2HAmJxxH1tScDX2rLGSU9exnuvZKNM9SoK3v315azp68DLPW
Libp2p node ID of a specific peer within p2p network.
grpc-address
peers status [--grpc-address GRPC_ADDRESS]
peers status --grpc-address 127.0.0.1:10003
Address of the gRPC API. Default: 127.0.0.1:9632
IBFT Commands
Command | Description |
---|---|
ibft snapshot | Returns the IBFT snapshot |
ibft candidates | Queries the current set of proposed candidates, as well as candidates that have not been included yet |
ibft propose | Proposes a new candidate to be added/removed from the validator set |
ibft status | Returns the overall status of the IBFT client |
ibft switch | Add fork configurations into genesis.json file to switch IBFT type |
ibft quorum | Specifies the block number after which the optimal quorum size method will be used for reaching consensus |
ibft snapshot flags
number
ibft snapshot [--number BLOCK_NUMBER]
ibft snapshot --number 100
The block height (number) for the snapshot.
grpc-address
ibft snapshot [--grpc-address GRPC_ADDRESS]
ibft snapshot --grpc-address 127.0.0.1:10003
Address of the gRPC API. Default: 127.0.0.1:9632
ibft candidates flags
grpc-address
ibft candidates [--grpc-address GRPC_ADDRESS]
ibft candidates --grpc-address 127.0.0.1:10003
Address of the gRPC API. Default: 127.0.0.1:9632
ibft propose flags
vote
ibft propose --vote VOTE
ibft propose --vote auth
Proposes a change to the validator set. Possible values: [ auth, drop]
addr
ibft propose --addr WOOP_ADDRESS
ibft propose --addr 0x89205A3A3b2A69De6Dbf7f01ED13B2108B2c43e7
Address of the account to be voted for.
bls
ibft propose --bls BLS_PUBLIC_KEY
ibft propose --bls 0x9952735ca14734955e114a62e4c26a90bce42b4627a393418372968fa36e73a0ef8db68bba11ea967ff883e429b3bfdf
BLS Public Key of the account to be voted for, necessary only in BLS mode.
grpc-address
ibft propose --bls BLS_PUBLIC_KEY
ibft candidates --grpc-address 127.0.0.1:10003
Address of the gRPC API. Default: 127.0.0.1:9632
ibft status flags
grpc-address
ibft status [--grpc-address GRPC_ADDRESS]
ibft status --grpc-address 127.0.0.1:10003
Address of the gRPC API. Default: 127.0.0.1:9632
ibft switch flags
chain
ibft switch [--chain GENESIS_FILE]
ibft switch [--chain GENESIS_FILE]
Specifies the genesis file to update. Default: ./genesis.json
type
ibft switch [--type TYPE]
ibft switch --type PoS
Specifies the IBFT type to switch. Possible values: [PoA, PoS]
deployment
ibft switch [--deployment DEPLOYMENT]
ibft switch --deployment 100
Specifies the height of contract deployment. Only available with PoS.
from
ibft switch [--from FROM]
ibft switch --from 200
ibft-validator-type
ibft switch [--ibft-validator-type IBFT_VALIDATOR_TYPE]
ibft switch --ibft-validator-type ecdsa
Specifies the validation mode of block headers. Possible values: [ecdsa, bls] Default: bls
ibft-validators-prefix-path
ibft switch [--ibft-validators-prefix-path IBFT_VALIDATORS_PREFIX_PATH]
ibft switch --ibft-validators-prefix-path test-chain-
Prefix path for the directories of new validators. Needs to be present if the flag ibft-validator is omitted. Available only when the IBFT mode is PoA --pos flag is omitted.
ibft-validator
ibft switch [--ibft-validator IBFT_VALIDATOR_LIST]
ibft switch --ibft-validator 0xC12bB5d97A35c6919aC77C709d55F6aa60436900
Sets passed in addresses as IBFT validators used after the fork. Needs to be present
if the flag
bft-validators-prefix-path is omitted. Available only in PoA mode
1 . If the network is running with ECDSA, the format is --ibft-validator [ADDRESS]
2 . If the network is running with BLS, the format is --ibft-validator [ADDRESS] [BLS_PUBLIC_KEY]
max-validator-count
ibft switch [--max-validator-count MAX_VALIDATOR_COUNT]
ibft switch --max-validator-count 42
The maximum number of stakers able to join the validator set in a PoS consensus. This number cannot exceed the value of MAX_SAFE_INTEGER (2^53 - 2).
min-validator-count
ibft switch [--min-validator-count MIN_VALIDATOR_COUNT]
ibft switch --min-validator-count 4
The minimum number of stakers needed to join the validator set in a PoS consensus. This number cannot exceed the value of max-validator-count. Defaults to 1.
Specifies the beginning height of the fork.
ibft quorum flags
from
ibft quorum [--from your_quorum_switch_block_num]
ibft quorum --from 350
The height to switch the quorum calculation to QuorumOptimal, which uses the formula (2/3 * N), N being the number of validator nodes. Please note that this is for backwards compatibility, ie. only for chains that used a Quorum legacy calculation up to a certain block height.
chain
ibft quorum [--chain GENESIS_FILE]
ibft quorum --chain genesis.json
Specifies the genesis file to update. Default: ./genesis.json
Transaction Pool Commands
Command | Description |
---|---|
txpool status | Returns the number of transactions in the pool |
txpool subscribe | Subscribes for events in the transaction pool |
txpool status flags
grpc-address
txpool status [--grpc-address GRPC_ADDRESS]
txpool status --grpc-address 127.0.0.1:10003
Address of the gRPC API. Default 127.0.0.1:9632
txpool subscribe flags
grpc-address
txpool subscribe [--grpc-address GRPC_ADDRESS]
txpool subscribe --grpc-address 127.0.0.1:10003
Address of the gRPC API. Default 127.0.0.1:9632
promoted
txpool subscribe [--promoted LISTEN_PROMOTED]
txpool subscribe --promoted
Subscribes for promoted tx events in the TxPool.
dropped
txpool subscribe [--dropped LISTEN_DROPPED]
txpool subscribe --dropped
Subscribes for dropped tx events in the TxPool.
demoted
txpool subscribe [--demoted LISTEN_DEMOTED]
txpool subscribe --demoted
Subscribes for demoted tx events in the TxPool.
added
txpool subscribe [--added LISTEN_ADDED]
txpool subscribe --added
Subscribes for added tx events to the TxPool.
enqueued
txpool subscribe [--enqueued LISTEN_ENQUEUED]
txpool subscribe --enqueued
Subscribes for enqueued tx events in the account queues.
Blockchain commands
Command | Description |
---|---|
status | Returns the status of the client. The detailed response can be found below |
monitor | Subscribes to a blockchain event stream. The detailed response can be found below |
version | Returns the current version of the client |
status flags
grpc-address
status [--grpc-address GRPC_ADDRESS]
status --grpc-address 127.0.0.1:10003
Address of the gRPC API. Default: 127.0.0.1:9632
monitor flags
grpc-address
monitor [--grpc-address GRPC_ADDRESS]
monitor --grpc-address 127.0.0.1:10003
Address of the gRPC API. Default: 127.0.0.1:9632
version command
version
Displays release version, git branch, commit hash and build time.
Secrets Commands
Command | Description |
---|---|
secrets init | Initializes the private keys to the corresponding secrets manager |
secrets generate | Generates a secrets manager configuration file which can be parsed by the WoopChain |
secrets output | Prints the BLS public key address, validator public key address, and node id for reference |
secrets init flags
config
secrets init [--config SECRETS_CONFIG]
secrets init --config ./secretsManagerConfig.json
Sets the path to the SecretsManager config file. Used for Hashicorp Vault. If omitted, the local FS secrets manager is used.
data-dir
secrets init [--data-dir DATA_DIRECTORY]
secrets init --data-dir ./example-dir
Sets the directory for the WoopChain data if the local FS is used.
ecdsa
secrets init [--ecdsa FLAG]
secrets init --ecdsa=false
Sets the flag indicating whether to generate an ECDSA key. Default: true
network
secrets init [--network FLAG]
secrets init --network=false
Sets the flag indicating whether to generate a Libp2p Network key. Default: true
bls
secrets init [--bls FLAG]
secrets init --bls
Sets the flag indicating whether to generate a BLS key. Default: true
secrets generate flags
dir
secrets generate [--dir DATA_DIRECTORY]
secrets generate --dir ./example-dir
Sets the directory for the secrets manager configuration file Default: ./secretsManagerConfig.json
type
secrets generate [--type TYPE]
secrets generate --type hashicorp-vault
Specifies the type of the secrets manager [hashicorp-vault] Default: hashicorp-vault
token
secrets generate [--token TOKEN]
secrets generate --token s.zNrXa9zF9mgrdnClM7PZ19cu
Specifies the access token for the service
server-url
secrets generate [--server-url SERVER_URL]
secrets generate --server-url http://127.0.0.1:8200
Specifies the server URL for the service
name
secrets generate [--name NODE_NAME]
secrets generate --name node-1
Specifies the name of the node for on-service record keeping. Default: woop-node
namespace
secrets generate [--namespace NAMESPACE]
secrets generate --namespace my-namespace
Specifies the namespace used for the Hashicorp Vault secrets manager. Default: admin:
secrets output flags
bls
secrets output [--bls FLAG]
secrets output --bls
Sets the flag indicating whether to only output the BLS public key. Default: true
config
secrets output [--config SECRETS_CONFIG]
secrets output --config ./secretsManagerConfig.json
Sets the path to the SecretsManager config file. If omitted, the local FS secrets manager is used.
data-dir
secrets output [--data-dir DATA_DIRECTORY]
secrets output --data-dir ./example-dir
Sets the directory for the WoopChain data if the local FS is used.
node-id
secrets output [--node-id FLAG]
secrets output --node-id
Sets the flag indicating whether to only output the network node ID. Default: true
validator
validator
secrets output --validator
Sets the flag indicating whether to only output the validator address. Default: true
Responses
Status Response
The response object is defined using Protocol Buffers.
message ServerStatus {
int64 network = 1;
string genesis = 2;
Block current = 3;
string p2pAddr = 4;
message Block {
int64 number = 1;
string hash = 2;
}
}
Monitor Response
message BlockchainEvent {
// The "repeated" keyword indicates an array
repeated Header added = 1;
repeated Header removed = 2;
message Header {
int64 number = 1;
string hash = 2;
}
}
Utilities
whitelist commands
Command | Description |
---|---|
whitelist show | Displays whitelist information |
whitelist deployment | Updates the smart contract deployment whitelist |
whitelist show
whitelist show
Displays whitelist information.
whitelist show [--chain GENESIS_FILE]
whitelist show --chain genesis.json
Specifies the genesis file to update. Default: ./genesis.json.
whitelist deployment
chain
whitelist deployment [--chain GENESIS_FILE]
whitelist deployment --chain genesis.json
Specifies the genesis file to update. Default: ./genesis.json.
add
whitelist deployment [--add ADDRESS]
whitelist deployment --add 0x5383Cb489FaCa92365Bb6f9f1FB40bD032E6365d
Adds a new address to the contract deployment whitelist. Only the addresses in the contract deployment whitelist can deploy contracts. If empty, any address can execute the contract deployment
remove
whitelist deployment [--remove ADDRESS]
whitelist deployment --remove 0x5383Cb489FaCa92365Bb6f9f1FB40bD032E6365d
Removes an address from the contract deployment whitelist. Only the addresses in the contract deployment whitelist can deploy contracts. If empty, any address can execute the contract deployment
loadbot flags
tps
loadbot [--tps NUMBER_OF_TXNS_PER_SECOND]
loadbot --tps 2000
The number of transactions per second to send. Default: 100
mode
loadbot [--mode MODE]
loadbot --mode transfer
Sets the loadbot run mode [transfer, deploy] Default: transfer
chain-id
loadbot [--chain-id CHAIN_ID]
loadbot --chain-id 100
Sets the network chain ID for transactions. Default: 100
gas-price
loadbot [--gas-price GAS_PRICE]
loadbot --gas-price 10000
The gas price that should be used for the transactions. If omitted, the average gas price is fetched from the network.
gas-limit
loadbot [--gas-limit GAS_LIMIT]
loadbot --gas-limit 10000
The gas limit that should be used for the transactions. If omitted, the gas limit is estimated before starting the loadbot.
grpc-address
loadbot --grpc-address GRPC_ADDRESS
loadbot --grpc-address 127.0.0.1:9645
The GRPC endpoint used to send transactions
detailed
loadbot [--detailed DETAILED]
loadbot --detailed
Flag indicating if the error logs should be shown. Default: false
contract
loadbot [--contract CONTRACT_PATH]
loadbot --contract ./myContract.json
The path to the contract JSON artifact containing the bytecode. If omitted, a default contract is used.
sender
loadbot [--sender ADDRESS]
loadbot --sender 0x1010101010101010101010101010101010101020
Address of the sender account.
receiver
loadbot [--receiver ADDRESS]
loadbot --receiver 0x1010101010101010101010101010101010101000
Address of the receiver account.
jsonrpc
loadbot [--jsonrpc ENDPOINT]
loadbot --jsonrpc http://127.0.0.1:8545
A JSON RPC endpoint used to send transactions.
count
loadbot [--count COUNT]
loadbot --count 100
The total number of transactions to send. Default: 1000
value
loadbot [--value VALUE]
loadbot --value 10000000000000000
The value to send in each transaction.
max-conns
loadbot [--max-conns MAX_CONNECTIONS_COUNT]
loadbot --max-conns 1000
Sets the maximum no.of connections allowed per host. Default: 2*tps
backup flags
grpc-address
backup [--grpc-address GRPC_ADDRESS]
backup --grpc-address 127.0.0.1:9632
Address of the gRPC API. Default: 127.0.0.1:9632
out
backup [--out OUT]
backup --out backup.dat
Path of archive file to save.
from
from [--from FROM]
backup --from 0x0
The beginning height of blocks in archive. Default: 0
to
to [--to TO]
backup --to 0x2710
The end height of blocks in archive.
Genesis Template
The genesis file should be used to set the initial state of the blockchain (ex. if some accounts should have a starting balance). The following ./genesis.json file is generated:
{
"name": "example",
"genesis": {
"nonce": "0x0000000000000000",
"gasLimit": "0x0000000000001388",
"difficulty": "0x0000000000000001",
"mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
"coinbase": "0x0000000000000000000000000000000000000000",
"parentHash": "0x0000000000000000000000000000000000000000000000000000000000000000"
},
"params": {
"forks": {},
"chainID": 100,
"engine": {
"pow": {}
}
},
"bootnodes": []
}
Data Directory
When executing the data-dirflag, a test-chain folder is generated.
The folder structure consists of the
following sub-folders:
● blockchain Stores the LevelDB for blockchain objects.
● trie Stores the LevelDB for the Merkle tries.
● keystore Stores private keys for the client. This includes the libp2p private key and the sealing/validator private key
● consensus Stores any consensus information that the client might need while working
Resources