-
Notifications
You must be signed in to change notification settings - Fork 30
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
Adds a new API that can customize the ingest sender. #742
Conversation
@breedx-splk this approach will cover the functionality of #739. Thank you! |
|
||
package com.splunk.rum.incubating; | ||
|
||
import zipkin2.reporter.okhttp3.OkHttpSender; |
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.
Shucks, I was hoping this might be forward-compatible if/when we move to OTLP....
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.
Well, headers can be specified through OtlpHttpSpanExporterBuilder.setHeaders()
and compression can be swizzled with OtlpHttpSpanExporterBuilder.setCompression()
.
These methods also exist on OtlpHttpLogRecordExporterBuilder
, so I think we'll be ok.
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
This allows users to get access to the guts of the Zipkin
OkHttpSender.Builder
in order to do things like add custom headers and control compression settings, etc. The sender used in both paths (with or without disk buffering) can be impacted by this customizer.It also includes a sample usage in the sample app.
This would ideally supersede #739. Thanks to @magdamagda for the original ideas and inspiration here.