Skip to content

Commit

Permalink
fix(active-job): Prefix ::ActiveSupport when installing the instrumen…
Browse files Browse the repository at this point in the history
…tation (#1120)

fix(active-job) Prefix ::ActiveSupport when installing the instrumentation

Otherwise, `ActiveSupport` ends up resolving to `OpenTelemetry::Instrumentation::ActiveSupport`.

`OpenTelemetry::Instrumentation::Registry#install_instrumentation` rescues the exception, so the prepend ends up being (somewhat) silently dropped.
  • Loading branch information
lavoiesl authored Aug 15, 2024
1 parent f5f8375 commit c51c0ee
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ def require_dependencies
def patch_activejob
Handlers.subscribe

ActiveSupport.on_load(:active_job) do
::ActiveSupport.on_load(:active_job) do
::ActiveJob::Base.prepend(Patches::Base) unless ::ActiveJob::Base <= Patches::Base
end
end
Expand Down

0 comments on commit c51c0ee

Please sign in to comment.