Skip to content
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

SpanOption DisableQuery #26

Merged
merged 6 commits into from
Sep 3, 2021
Merged

SpanOption DisableQuery #26

merged 6 commits into from
Sep 3, 2021

Conversation

wesleyvicthor
Copy link
Contributor

Hi, this PR attempts to cover the DisableQuery functionality, this time as opposed #25, it makes only the attribute not set.

It tries to cover the expected functionality by #22

DisableQuery when set to true, will suppress attribute of key
db.statement on spans.
this commit adds a step check on every span which uses db.statement
attribute. in case SpanOption.DisableQuery is set true, the attribute is
not set.
@wesleyvicthor wesleyvicthor requested a review from XSAM as a code owner August 31, 2021 18:42
@wesleyvicthor
Copy link
Contributor Author

Hi @XSAM this time I am trying to disable the query itself. I wonder if would make sense to set the value with something like "-" instead of not sending it. wdyt ?

@XSAM
Copy link
Owner

XSAM commented Sep 1, 2021

Hi @XSAM this time I am trying to disable the query itself. I wonder if would make sense to set the value with something like "-" instead of not sending it. wdyt ?

I think not sending the value is make sense to me. You can check the example value from the specification.

Copy link
Owner

@XSAM XSAM left a comment

Choose a reason for hiding this comment

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

Looks good overall. Please update CHANGELOG.md and run make precommit before commit.

updates the changelog adding new feature option for SpanOption +
fix linting.
@codecov
Copy link

codecov bot commented Sep 1, 2021

Codecov Report

Merging #26 (7b4d621) into main (83759c0) will decrease coverage by 0.7%.
The diff coverage is 100.0%.

Impacted file tree graph

@@           Coverage Diff           @@
##            main     #26     +/-   ##
=======================================
- Coverage   82.3%   81.6%   -0.8%     
=======================================
  Files         11      11             
  Lines        311     299     -12     
=======================================
- Hits         256     244     -12     
  Misses        45      45             
  Partials      10      10             
Impacted Files Coverage Δ
config.go 100.0% <100.0%> (ø)
conn.go 77.5% <100.0%> (-1.8%) ⬇️
stmt.go 79.4% <100.0%> (-2.8%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 83759c0...7b4d621. Read the comment docs.

CHANGELOG.md Outdated Show resolved Hide resolved
@XSAM XSAM linked an issue Sep 2, 2021 that may be closed by this pull request
config.go Outdated Show resolved Hide resolved
wesleyvicthor and others added 2 commits September 2, 2021 23:13
Co-authored-by: Sam Xie <xsambundy@gmail.com>
Co-authored-by: Sam Xie <xsambundy@gmail.com>
Copy link
Owner

@XSAM XSAM left a comment

Choose a reason for hiding this comment

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

@wesleyvicthor LGTM. Thanks for your contribution.

@XSAM XSAM merged commit e9d1cb8 into XSAM:main Sep 3, 2021
@XSAM XSAM mentioned this pull request Sep 6, 2021
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.

Features not toggleable in config?
2 participants