Conversation
|
Thank you for updating Change log entry section 👏 Visited at: 2025-01-09 11:52:07 UTC |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #4253 +/- ##
==========================================
- Coverage 97.73% 97.73% -0.01%
==========================================
Files 1352 1352
Lines 82409 82464 +55
Branches 4224 4229 +5
==========================================
+ Hits 80545 80595 +50
- Misses 1864 1869 +5 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
|
||
| ### Kicks | ||
|
|
||
| The Kicks integration is a server-side middleware which will trace job executions. |
There was a problem hiding this comment.
| The Kicks integration is a server-side middleware which will trace job executions. | |
| The Kicks integration is a server-side middleware that traces job executions. |
There was a problem hiding this comment.
(I noticed most of these were copy-pasted from the sneakers docs, so we should probably propagate the improvements to both)
| The Kicks integration is a server-side middleware which will trace job executions. | ||
|
|
||
| <div class="alert alert-warning"> | ||
| Kicks is a continuation of Sneakers and both cannot be active at the same time, as they share their Ruby class namespace. Configurations to the Sneakers integration will be safely merged with any Kicks configuration. |
There was a problem hiding this comment.
| Kicks is a continuation of Sneakers and both cannot be active at the same time, as they share their Ruby class namespace. Configurations to the Sneakers integration will be safely merged with any Kicks configuration. | |
| Kicks is a continuation of Sneakers. Because Kicks and Sneakers share a Ruby class namespace, they cannot both be active at the same time. Configurations to the Sneakers integration is safely merged with any Kicks configuration. |
| | ---------- | - | ----- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------- | | ||
| | `enabled` | `DD_TRACE_SNEAKERS_ENABLED` | `Bool` | Whether the integration should create spans. | `true` | | ||
| | `tag_body` | | `Bool` | Enable tagging of job message. `true` for on, `false` for off. | `false` | | ||
| | `on_error` | | `Proc` | Custom error handler invoked when a job raises an error. Provided `span` and `error` as arguments. Sets error on the span by default. Useful for ignoring transient errors. | `proc { \|span, error\| span.set_error(error) unless span.nil? }` | |
There was a problem hiding this comment.
| | `on_error` | | `Proc` | Custom error handler invoked when a job raises an error. Provided `span` and `error` as arguments. Sets error on the span by default. Useful for ignoring transient errors. | `proc { \|span, error\| span.set_error(error) unless span.nil? }` | | |
| | `on_error` | | `Proc` | Custom error handler invoked when a job raises an error. Provides `span` and `error` as arguments. Sets error on the span by default. Useful for ignoring transient errors. | `proc { \|span, error\| span.set_error(error) unless span.nil? }` | |
| The Sneakers integration is a server-side middleware which will trace job executions. | ||
|
|
||
| <div class="alert alert-warning"> | ||
| Kicks is a continuation of Sneakers and both cannot be active at the same time, as they share their Ruby class namespace. Configurations to the Sneakers integration will be safely merged with any Kicks configuration. |
There was a problem hiding this comment.
| Kicks is a continuation of Sneakers and both cannot be active at the same time, as they share their Ruby class namespace. Configurations to the Sneakers integration will be safely merged with any Kicks configuration. | |
| Kicks is a continuation of Sneakers. Because Kicks and Sneakers share a Ruby class namespace, they cannot both be active at the same time. Configurations to the Sneakers integration is safely merged with any Kicks configuration. |
There was a problem hiding this comment.
I actually noticed that this file was still being ignored in the Steepfile, but can safely be enabled (passes typecheck), so may be worth including that in this PR ;)
| # @public_api Changing the integration name or integration options can cause breaking changes | ||
| register_as :sneakers, auto_patch: true | ||
|
|
||
| register_as_alias :sneakers, :kicks |
There was a problem hiding this comment.
I noticed that for register_as_alias the auto_patch is always false -- is that because it reuses the auto_patch from the register_as? (If so, maybe that's a useful comment to leave somewhere, perhaps in the register_as_alias?)
|
|
||
| ### Kicks | ||
|
|
||
| The Kicks integration is a server-side middleware which will trace job executions. |
There was a problem hiding this comment.
(I noticed most of these were copy-pasted from the sneakers docs, so we should probably propagate the improvements to both)
| gem 'roda', '>= 2.0.0' | ||
| gem 'semantic_logger', '~> 4.0' | ||
| gem 'sidekiq', '~> 7' | ||
| gem 'sneakers', '>= 2.12.0' |
There was a problem hiding this comment.
Should this change be propagated to the other appraisal files as well? Noticed the others still list sneakers under contrib
TonyCTHsu
left a comment
There was a problem hiding this comment.
I understand this approach to support kicks.
However, I am a little bit concern about
kicksgem decided to rename the modules and paths in the future- The span data is decorated with the obsolete name
sneakerscan cause confusion
I am overall supportive because (1) might not happen in the future and (2) we could make the risk explicit in the documentation.
I might even push to deprecate sneakers integration and replace it completely with kicks in the next major release.
| gem 'roda', '>= 2.0.0' | ||
| gem 'semantic_logger', '~> 4.0' | ||
| gem 'sidekiq', '~> 7' | ||
| gem 'sneakers', '>= 2.12.0' |
There was a problem hiding this comment.
@marcotc Do you struggle to remove sneakers from other runtimes? Do you need my help on this?
| # The first version of Kicks is 3.0.0. We currently support all versions of Kicks. | ||
| # | ||
| # @see https://github.com/jondot/sneakers/commit/9780692624c666b6db8266d2d5710f709cb0f2e2 | ||
| def self.version |
There was a problem hiding this comment.
They kept everything the same, even the file paths (require 'sneakers') and module names (::Sneakers).
kicks even continue the semantic version to avoid conflict with the obsolete gem.
Correct me if I am wrong. Due to this, I assume the easiest path to support kicks is to change self.version with the conditional logic of kicks from Gem.loaded_specs. Do we need register_as_alias to support kicks?
| build_coverage_matrix('opensearch', 2..3, gem: 'opensearch-ruby') | ||
| build_coverage_matrix('elasticsearch', 7..8) | ||
| build_coverage_matrix('kicks', [], min: '3.0.0') | ||
| build_coverage_matrix('sneakers', [], min: '2.12.0', latest: false) # Sneakers is not receiving updates anymore and 2.12.0 is the last version |
There was a problem hiding this comment.
I actually think we don't need to invoke build_coverage_matrix with latest: false, since this method call only generate a single group.
Prefer the following for explicitness
appraisal 'sneakers-min' do
gem 'sneakers', '= 2.12.0'
end| # @param [Hash] meta optional, additional metadata (development dependencies, etc.) for the group | ||
| def build_coverage_matrix(integration, range, gem: integration, min: nil, latest: true, meta: {}) | ||
| # Allow single version to be passed easily | ||
| range = range..range if range.is_a?(Integer) |
There was a problem hiding this comment.
| range = range..range if range.is_a?(Integer) | |
| range = Array(range) |
I'm guessing they would rename on a major version, so we'd probably want to support the 3.x series (with sneakers naming) for a while? Looking at their readme, it seems the main objective was "original author was unresponsive, community had a few pending patches": ...so yeah doesn't look like the kind of project that will refactor just for the sake of making the name prettier ;) |
|
Just wanted to give a nudge here that my team is eagerly waiting to use this as soon as you merge. |
|
This and any improvements would be helpful to have as we use Sneakers. We migrated to the Kicks gem which was a like for like change. It resulted in no code changes. Just swapping out the gem names in our Gemfile. Does this implement error tracking for Kicks? We use Datadog Error Tracking with a custom Sneakers error_reporters set but we are noticing the Datadog active_span is nil so Sneakers errors by default are not being reported in Datadog. |
|
@codex find critical bugs and corner cases |
|
Summary
Testing
|
|
Superceded by #5305 |

Fixes #4191
Kicks is a fork/continuation of the
sneakersgem (announcement).Change log entry
Yes. Add support for the
kicksgemAdditional Notes:
They kept everything the same, even the file paths (
require 'sneakers') and module names (::Sneakers).I created an alias for
instrument :kickstoinstrument :sneakers, to allow users to use the name that matches their installed gem name. They share the same internal objects and configuration settings.How to test the change?