Open orangain opened 1 year ago
@haddasbronfman do you maybe have some more context on this? :slightly_smiling_face:
This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 14 days.
This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 14 days.
This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 14 days.
What version of OpenTelemetry are you using?
What version of Node are you using?
v16.19.0
What did you do?
I set up auto instrumentation of an application using pg.Pool. In the application, pg.Pool was configured by
connectionString
like this:Then I launched the application and found a trace having wrong value of
db.connection_string
.Repro application is available at: https://github.com/orangain/opentelemetry-js-contrib/tree/spike-address-pg-pool-issue/examples/postgres
Complete recipe to reproduce
After launching the server, open http://localhost:16686 in a browser, and you will see the Jaeger UI. Then select
unknown_service:node
from "Service" dropdown and click "Find Traces" button.What did you expect to see?
The span
pg-pool.connect
contains a tagdb.connection_string
and its value ispostgresql://localhost:54320/postgres
.What did you see instead?
The span
pg-pool.connect
contains a tagdb.connection_string
and its value ispostgresql://localhost:5432/
. The port number is wrong and the database name does not exist.Additional context
Note that the child span
pg.connect
contains a tagdb.connection_string
and its value ispostgresql://localhost:54320/postgres
as expected.https://github.com/open-telemetry/opentelemetry-js-contrib/issues/782 is a similar issue but it seems to be a different situation.