Architecture Overview
This page describes Ashen’s testnet architecture. For component details, see:
Testnet Architecture
Section titled “Testnet Architecture” ┌─────────────────────────────────────────────────────────┐ │ TESTNET ARCHITECTURE │ └─────────────────────────────────────────────────────────┘
┌───────────────────────────────────────────────────────────────────────────────────────┐ │ CONSENSUS LAYER │ │ │ │ ┌─────────────────┐ ┌─────────────────┐ ┌─────────────────┐ │ │ │ Validator 0 │ │ Validator 1 │ │ Validator 2 │ │ │ │ (PRUNING) │ │ (PRUNING) │ │ [ARCHIVE] │ │ │ │ │ │ │ │ │ │ │ │ P2P: :4040 │◄──►│ P2P: :4041 │◄──►│ P2P: :4042 │ │ │ │ Metrics: :3031 │ │ Metrics: :3032 │ │ Metrics: :3033 │ │ │ │ │ │ │ │ │ │ │ │ ┌───────────┐ │ │ ┌───────────┐ │ │ ┌───────────┐ │ │ │ │ │ 3 epochs │ │ │ │ 3 epochs │ │ │ │ FULL │ │ │ │ │ │ of state │ │ │ │ of state │ │ │ │ HISTORY │ │ │ │ │ └───────────┘ │ │ └───────────┘ │ │ └───────────┘ │ │ │ └────────┬────────┘ └────────┬────────┘ └────────┬────────┘ │ │ │ │ │ │ │ └──────────────────────┼──────────────────────┘ │ │ │ │ │ BLS Threshold Signing │ │ DKG Key Refresh │ │ Simplex Consensus │ └───────────────────────────────────┼───────────────────────────────────────────────────┘ │ │ shares data dir ▼ ┌───────────────────────────────────────────────────────────────────────────────────────┐ │ RPC LAYER │ │ │ │ ┌─────────────────────┐ │ │ │ RPC Server │ │ │ │ :3030 │ │ │ │ │ │ │ │ • Full /v2/rpc │ │ │ │ • Historical queries│ │ │ │ • tx_submit │ │ │ │ • WebSocket subs │ │ │ └──────────┬──────────┘ │ │ │ │ └───────────────────────────────────────┼────────────────────────────────────────────────┘ │ ▼ ┌───────────────────────────────────────────────────────────────────────────────────────┐ │ CLIENTS │ │ │ │ ┌──────────┐ ┌──────────┐ ┌──────────┐ ┌──────────┐ │ │ │ ashen │ │ dApps │ │ Explorer │ │ Wallets │ │ │ │ CLI │ │ │ │ │ │ │ │ │ └──────────┘ └──────────┘ └──────────┘ └──────────┘ │ │ │ └────────────────────────────────────────────────────────────────────────────────────────┘Data Flow
Section titled “Data Flow”Transactions: Client ──► RPC ──► Mempool ──► Leader Validator ──► Block
Blocks: Leader ──► P2P Broadcast ──► All Validators ──► Finality Proof
Queries: Client ──► RPC ──► Archive Validator State ──► ResponseStorage Per Node
Section titled “Storage Per Node”Pruning Validators (0, 1):
Directorytestnet-local/
Directorynode-X/
- genesis.json
Directoryblocks/ pruned
- …
Directorystate/ 3 epochs only
- …
Directoryconsensus/
- …
Archive Validator (2):
Directorytestnet-local/
Directorynode-2/
- genesis.json
Directoryblocks/ full history
- …
Directorystate/ full history
- …
Directoryconsensus/
- …
Node Roles
Section titled “Node Roles”| Role | Mode | Storage | RPC | Consensus |
|---|---|---|---|---|
| Pruning Validator | --validator --prune-keep-epochs N | Limited | Metrics only | Yes |
| Archive Validator | --validator --archive-mode | Full | Metrics only | Yes |
| RPC Server | node rpc | Shared | Full | No |
| Follower (planned) | --follower | Configurable | Full | No |
Running the Testnet
Section titled “Running the Testnet”-
Generate keys and peers.yaml (first time only)
Terminal window just testnet-local-generate -
Run testnet - 2 pruning + 1 archive validator + RPC
Terminal window just testnet-local-run -
Custom configuration (optional)
Terminal window just testnet-local-run N_VALIDATORS=5 PRUNE_KEEP_EPOCHS=5
Ports (Default Configuration)
Section titled “Ports (Default Configuration)”| Service | Port |
|---|---|
| RPC Server | 3030 |
| Validator 0 Metrics | 3031 |
| Validator 1 Metrics | 3032 |
| Validator 2 Metrics | 3033 |
| Validator 0 P2P | 4040 |
| Validator 1 P2P | 4041 |
| Validator 2 P2P | 4042 |