|
| 1 | +# DA Visualizer |
| 2 | + |
| 3 | +The Data Availability (DA) Visualizer is a built-in monitoring tool in Evolve that provides real-time insights into blob submissions to the DA layer. It offers a web-based interface for tracking submission statistics, monitoring DA layer health, and analyzing blob details. |
| 4 | + |
| 5 | +**Note**: Only aggregator nodes submit data to the DA layer. Non-aggregator nodes will not display submission data. |
| 6 | + |
| 7 | +## Overview |
| 8 | + |
| 9 | +The DA Visualizer provides: |
| 10 | + |
| 11 | +- Real-time monitoring of blob submissions (last 100 submissions) |
| 12 | +- Success/failure statistics and trends |
| 13 | +- Gas price tracking and cost analysis |
| 14 | +- DA layer health monitoring |
| 15 | +- Detailed blob inspection capabilities |
| 16 | +- Recent submission history |
| 17 | + |
| 18 | +## Enabling the DA Visualizer |
| 19 | + |
| 20 | +The DA Visualizer is disabled by default. To enable it, use the following configuration: |
| 21 | + |
| 22 | +### Via Command-line Flag |
| 23 | + |
| 24 | +```bash |
| 25 | +testapp start --rollkit.rpc.enable_da_visualization |
| 26 | +``` |
| 27 | + |
| 28 | +### Via Configuration File |
| 29 | + |
| 30 | +Add the following to your `evolve.yaml` configuration file: |
| 31 | + |
| 32 | +```yaml |
| 33 | +rpc: |
| 34 | + enable_da_visualization: true |
| 35 | +``` |
| 36 | +
|
| 37 | +## Accessing the DA Visualizer |
| 38 | +
|
| 39 | +Once enabled, the DA Visualizer is accessible through your node's RPC server. By default, this is: |
| 40 | +
|
| 41 | +``` |
| 42 | +http://localhost:7331/da |
| 43 | +``` |
| 44 | + |
| 45 | +The visualizer provides several API endpoints and a web interface: |
| 46 | + |
| 47 | +### Web Interface |
| 48 | + |
| 49 | +Navigate to `http://localhost:7331/da` in your web browser to access the interactive dashboard. |
| 50 | + |
| 51 | +### API Endpoints |
| 52 | + |
| 53 | +The following REST API endpoints are available for programmatic access: |
| 54 | + |
| 55 | +#### Get Recent Submissions |
| 56 | + |
| 57 | +```bash |
| 58 | +GET /da/submissions |
| 59 | +``` |
| 60 | + |
| 61 | +Returns the most recent blob submissions (up to 100 kept in memory). |
| 62 | + |
| 63 | +#### Get Blob Details |
| 64 | + |
| 65 | +```bash |
| 66 | +GET /da/blob?id={blob_id} |
| 67 | +``` |
| 68 | + |
| 69 | +Returns detailed information about a specific blob submission. |
| 70 | + |
| 71 | +#### Get DA Statistics |
| 72 | + |
| 73 | +```bash |
| 74 | +GET /da/stats |
| 75 | +``` |
| 76 | + |
| 77 | +Returns aggregated statistics including: |
| 78 | + |
| 79 | +- Total submissions count |
| 80 | +- Success/failure rates |
| 81 | +- Average gas price |
| 82 | +- Total gas spent |
| 83 | +- Average blob size |
| 84 | +- Submission trends |
| 85 | + |
| 86 | +#### Get DA Health Status |
| 87 | + |
| 88 | +```bash |
| 89 | +GET /da/health |
| 90 | +``` |
| 91 | + |
| 92 | +Returns the current health status of the DA layer including: |
| 93 | + |
| 94 | +- Connection status |
| 95 | +- Recent error rates |
| 96 | +- Performance metrics |
| 97 | +- Last successful submission timestamp |
| 98 | + |
| 99 | +## Features |
| 100 | + |
| 101 | +### Real-time Monitoring |
| 102 | + |
| 103 | +The dashboard automatically updates every 30 seconds, displaying: |
| 104 | + |
| 105 | +- Recent submission feed with status indicators (last 100 submissions) |
| 106 | +- Success rate percentage |
| 107 | +- Current gas price trends |
| 108 | +- Submission history |
| 109 | + |
| 110 | +### Submission Details |
| 111 | + |
| 112 | +Each submission entry shows: |
| 113 | + |
| 114 | +- Timestamp |
| 115 | +- Blob ID with link to detailed view |
| 116 | +- Number of blobs in the batch |
| 117 | +- Submission status (success/failure) |
| 118 | +- Gas price used |
| 119 | +- Error messages (if any) |
| 120 | + |
| 121 | +### Statistics Dashboard |
| 122 | + |
| 123 | +The statistics section provides: |
| 124 | + |
| 125 | +- **Performance Metrics**: Success rate, average submission time |
| 126 | +- **Cost Analysis**: Total gas spent, average gas price over time |
| 127 | +- **Volume Metrics**: Total blobs submitted, average blob size |
| 128 | +- **Trend Analysis**: Hourly and daily submission patterns |
| 129 | + |
| 130 | +### Health Monitoring |
| 131 | + |
| 132 | +The health status indicator shows: |
| 133 | + |
| 134 | +- 🟢 **Healthy**: DA layer responding normally |
| 135 | +- 🟡 **Warning**: Some failures but overall functional |
| 136 | +- 🔴 **Critical**: High failure rate or connection issues |
| 137 | + |
| 138 | +## Use Cases |
| 139 | + |
| 140 | +### For Node Operators |
| 141 | + |
| 142 | +- Monitor the reliability of DA submissions |
| 143 | +- Track gas costs and optimize gas price settings |
| 144 | +- Identify patterns in submission failures |
| 145 | +- Ensure DA layer connectivity |
| 146 | + |
| 147 | +### For Developers |
| 148 | + |
| 149 | +- Debug DA submission issues |
| 150 | +- Analyze blob data structure |
| 151 | +- Monitor application-specific submission patterns |
| 152 | +- Test DA layer integration |
| 153 | + |
| 154 | +### For Network Monitoring |
| 155 | + |
| 156 | +- Track overall network DA usage |
| 157 | +- Identify congestion periods |
| 158 | +- Monitor gas price fluctuations |
| 159 | +- Analyze submission patterns across the network |
| 160 | + |
| 161 | +## Configuration Options |
| 162 | + |
| 163 | +When enabling the DA Visualizer, you may want to adjust related RPC settings: |
| 164 | + |
| 165 | +```yaml |
| 166 | +rpc: |
| 167 | + address: "0.0.0.0:7331" # Bind to all interfaces for remote access |
| 168 | + enable_da_visualization: true |
| 169 | +``` |
| 170 | +
|
| 171 | +**Security Note**: If binding to all interfaces (`0.0.0.0`), ensure proper firewall rules are in place to restrict access to trusted sources only. |
| 172 | + |
| 173 | +## Troubleshooting |
| 174 | + |
| 175 | +### Visualizer Not Accessible |
| 176 | + |
| 177 | +1. Verify the DA Visualizer is enabled: |
| 178 | + - Check your configuration file or ensure the flag is set |
| 179 | + - Look for log entries confirming "DA visualization endpoints registered" |
| 180 | + |
| 181 | +2. Check the RPC server is running: |
| 182 | + - Verify the RPC address in logs |
| 183 | + - Ensure no port conflicts |
| 184 | + |
| 185 | +3. For remote access: |
| 186 | + - Ensure the RPC server is bound to an accessible interface |
| 187 | + - Check firewall settings |
| 188 | + |
| 189 | +### No Data Displayed |
| 190 | + |
| 191 | +1. Verify your node is in aggregator mode (only aggregators submit to DA) |
| 192 | +2. Check DA layer connectivity in the node logs |
| 193 | +3. Ensure transactions are being processed |
| 194 | +4. Note that the visualizer only keeps the last 100 submissions in memory |
| 195 | + |
| 196 | +### API Errors |
| 197 | + |
| 198 | +- **404 Not Found**: DA Visualizer not enabled |
| 199 | +- **500 Internal Server Error**: Check node logs for DA connection issues |
| 200 | +- **Empty responses**: No submissions have been made yet |
| 201 | + |
| 202 | +## Example Usage |
| 203 | + |
| 204 | +### Using curl to access the API |
| 205 | + |
| 206 | +```bash |
| 207 | +# Get recent submissions (returns up to 100) |
| 208 | +curl http://localhost:7331/da/submissions |
| 209 | +
|
| 210 | +# Get specific blob details |
| 211 | +curl http://localhost:7331/da/blob?id=abc123... |
| 212 | +
|
| 213 | +# Get statistics |
| 214 | +curl http://localhost:7331/da/stats |
| 215 | +
|
| 216 | +# Check DA health |
| 217 | +curl http://localhost:7331/da/health |
| 218 | +``` |
| 219 | + |
| 220 | +### Monitoring with scripts |
| 221 | + |
| 222 | +```bash |
| 223 | +#!/bin/bash |
| 224 | +# Simple monitoring script |
| 225 | +
|
| 226 | +while true; do |
| 227 | + health=$(curl -s http://localhost:7331/da/health | jq -r '.status') |
| 228 | + if [ "$health" != "healthy" ]; then |
| 229 | + echo "DA layer issue detected: $health" |
| 230 | + # Send alert... |
| 231 | + fi |
| 232 | + sleep 30 |
| 233 | +done |
| 234 | +``` |
| 235 | + |
| 236 | +## Related Configuration |
| 237 | + |
| 238 | +For complete DA layer configuration options, see the [Config Reference](../learn/config.md#data-availability-configuration-da). |
| 239 | + |
| 240 | +For metrics and monitoring setup, see the [Metrics Guide](./metrics.md). |
0 commit comments