Releases: DataDog/dogstatsd-ruby
Releases · DataDog/dogstatsd-ruby
v5.1.0 / 2021.06.17
- [FEATURE] Flush last metrics on Statsd#close #180 by @kbogtob
- [ENHANCEMENT] Do not try to flush where there is no available message_queue [#189][] by @remeh
- [OTHER] Add pry to development dependencies and enable gem in Gemfile #192 by @ivoanjo
- [OTHER] Expand Ruby Support to Rubies 2.6, 2.7, and 3.0 [#191][] by @laserlemon
Known issues
If the DogStatsD client is instantiated before a fork, the forked process won't copy the companion thread that the original client needs to flush and the client won't work properly. This issue will be addressed in an upcoming version. If you are concerned by this issue, please read this section of the README.
v5.0.1 / 2021.04.09
- [OTHER] Re-introduce a Statsd#batch method to help with compatibility with v4.x versions. #176 by @remeh
- It is deprecated and will be removed in v6.x
- It does not have the exact same behavior as the batch method from v4.x versions since the flush could now automatically occur while the batch block is executed if the buffer has been filled.
- [BUGFIX] Safely close concurrent resources on Sender #175 by @marcotc
v5.0.0 / 2021.04.07
API breaking changes
- This new major version uses automatic buffering with preemptive flushing, there is no need to manually batch the metrics together anymore. The preemptive flushing part means that just before the buffer gets full, a flush is triggered. Manual flush is still possible with the
Statsd#flush
method. TheStatsd#batch
method has been removed from the API. What would have been written this way with the v4 API:
require 'datadog/statsd'
statsd = Datadog::Statsd.new('127.0.0.1', 8125)
statsd.batch do |s|
s.increment('example_metric.increment', tags: ['environment:dev'])
s.gauge('example_metric.gauge', 123, tags: ['environment:dev'])
end
should be written this way with the v5 API:
require 'datadog/statsd'
statsd = Datadog::Statsd.new('127.0.0.1', 8125)
statsd.increment('example_metric.increment', tags: ['environment:dev'])
statsd.gauge('example_metric.gauge', 123, tags: ['environment:dev'])
# synchronous flush
statsd.flush(sync: true)
Statsd#initialize
parametermax_buffer_bytes
has been renamed tobuffer_max_payload_size
for consistency with the new automatic batch strategy. Please note the addition ofbuffer_max_pool_size
to limit the maximum amount of messages to buffer.
Commits
v4.8.3
v4.8.2
v4.8.1
v4.8.0
- [Feature] Add support of more environment variables for tagging #140 by @delner
- [OTHER] Small optimizations #139 by @tenderlove
- [BUGFIX] Properly close UDPSocket before creating a new one #143 by @zachmccormick
- [OTHER] Refactor to make code more idiomatic #138 by @kbogtob
- [OTHER] Refactor to translate unit tests to rspec #135 by @kbogtob
- [OTHER] Bump rake requirement to >= 12.3.3 #137 by @remeh