-
Notifications
You must be signed in to change notification settings - Fork 3
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
feat(octetcounting): re-use readers #18
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Signed-off-by: sinkingpoint <[email protected]>
leodido
approved these changes
Sep 18, 2024
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.
LGTM!
codeboten
referenced
this pull request
in open-telemetry/opentelemetry-collector-contrib
Sep 24, 2024
…35398) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [github.com/leodido/go-syslog/v4](https://redirect.github.com/leodido/go-syslog) | `v4.1.0` -> `v4.2.0` | [![age](https://developer.mend.io/api/mc/badges/age/go/github.com%2fleodido%2fgo-syslog%2fv4/v4.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/go/github.com%2fleodido%2fgo-syslog%2fv4/v4.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/go/github.com%2fleodido%2fgo-syslog%2fv4/v4.1.0/v4.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/go/github.com%2fleodido%2fgo-syslog%2fv4/v4.1.0/v4.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | --- > [!WARNING] > Some dependencies could not be looked up. Check the Dependency Dashboard for more information. --- ### Release Notes <details> <summary>leodido/go-syslog (github.com/leodido/go-syslog/v4)</summary> ### [`v4.2.0`](https://redirect.github.com/leodido/go-syslog/releases/tag/v4.2.0) [Compare Source](https://redirect.github.com/leodido/go-syslog/compare/v4.1.0...v4.2.0) <!-- Release notes generated using configuration in .github/release.yml at v4.2.0 --> #### What's Changed ##### Features & Enhancements 🎉 - feat(octetcounting): re-use readers by [@​sinkingpoint](https://redirect.github.com/sinkingpoint) in [https://github.com/leodido/go-syslog/pull/18](https://redirect.github.com/leodido/go-syslog/pull/18) ##### Other Changes 🫶 - docs: fix link for octect counting section in the RFC by [@​palash25](https://redirect.github.com/palash25) in [https://github.com/leodido/go-syslog/pull/17](https://redirect.github.com/leodido/go-syslog/pull/17) #### New Contributors - [@​palash25](https://redirect.github.com/palash25) made their first contribution in [https://github.com/leodido/go-syslog/pull/17](https://redirect.github.com/leodido/go-syslog/pull/17) - [@​sinkingpoint](https://redirect.github.com/sinkingpoint) made their first contribution in [https://github.com/leodido/go-syslog/pull/18](https://redirect.github.com/leodido/go-syslog/pull/18) **Full Changelog**: leodido/go-syslog@v4.1.0...v4.2.0 </details> --- ### Configuration 📅 **Schedule**: Branch creation - "on tuesday" (UTC), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/open-telemetry/opentelemetry-collector-contrib). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOC44MC4wIiwidXBkYXRlZEluVmVyIjoiMzguODAuMCIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOlsiZGVwZW5kZW5jaWVzIiwicmVub3ZhdGVib3QiXX0=--> --------- Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: opentelemetrybot <[email protected]> Co-authored-by: Yang Song <[email protected]> Co-authored-by: Alex Boten <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Solves #16
This adds a
sync.Pool
that storesbufio.Reader
s that can be re-used across messages. Previously, we were creating a new bufio.Reader for each new message. This allocates a buffer and results in amalloc
call for each new message which can be very inefficient in high throughput environments. By introducing a sync.Pool we are able to re-use those allocations across multiple messages, dramatically reducing the cpu hit.