Skip to content
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

Report Sidekiq jobs that call other jobs #2379

Open
kaylareopelle opened this issue Dec 22, 2023 · 3 comments
Open

Report Sidekiq jobs that call other jobs #2379

kaylareopelle opened this issue Dec 22, 2023 · 3 comments
Labels
3 Story Point Estimate feature request To tag feature request after Hero Triage for PM to disposition GTSE Issue associated with a previously logged support escalation oct-dec qtr Possible FY Q3 candidate

Comments

@kaylareopelle
Copy link
Contributor

Is your feature request related to a problem? Please describe.

The New Relic Ruby agent cannot accurately report on Sidekiq jobs that call other jobs.

For example, if I invoke the following code using OutsideJob.perform_later, InsideJob would be the name of the transaction, and OutsideJob would not appear as a transaction or as a segment within another transaction.

class OutsideJob < ApplicationJob
  queue_as :high

  def perform
    NewRelic::Agent::Tracer.start_transaction_or_segment(name: 'OutsideJob', category: :background) do
      puts "OutsideJob: start"
      InsideJob.perform_now
      puts "OutsideJob: finish"
    end
  end
end

class InsideJob < ApplicationJob
  queue_as :high

  def perform
    puts "InsideJob: start"
    sleep 1
    puts "InsideJob: finish"
  end
end

Feature Description

Sidekiq jobs that call other Sidekiq jobs are reported to New Relic.

Using the scenario above as an example, OutsideJob will be used as the root of a non-web transaction and InsideJob will be a segment/span nested within the OutsideJob transaction.

Describe Alternatives

If someone encounters this problem, try using custom instrumentation to set the correct transaction name. We suggest you explore:

However, we have not tested these APIs with this scenario, so YMMV.

Additional context

Internal - Slack

Priority

TBD

@kaylareopelle kaylareopelle added the feature request To tag feature request after Hero Triage for PM to disposition label Dec 22, 2023
@workato-integration
Copy link

@elucus elucus added the estimate Issue needing estimation label Jan 26, 2024
@kford-newrelic kford-newrelic added the apr-jun qtr Represents proposed work item for the Apr-Jun quarter label Feb 8, 2024
@kford-newrelic kford-newrelic added the GTSE Issue associated with a previously logged support escalation label Feb 16, 2024
@kaylareopelle
Copy link
Contributor Author

kaylareopelle commented Feb 16, 2024

Blocked by: #2195

This issue is scoped to setting up an integration test for this particular scenario once the work in #2195 is complete.

@kford-newrelic kford-newrelic added 3 Story Point Estimate and removed estimate Issue needing estimation labels Feb 16, 2024
@kford-newrelic kford-newrelic added jul-sep qtr Represents proposed work item for the Jul-Sep quarter and removed apr-jun qtr Represents proposed work item for the Apr-Jun quarter labels May 23, 2024
@kford-newrelic kford-newrelic added oct-dec qtr Possible FY Q3 candidate and removed jul-sep qtr Represents proposed work item for the Jul-Sep quarter labels Jun 11, 2024
@hannahramadan
Copy link
Contributor

Related to: #2835

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3 Story Point Estimate feature request To tag feature request after Hero Triage for PM to disposition GTSE Issue associated with a previously logged support escalation oct-dec qtr Possible FY Q3 candidate
Projects
Development

No branches or pull requests

4 participants