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

Add possibility to split oversized udp batches #1500

Merged
merged 3 commits into from
Mar 8, 2021

Conversation

janLo
Copy link
Contributor

@janLo janLo commented Dec 22, 2020

Description

If we use the BatchExportSpanProcessor combined with the
JaegerSpanExporter and use instrumentations that add a lot of metadata
to the spans like sqlalchemy, then we run occationally into the "Data
exceeds the max UDP packet size" warning causing dropped spans and
incomplete data.

The option to reduce the general batch-size to a very small number (in
my case >30) may cause a performance issue as the worker thread of the
batch exporter gets very busy. Instead this change allows the user to
ask the exporter to split oversized batches when they get detected and
send the splits separately instead of dropping them. Depending on the
usecase this is a better option than reducing the batch-size to a very
small value because every now and then they contain a couple of large
spans.

Type of change

  • New feature (non-breaking change which adds functionality)
  • This change requires a documentation update

How Has This Been Tested?

  • A unittest was added
  • Its running successfully in production

Does This PR Require a Contrib Repo Change?

  • Yes. - Link to PR:
  • No.

Checklist:

  • Followed the style guidelines of this project
  • Changelogs have been updated
  • Unit tests have been added
  • Documentation has been updated

@janLo janLo requested review from a team, aabmass and ocelotl and removed request for a team December 22, 2020 13:25
@linux-foundation-easycla
Copy link

linux-foundation-easycla bot commented Dec 22, 2020

CLA Signed

The committers are authorized under a signed CLA.

Copy link
Contributor

@codeboten codeboten left a comment

Choose a reason for hiding this comment

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

Thanks for the PR, it looks great. Just a couple of changes requested, please also add an entry to the changelog.

@codeboten
Copy link
Contributor

hey @janLo any chance you can take a look at the comments on this PR so we can get it merged?

@janLo
Copy link
Contributor Author

janLo commented Jan 21, 2021

Yes, sorry, I'm just very busy at the moment. It's on my list and I plan to get it finished ASAP.

@codeboten
Copy link
Contributor

Yes, sorry, I'm just very busy at the moment. It's on my list and I plan to get it finished ASAP.

No worries, thanks!

Base automatically changed from master to main January 29, 2021 16:49
@lzchen
Copy link
Contributor

lzchen commented Feb 19, 2021

@janLo
Any chance you are still working on this? The PR has been open for almost 2 months now.

@janLo
Copy link
Contributor Author

janLo commented Feb 19, 2021

I hope to get to it next week.

@janLo janLo force-pushed the jaeger-split-batches branch 2 times, most recently from 7e0e58d to 1e654bd Compare February 26, 2021 13:44
janLo added a commit to janLo/opentelemetry-specification that referenced this pull request Feb 26, 2021
This adds OTEL_EXPORTER_JAEGER_AGENT_SPLIT_OVERSIZED_BATCHES to 
the Jaeger exporter as porposed in 
open-telemetry/opentelemetry-python#1500
@janLo janLo force-pushed the jaeger-split-batches branch 6 times, most recently from 267544e to 99abed7 Compare February 26, 2021 17:27
@janLo
Copy link
Contributor Author

janLo commented Feb 26, 2021

Sorry for the noise, I haven't had a working python env at hand today.

I fixed the mentioned issues and rebased everything on main. I also added a changelog entry and made a PR in the mentioned documentation repo: open-telemetry/opentelemetry-specification#1475

If we use the BatchExportSpanProcessor combined with the
JaegerSpanExporter and use instrumentations that add a lot of metadata
to the spans like sqlalchemy, then we run occationally into the "Data
exceeds the max UDP packet size" warning causing dropped spans and
incomplete data.

The option to reduce the general batch-size to a very small number (in
my case >30) may cause a performance issue as the worker thread of the
batch exporter gets very busy. Instead this change allows the user to
ask the exporter to split oversized batches when they get detected and
send the splits separately instead of dropping them. Depending on the
usecase this is a better option than reducing the batch-size to a very
small value because every now and then they contain a couple of large
spans.
@janLo
Copy link
Contributor Author

janLo commented Mar 4, 2021

Can I somehow rerun teh failed check? I don't think it has anything to do with my changes.

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.

5 participants