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

Stop creating root spans without existing spans #13

Merged
merged 5 commits into from
May 13, 2021
Merged

Stop creating root spans without existing spans #13

merged 5 commits into from
May 13, 2021

Conversation

XSAM
Copy link
Owner

@XSAM XSAM commented May 12, 2021

otelsql will not create root spans without existing spans by default; discrete spans will disappear.

It resolves #7 because sql.conn.reset_session will not occur if there is no parent spans exist.

AllowRoot option is for preventing backward incompatible.

@codecov
Copy link

codecov bot commented May 12, 2021

Codecov Report

Merging #13 (0bc9d52) into main (8c94007) will increase coverage by 1.70%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main      #13      +/-   ##
==========================================
+ Coverage   80.49%   82.20%   +1.70%     
==========================================
  Files          11       11              
  Lines         282      309      +27     
==========================================
+ Hits          227      254      +27     
  Misses         45       45              
  Partials       10       10              
Impacted Files Coverage Δ
config.go 100.00% <ø> (ø)
conn.go 79.31% <100.00%> (+2.38%) ⬆️
rows.go 56.09% <100.00%> (+4.74%) ⬆️
stmt.go 82.22% <100.00%> (+2.22%) ⬆️
tx.go 100.00% <100.00%> (ø)
utils.go 100.00% <100.00%> (ø)

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 8c94007...0bc9d52. Read the comment docs.

@XSAM XSAM changed the title Add AllowRoot option Stop creating root spans without existing spans May 12, 2021
@XSAM XSAM merged commit 0987eb9 into main May 13, 2021
@XSAM XSAM deleted the allow-root branch May 13, 2021 01:33
@XSAM XSAM mentioned this pull request May 13, 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.

sql.conn.reset_session
1 participant