-
Notifications
You must be signed in to change notification settings - Fork 96
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support SELECT/INSERT/UPDATE/DELETE db operation + span names #1253
Conversation
8f0e456
to
5340675
Compare
89e64c7
to
7116a06
Compare
c809878
to
97ccfaf
Compare
cccbf66
to
264081d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks like an exciting change. Mainly small comments outside of the compatibility policy issue.
Do we need to support older versions of Go? Would that break any downstream users of go.opentelemetry.io/auto
?
76511c5
to
cc00965
Compare
Update from the SIG call feedback this week, I pinned Vitess to v0.20.2 which is on Go 1.22.7 (our version) and this is the error: https://github.com/open-telemetry/opentelemetry-go-instrumentation/actions/runs/12181495669/job/33978276098?pr=1253#step:6:434
This is probably because we build our image on go 1.23 (which makes sense, we ship an artifact based on that so it should use the latest runtime). Based on that, I think the only option is to undo the vitess work and revert this to just the basic command parsing I originally had. Which is a bummer, because vitess is a lot richer :\ @MrAlias does that sound good to you? |
I agree with the revert to the other sql parsing package. I think we should still be able to support table parsing though based on #1253 (comment) |
472c686
to
2bc5aa8
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
left 2 non-blocking comments
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🏅
Ref #743
From the semconv for db spans:
We don't have
collection
(table),namespace
, orserver.address
readily available (right now), but we can at least parse certain operations. We can also support more over time. So this gets us at least a couple useful span names besidesDB
(fallback for unsupported operations)This means we can also set
db.operation.name
with that same value when it is available.