Overview
A Tashi Vertex node requires four main components:- A runtime context for managing async operations
- A network socket bound to an address
- A consensus engine configured with options
- A message loop to process events and sync points
Initialize the runtime
First, create aContext to manage async operations and resources:
Parse your secret key
Load your node’s secret key from a Base58-encoded string:See the Key management guide for details on generating and securing keys.
Configure the peer network
Set up the initial peer set including other nodes and yourself:Bind a network socket
Bind a socket to listen for incoming connections:Configure engine options
Set up execution options for the consensus engine:See the Configuration guide for all available options and their defaults.
Start the consensus engine
Start the engine and begin participating in consensus:- Connecting to peers
- Participating in consensus
- Processing transactions
Send transactions
Submit transactions to the network:Receive messages
Process messages from the network in a loop:Event fields
Available event methods
Available event methods
creator()- Returns theKeyPublicof the event creatorcreated_at()- Timestamp when the event was createdconsensus_at()- Timestamp when consensus was reachedtransaction_count()- Number of transactions in the eventtransactions()- Iterator over transaction byte slices
Complete example
Here’s a complete pingback node that sends and receives messages:Next steps
Configure peers
Learn about peer capabilities and network topology in Network setup
Tune performance
Optimize engine parameters in Configuration
Manage keys
Set up secure key storage in Key management