Skip to content

Commit 237e8e4

Browse files
authored
Fixes to C++ and Python OTel codelabs (#35)
1 parent f7c3cb6 commit 237e8e4

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

codelabs/grpc-cpp-opentelemetry/README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ $ cp bazelisk-linux-amd64 /usr/local/bin/bazel
3838
### **What you’ll need**
3939

4040
* A computer with internet connection
41+
* Ability to open three separate terminals.
4142

4243
<!-- TODO(yashkt/arvindbright) : Add some additional boilerplate stuff over here if needed. -->
4344

@@ -95,7 +96,7 @@ int main(int argc, char** argv) {
9596
```
9697
9798
> [!NOTE]
98-
> How a Prometheus Exporter is being set up on the OpenTelemetry Meter Provider.
99+
> A Prometheus Exporter is being set up on the OpenTelemetry Meter Provider.
99100
> (There are other ways to export the metrics as well. This codelab chooses the
100101
> prometheus exporter.) This MeterProvider is provided to gRPC’s OpenTelemetry
101102
> plugin as configuration. Once the OpenTelemetry plugin is registered globally

codelabs/grpc-python-opentelemetry/README.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ $ python -m pip install --upgrade pip
3333
#### Install dependencies
3434

3535
```console
36-
$ cd codelabs/gRPC_Python_OpenTelemetry_Plugin/
36+
$ cd codelabs/grpc-python-opentelemetry/
3737
$ python -m pip install -r requirements.txt
3838
```
3939

@@ -47,6 +47,7 @@ $ python -m pip install -r requirements.txt
4747
### **What you’ll need**
4848

4949
* A computer with internet connection
50+
* Ability to open three separate terminals.
5051

5152
## Instrumenting applications with gRPC OpenTelemetry Plugin
5253

@@ -67,6 +68,9 @@ import helloworld_pb2_grpc
6768
from opentelemetry.exporter.prometheus import PrometheusMetricReader
6869
from opentelemetry.sdk.metrics import MeterProvider
6970
from prometheus_client import start_http_server
71+
72+
_SERVER_PORT = "50051"
73+
_PROMETHEUS_PORT = 9465
7074
```
7175

7276
Then transform `run()` to look like

0 commit comments

Comments
 (0)