Installation and usage of the platform

Precise platform configuration: anchoring

If you plan to use the data anchoring from your network to a larger network, configure the data transfer settings in the anchoring block of the node’s configuration file. In the terminology of the configuration file, targetnet is the blockchain to which your node will perform anchoring transactions from the current network.

 anchoring {
 enable = yes
 height-range = 30
 height-above = 8
 threshold = 20
 tx-mining-check-delay = 5 seconds
 tx-mining-check-count = 20


 targetnet-authorization {
 type = "oauth2" # "api-key" or "oauth2"
 authorization-token = ""
 authorization-service-url = "https://client.wavesenterprise.com/authServiceAddress/v1/auth/token"
 token-update-interval = "60s"
 # api-key-hash = ""
 # privacy-api-key-hash = ""
 }

 targetnet-scheme-byte = "V"
 targetnet-node-address = "https://client.wavesenterprise.com:6862/NodeAddress"
 targetnet-node-recipient-address = ""
 targetnet-private-key-password = ""

  wallet {
  file = "node-1_mainnet-wallet.dat"
  password = "small"
   }

 targetnet-fee = 10000000
 sidechain-fee = 5000000
}

Anchoring parameters

  • enable - enable or disable anchoring (yes / no);

  • height-range - the block interval, after which the private blockchain node sends transactions to the Targetnet for anchoring;

  • height-above - the number of blocks in Targetnet, after which the private blockchain node creates a confirmation anchoring transaction with the data of the first transaction. It is recommended to set the value not exceeding the maximum value of rollback of blocks in Targetnet (max-rollback);

  • threshold - the number of blocks that is subtracted from the current height of the private blockchain. Anchoring transaction sent to Targetnet will receive information from the block at current-height - threshold. If the value 0 is set, the block value at the current block height is written to the anchoring transaction. It is recommended to set the value close to the maximum rollback value in the private blockchain (max-rollback);

  • tx-mining-check-delay - the wait time between checks of transaction availability for anchoring in Targetnet;

  • tx-mining-check-count - the maximum number of checks for transaction availability for anchoring in the Targetnet, after completion of which the transaction is not considered to enter the network.

Depending on the mining settings on the Targetnet, the distance between anchoring transactions may vary. The set value of height-range defines the approximate interval between anchoring transactions. The actual time for anchoring transactions to hit a mined block on the Targetnet network may be longer than the time it takes to mine the number of height-range blocks on the Targetnet network.

Authorization parameters for anchoring

  • type - type of authorization when using anchoring: * api-key - authorization by an api-key-hash; * auth-service - authorization by aJWT-token through authorization service.

If you choose authorization by api-key-hash, it is sufficient to specify the key value in the api-key parameter. If you choose authorization by a JWT-token, you must specify type = "auth-service" and uncomment and fill in the parameters below:

  • authorization-token - permanent authorization token;

  • authorization-service-url - URL of the authorization service;

  • token-update-interval - interval for authorization token update.

Targetnet access parameters

A separate keystore.dat file is generated for the node that will send anchoring transactions to the Targetnet with the key pair for access to the Targetnet.

  • targetnet-scheme-byte - Targetnet network (Waves Enterprise Mainnet - V);

  • targetnet-node-address - full network address of the node together with the port number in the Targetnet network to which transactions will be sent for anchoring. The address must be specified together with the connection type (http/https), port number and parameter NodeAddress: http://node.weservices.com:6862/NodeAddress;

  • targetnet-node-recipient-address - the address of the node in the Targetnet network, to which the transactions for anchoring will be written, signed by the key pair of this address;

  • targetnet-private-key-password - node private key password to sign anchoring transactions.

The network address and port for anchoring to the Targetnet network can be obtained from Waves Enterprise technical support specialists. If you use multiple private blockchains with mutual anchoring, use the appropriate private network settings.

Key pair file parameters for signing anchoring transactions in Targetnet, (``wallet`` section)

  • file - file name and path to the file storage directory with the key pair for signing anchoring transactions in the Targetnet network. The file is located on the private network node;

  • password - the password of the key pair file.

Fee parameters

  • targetnet-fee - a fee for issuing a transaction for anchoring in the Targetnet network;

  • sidechain-fee - a fee for issuing a transaction in the current private blockchain.