Skip to content

Commit

Permalink
[docs] Include opentelemetry-distro as dep for auto-instrumentation e…
Browse files Browse the repository at this point in the history
…xample (#2317)
  • Loading branch information
robbkidd authored Dec 10, 2021
1 parent 9ef6829 commit af862eb
Showing 1 changed file with 12 additions and 16 deletions.
28 changes: 12 additions & 16 deletions docs/examples/auto-instrumentation/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -72,17 +72,21 @@ Install
-------

Run the following commands to install the appropriate packages. The
``opentelemetry-instrumentation`` package provides several
commands that help automatically instruments a program.
``opentelemetry-distro`` package depends on a few others, like ``opentelemetry-sdk``
for custom instrumentation of your own code and ``opentelemetry-instrumentation`` which
provides several commands that help automatically instrument a program.

.. code:: sh
$ pip install opentelemetry-sdk
$ pip install opentelemetry-instrumentation
$ pip install opentelemetry-distro
$ pip install opentelemetry-instrumentation-flask
$ pip install flask
$ pip install requests
The examples that follow send instrumentation results to the console. Learn more
about installing and configuring the `OpenTelemetry Distro <../distro>`_ to send
telemetry to other destinations, like an OpenTelemetry Collector.

Execute
---------

Expand All @@ -106,8 +110,8 @@ scripts that make up this example:
$ source auto_instrumentation/bin/activate
$ python client.py testing
When you execute ``server_instrumented.py`` it returns a JSON response
similar to the following example:
The console running ``server_instrumented.py`` will display the spans generated by instrumentation as JSON.
The spans should appear similar to the following example:

.. code:: sh
Expand Down Expand Up @@ -162,8 +166,8 @@ command again:
$ python client.py testing
When you execute ``server_uninstrumented.py`` it returns a JSON response
similar to the following example:
The console running ``server_uninstrumented.py`` will display the spans generated by instrumentation as JSON.
The spans should appear similar to the following example:

.. code:: sh
Expand Down Expand Up @@ -227,11 +231,3 @@ reloader. To run instrumentation while the debug mode is enabled, set the
if __name__ == "__main__":
app.run(port=8082, debug=True, use_reloader=False)
Additional resources
~~~~~~~~~~~~~~~~~~~~

In order to send telemetry to an OpenTelemetry Collector without doing any
additional configuration, read about the `OpenTelemetry Distro <../distro>`_
package.

0 comments on commit af862eb

Please sign in to comment.