You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/guides/01-getting-started-cli.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# Getting Started with mump2p CLI
2
2
3
-
The `mump2p` CLI is the quickest way to interact with [Optimum Network](https://github.com/getoptimum/optimum-p2p) without running your own infrastructure.
3
+
The `mump2p` CLI is the quickest way to interact with Optimum Network without running your own infrastructure.
|**mump2p Node**| RLNC-enabled mesh peer, encodes/decodes message shards, handles peer discovery and subscriptions. Optional gRPC API for direct clients. |`getoptimum/p2pnode:v0.0.1-rc2`|
66
-
|**Optimum Proxy**| Bridges clients and the mesh, manages subscriptions, shard reassembly, threshold logic, and node selection. |`getoptimum/proxy:v0.0.1-rc3`|
65
+
|**mump2p Node**| RLNC-enabled mesh peer, encodes/decodes message shards, handles peer discovery and subscriptions. Optional gRPC API for direct clients. |`getoptimum/p2pnode:${P2P_NODE_VERSION-latest}`|
66
+
|**Optimum Proxy**| Bridges clients and the mesh, manages subscriptions, shard reassembly, threshold logic, and node selection. |`getoptimum/proxy:${PROXY_VERSION-latest}`|
67
67
68
68
69
69
@@ -96,13 +96,21 @@ Before starting, create your `.env` file:
96
96
cp .env.example .env
97
97
```
98
98
99
+
**Important:** After copying, you need to replace the `BOOTSTRAP_PEER_ID` in your `.env` file with the peer ID generated by `make generate-identity`.
100
+
101
+
**Workflow:**
102
+
103
+
1. Run `make generate-identity` - this creates a unique peer ID
104
+
2. Copy the generated peer ID from the output
105
+
3. Edit your `.env` file and replace the example `BOOTSTRAP_PEER_ID` with your generated one
This creates `./identity/p2p.key` with your unique Peer ID.
119
127
120
-
> **Complete Guide:**[Identity generation and Makefile commands](https://github.com/getoptimum/optimum-dev-setup-guide#quick-start) - all make commands, direct binary usage
128
+
> **Complete Guide:**[Identity generation and Makefile commands](https://github.com/getoptimum/optimum-dev-setup-guide/blob/main/docs/guide.md#getting-started) - all make commands, direct binary usage
121
129
122
130
## 5. Mode A — OptimumProxy + mump2p (Recommended)
123
131
@@ -156,20 +164,20 @@ services:
156
164
> **Complete Docker Compose:**
157
165
>
158
166
> * [Full configuration with 2 proxies + 4 nodes](https://github.com/getoptimum/optimum-dev-setup-guide/blob/main/docker-compose-optimum.yml)
docker-compose -f docker-compose-optimum.yml up --build -d
166
174
```
167
175
168
176
### Verify Health
169
177
170
178
```sh
171
179
# Check containers
172
-
dockercompose ps
180
+
docker-compose -f docker-compose-optimum.yml ps
173
181
174
182
# Test endpoints
175
183
curl http://localhost:8081/api/v1/health # Proxy
@@ -251,12 +259,14 @@ services:
251
259
```
252
260
253
261
> **Complete Docker Compose:** [Full configuration for direct P2P mode](https://github.com/getoptimum/optimum-dev-setup-guide/blob/main/docker-compose-optimum.yml)
262
+
>
263
+
> **Note:** The docker-compose file uses environment variables from `.env` for versions. Ensure your `.env` file has `PROXY_VERSION` and `P2P_NODE_VERSION` set.
254
264
255
265
### Start and Verify
256
266
257
267
```sh
258
268
export BOOTSTRAP_PEER_ID=<your-peer-id>
259
-
dockercompose up -d
269
+
docker-compose -f docker-compose-optimum.yml up --build -d
260
270
curl http://localhost:9091/api/v1/health
261
271
```
262
272
@@ -266,15 +276,15 @@ Connect using the P2P client with trace handling and metrics:
Copy file name to clipboardExpand all lines: docs/guides/04-experiments.md
+16-14Lines changed: 16 additions & 14 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -13,7 +13,7 @@ Each experiment below lists the **goal**, a quick **how-to**, and **what to obse
13
13
You can run them using:
14
14
15
15
***mump2p CLI** (see [CLI Guide](./01-getting-started-cli.md))
16
-
***gRPC client** (with `MessageTraceGossipSub` or `MessageTraceOptimump2p` for protocol metrics)
16
+
***gRPC P2P client** (trace collection is automatic when subscribing - see [Trace Collection](#metrics-collection))
17
17
18
18
19
19
@@ -112,33 +112,35 @@ You can run them using:
112
112
**Expected Result:** mump2p should handle higher stress levels before failing compared to GossipSub.
113
113
114
114
115
-
> **Tip:** Enable protocol traces in the gRPC client to get hop-by-hop delivery info:
116
-
>
117
-
> *`MessageTraceGossipSub` for GossipSub mode.
118
-
> *`MessageTraceOptimump2p` for mump2p mode.
115
+
> **Tip:** Trace collection is automatic when using the gRPC P2P client. Simply subscribe to a topic and trace events will be automatically parsed and displayed. See [Trace Collection](#metrics-collection) for details.
119
116
120
117
## Metrics Collection
121
118
122
119
For comprehensive metrics collection during experiments, use the gRPC P2P client with trace handling:
123
120
124
121
**[P2P Client with Metrics Collection](https://github.com/getoptimum/optimum-dev-setup-guide/blob/main/docs/guide.md#collecting-trace-data-for-experiments)**
Trace parsing is implemented in `grpc_p2p_client/shared/utils.go` and handles both `ResponseType_MessageTraceGossipSub` and `ResponseType_MessageTraceMumP2P` automatically.
Use this client instead of the CLI for detailed performance analysis during experiments.
146
+
See the [dev setup guide](https://github.com/getoptimum/optimum-dev-setup-guide/blob/main/docs/guide.md#multi-node-client-tools)for more details on multi-node client tools.
For P2P direct client, see [`grpc_p2p_client/cmd/single/main.go`](https://github.com/getoptimum/optimum-dev-setup-guide/blob/main/grpc_p2p_client/cmd/single/main.go)
63
69
64
70
### Q: Getting "method not found" or protobuf errors
65
71
66
72
**A:** Use the correct protobuf definitions from [`optimum-dev-setup-guide/docs/guide.md`](https://github.com/getoptimum/optimum-dev-setup-guide/blob/main/docs/guide.md#api-reference):
67
73
68
74
* See the [API Reference section](https://github.com/getoptimum/optimum-dev-setup-guide/blob/main/docs/guide.md#api-reference) for complete protobuf definitions
69
75
* All proto files are available in the repository's `grpc_*_client/proto/` directories:
0 commit comments