Skip to content

Commit a0c9940

Browse files
Fix docs and comments
1 parent a0f74ca commit a0c9940

File tree

3 files changed

+8
-7
lines changed

3 files changed

+8
-7
lines changed

Diff for: docs-requirements.txt

+1
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ mysqlclient~=2.1.1
3232
openai >= 1.26.0
3333
psutil>=5
3434
psycopg~=3.1.17
35+
psycopg2~=2.9.9
3536
pika>=0.12.0
3637
pymongo~=4.6.3
3738
PyMySQL~=1.1.1

Diff for: instrumentation/opentelemetry-instrumentation-psycopg2/README.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
OpenTelemetry Psycopg Instrumentation
1+
OpenTelemetry Psycopg2 Instrumentation
22
=====================================
33

44
|pypi|
@@ -16,6 +16,6 @@ Installation
1616

1717
References
1818
----------
19-
* `OpenTelemetry Psycopg Instrumentation <https://opentelemetry-python-contrib.readthedocs.io/en/latest/instrumentation/psycopg2/psycopg2.html>`_
19+
* `OpenTelemetry Psycopg2 Instrumentation <https://opentelemetry-python-contrib.readthedocs.io/en/latest/instrumentation/psycopg2/psycopg2.html>`_
2020
* `OpenTelemetry Project <https://opentelemetry.io/>`_
2121
* `OpenTelemetry Python Examples <https://github.com/open-telemetry/opentelemetry-python/tree/main/docs/examples>`_

Diff for: instrumentation/opentelemetry-instrumentation-psycopg2/src/opentelemetry/instrumentation/psycopg2/__init__.py

+5-5
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@
1313
# limitations under the License.
1414

1515
"""
16-
The integration with PostgreSQL supports the `Psycopg`_ library, it can be enabled by
16+
The integration with PostgreSQL supports the `Psycopg2`_ library, it can be enabled by
1717
using ``Psycopg2Instrumentor``.
1818
19-
.. _Psycopg: http://initd.org/psycopg/
19+
.. _Psycopg2: https://www.psycopg.org/docs/
2020
2121
SQLCOMMENTER
2222
*****************************************
@@ -136,8 +136,8 @@ def instrumentation_dependencies(self) -> Collection[str]:
136136
return _instruments
137137

138138
def _instrument(self, **kwargs):
139-
"""Integrate with PostgreSQL Psycopg library.
140-
Psycopg: http://initd.org/psycopg/
139+
"""Integrate with PostgreSQL Psycopg2 library.
140+
Psycopg2: https://www.psycopg.org/docs/
141141
"""
142142
tracer_provider = kwargs.get("tracer_provider")
143143
enable_sqlcommenter = kwargs.get("enable_commenter", False)
@@ -171,7 +171,7 @@ def instrument_connection(
171171
# _instrument (via BaseInstrumentor) or instrument_connection (this)
172172
# was already called
173173
_logger.warning(
174-
"Attempting to instrument Psycopg connection while already instrumented"
174+
"Attempting to instrument Psycopg2 connection while already instrumented"
175175
)
176176
self._is_instrumented_by_opentelemetry = True
177177
return connection

0 commit comments

Comments
 (0)