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

Update BoundedMemoryQueue to consume remaining items on close #5203

Merged
merged 7 commits into from
Apr 14, 2022

Conversation

TylerHelmuth
Copy link
Member

Description:
This PR updated the BoundedMemoryQueue to consume any remaining items on shutdown. The timing of the colsure of the items queue during Stop() has been moved up so that items in the queue can be consumed in a non-blocking way.

Link to tracking Issue:
Fixes #5110

Testing:
Unit Tests

@TylerHelmuth TylerHelmuth requested review from a team and bogdandrutu April 13, 2022 17:30
@codecov
Copy link

codecov bot commented Apr 13, 2022

Codecov Report

Merging #5203 (7ba3428) into main (70e040a) will increase coverage by 0.04%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main    #5203      +/-   ##
==========================================
+ Coverage   90.34%   90.39%   +0.04%     
==========================================
  Files         187      187              
  Lines       11079    11051      -28     
==========================================
- Hits        10009     9989      -20     
+ Misses        844      839       -5     
+ Partials      226      223       -3     
Impacted Files Coverage Δ
...er/exporterhelper/internal/bounded_memory_queue.go 87.71% <100.00%> (+3.89%) ⬆️
service/config_provider.go 92.24% <0.00%> (+2.01%) ⬆️

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 70e040a...7ba3428. Read the comment docs.

@TylerHelmuth TylerHelmuth changed the title Issue 5110 Update BoundedMemoryQueue to consume remaining items on close Apr 13, 2022
@bogdandrutu
Copy link
Member

@TylerHelmuth please add a changelog entry.

@bogdandrutu bogdandrutu merged commit 2afc5e7 into open-telemetry:main Apr 14, 2022
@TylerHelmuth TylerHelmuth deleted the issue-5110 branch April 14, 2022 20:01
Nicholaswang pushed a commit to Nicholaswang/opentelemetry-collector that referenced this pull request Jun 7, 2022
…elemetry#5203)

* BoundedMemoryQueue now consumes on close

* Add back !ok return

* Removed stopCh

* Cleanup

* Updated CHANGELOG.md
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.

Question about shutdown the queuedRetrySender
2 participants