gRPC Single Sequencer App
This application runs an Evolve node with a single sequencer that connects to an execution client via gRPC. It allows you to use any execution layer that implements the Evolve execution gRPC interface.
Overview
The gRPC single sequencer app provides:
- An Evolve consensus node with single sequencer
- Connection to execution clients via TCP or Unix domain socket gRPC
- Full data availability layer integration
- P2P networking capabilities
Prerequisites
- A running execution client that implements the Evolve gRPC execution interface
- Access to a data availability layer (e.g., local DA, Celestia)
- Go 1.22 or higher
Installation
From the repository root:
cd apps/grpc
go build -o evgrpc
Usage
1. Initialize the Node
First, initialize the node configuration:
./evgrpc init --root-dir ~/.evgrpc
This creates the necessary configuration files and directories.
Edit the configuration file at ~/.evgrpc/config/config.toml to set your preferred parameters, or use command-line flags.
3. Start the Execution Service
Before starting the Evolve node, ensure your gRPC execution service is running.
4. Run the Node
Start the Evolve node with:
./evgrpc start \
--root-dir ~/.evgrpc \
--grpc-executor-url http://localhost:50051 \
--da.address http://localhost:7980 \
--da.auth-token your-da-token
For a same-machine executor, use a Unix domain socket endpoint:
./evgrpc start \
--root-dir ~/.evgrpc \
--grpc-executor-url unix:///tmp/evolve-executor.sock \
--da.address http://localhost:7980
Command-Line Flags
gRPC-specific Flags
--grpc-executor-url: URL of the gRPC execution service, either http://host:port or unix:///path/to/socket (default: http://localhost:50051)
Common Evolve Flags
--root-dir: Root directory for config and data (default: ~/.evgrpc)
--chain-id: The chain ID for your rollup
--da.address: Data availability layer address
--da.auth-token: Authentication token for DA layer
--da.namespace: Namespace for DA layer (optional)
--p2p.listen-address: P2P listen address (default: /ip4/0.0.0.0/tcp/7676)
--block-time: Time between blocks (default: 1s)
Example: Running with Local DA
-
Start the local DA service:
cd tools/local-da
go run .
-
Start your gRPC execution service:
# Your execution service implementation
-
Initialize and run the node:
./evgrpc init --root-dir ~/.evgrpc --chain-id test-chain
./evgrpc start \
--root-dir ~/.evgrpc \
--grpc-executor-url http://localhost:50051 \
--da.address http://localhost:7980
Architecture
┌─────────────────┐ ┌──────────────────┐ ┌─────────────┐
│ Evolve Node │────▶│ gRPC Execution │────▶│ Execution │
│ (Single Seqr) │◀────│ Client │◀────│ Service │
└─────────────────┘ └──────────────────┘ └─────────────┘
│ │
│ │
▼ ▼
┌─────────────────┐ ┌─────────────┐
│ DA │ │ State │
│ Layer │ │ Storage │
└─────────────────┘ └─────────────┘
Development
Building from Source
go build -o evgrpc
Running Tests
go test ./...
Troubleshooting
Connection Refused
If you see "connection refused" errors, ensure:
- Your gRPC execution service is running
- The execution service URL is correct
- No firewall is blocking the connection
DA Layer Issues
If you have issues connecting to the DA layer:
- Verify the DA service is running
- Check the authentication token
- Ensure the namespace exists (if using Celestia)
See Also