Skip to content

feat: Add db.system indicators to redis, sqlalchemy, and django#2035

Closed
AbhiPrasad wants to merge 4 commits into
masterfrom
abhi-db-system
Closed

feat: Add db.system indicators to redis, sqlalchemy, and django#2035
AbhiPrasad wants to merge 4 commits into
masterfrom
abhi-db-system

Conversation

@AbhiPrasad

Copy link
Copy Markdown
Contributor

ref getsentry/team-webplatform-meta#60

dependent on getsentry/develop#917

Add this information to span data field as db.system, matching OpenTelemetry's well known conventions.

For example, db.system of postgresql would indicate that it's a postgres database.

hub, self.cursor, sql, params, paramstyle="format", executemany=False
):
) as span:
vendor = connection.vendor

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I realized this strategy doesn't work if you have multiple connections open, but not sure how common that is.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In Django it is common to have one connection to a read only replica of the database and one you use to change the data, so probably on bigger installations quite common.

@AbhiPrasad

AbhiPrasad commented Apr 25, 2023

Copy link
Copy Markdown
Contributor Author

Splitting this up in favour of 4 PRs:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants