-
Notifications
You must be signed in to change notification settings - Fork 95
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
allow BatchTimeout to be overriden on the libhoney Transmission #509
Conversation
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.
Looks great, thanks @leviwilson 🎉
Only thing missing is adding an example to the config_config.toml to show it being overriden.
done |
Thanks @leviwilson ! @MikeGoldsmith fyi someday there's a more interesting problem to solve here, of refinery noticing Honeycomb's rate-limiting errors and adapting. This change will go a long way toward letting people solve this problem themselves now. |
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.
Thanks @leviwilson 🎉
…ycombio#509) This PR allows for the BatchTimeout to be configured for refinery rather than explicitly using DefaultBatchTimeout from libhoney * allow BatchTimeout to be overridden on the libhoney Transmission * add an example of modifying BatchTimeout in config_complete.toml
Which problem is this PR solving?
We have an issue where our ALB traffic has a
~5m
latency because of the cadence in which the CloudWatch logs are sent. Because the ALB represents our top-level traces, this means that all web traffic is delayed by that same amount.Decreasing the
TraceTimeout
value assists with this by spreading out the traffic, however this makes our rules a moot point as things we are intentionally trying to downsample do not get downsampled.What we really need is a manner to control how frequently events are sent upstream to Honeycomb so we can control how frequently we send things. https://github.com/honeycombio/libhoney-go/blob/8af08e456cfe1f786247ffdc755855999add2d76/libhoney.go#L136 indicates that
SendFrequency
can override how often batches are sent.Short description of the changes
This PR allows for the
BatchTimeout
to be configured for refinery rather than explicitly usingDefaultBatchTimeout
. I realizeSendFrequency
is what was mentioned above, but refinery callsNewClient
rather thanInit
and you can see that allSendFrequency
does is driveBatchTimeout
on theTransmission
anyway.