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

Magento CRON Job Names are missing in NewRelic: "Transaction Names" #22047

Closed
PiotrSiejczuk opened this issue Mar 29, 2019 · 10 comments
Closed
Assignees
Labels
Component: NewRelicReporting Fixed in 2.3.x The issue has been fixed in 2.3 release line Fixed in 2.4.x The issue has been fixed in 2.4-develop branch Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed

Comments

@PiotrSiejczuk
Copy link

Preconditions (*)

  1. Magento 2.1.x or 2.2.x or 2.3.x OpenSource / Commerce / Cloud
  2. Correctly Configured Magento CRON Jobs
  3. Issue Details: Transactions named /index.php or /unknown

Steps to reproduce (*)

  1. Any Magento CRON Job Executed via Standard Scheduler
  2. Any Magento CRON Job Executed via CLI Command
  3. Check NewRelic APM Monitoring - Transactions. Check below Screenshot to see the unwanted situation:

NewRelic-UnknownTraces-ActualResult

Expected result (*)

  1. NewRelic APM showing exact CRON Job Code as Names within Transaction Traces
  2. Number of unknown transaction percentage should get reduced
  3. Improved Trace-ability of Transactions for Performance Review Operations

NewRelic-UnknownTraces-ExpectedResult

Above screen has 2 transactions "hidden" with white box and red border due to project specific names and data that cannot be desclousered

Actual result (*)

  1. NewRelic shows unknown transaction in Transaction Traces

NewRelic-UnknownTraces-ActualResult

@m2-assistant
Copy link

m2-assistant bot commented Mar 29, 2019

Hi @PiotrSiejczuk. Thank you for your report.
To help us process this issue please make sure that you provided the following information:

  • Summary of the issue
  • Information on your environment
  • Steps to reproduce
  • Expected and actual results

Please make sure that the issue is reproducible on the vanilla Magento instance following Steps to reproduce. To deploy vanilla Magento instance on our environment, please, add a comment to the issue:

@magento-engcom-team give me 2.3-develop instance - upcoming 2.3.x release

For more details, please, review the Magento Contributor Assistant documentation.

@PiotrSiejczuk do you confirm that you was able to reproduce the issue on vanilla Magento instance following steps to reproduce?

  • yes
  • no

@magento-engcom-team magento-engcom-team added the Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed label Mar 29, 2019
@lbajsarowicz
Copy link
Contributor

I think that's great issue for tomorrow Magento Contribution Day with @magento/strix

Extra information:
https://docs.newrelic.com/docs/agents/php-agent/troubleshooting/transactions-named-indexphp-or-unknown

@PiotrSiejczuk
Copy link
Author

@lbajsarowicz that is indeed the idea for this ticket :) Will pick it up and hopefully fix it in a few hours :)

@lbajsarowicz
Copy link
Contributor

Question to @PiotrSiejczuk and @maghamed - what should be the depth of the NewRelic descriptions:

I've done some PoC
Screenshot 2019-03-30 at 12 17 46

@lbajsarowicz
Copy link
Contributor

lbajsarowicz commented Mar 30, 2019

Created PR #22059 for CLI commands.

I'm not sure if we can achieve something that @PiotrSiejczuk asked, as usually Cron Jobs are ran in groups and I'm not sure if one PHP execution can contain multiple transactions. So that... I just added transaction name based on CLI command name.

Screenshot 2019-03-30 at 14 28 09

I'm doing investigation if we can have multiple transactions in one runtime.

@PiotrSiejczuk
Copy link
Author

I am an old school guy, so, there is a Patch for normal CRON Flows:

patch -p0 < Magento2.3.x-NewRelicCRONTransactionTrackingPatch.patch

Magento2.3.x-NewRelicCRONTransactionTrackingPatch.zip

I am going to create a PR in a few moment too

@ghost ghost assigned PiotrSiejczuk Mar 30, 2019
PiotrSiejczuk added a commit to PiotrSiejczuk/magento2 that referenced this issue Mar 30, 2019
@ghost ghost self-assigned this Apr 1, 2019
@m2-assistant
Copy link

m2-assistant bot commented Apr 1, 2019

Hi @engcom-backlog-nazar. Thank you for working on this issue.
In order to make sure that issue has enough information and ready for development, please read and check the following instruction: 👇

  • 1. Verify that issue has all the required information. (Preconditions, Steps to reproduce, Expected result, Actual result).

    DetailsIf the issue has a valid description, the label Issue: Format is valid will be added to the issue automatically. Please, edit issue description if needed, until label Issue: Format is valid appears.

  • 2. Verify that issue has a meaningful description and provides enough information to reproduce the issue. If the report is valid, add Issue: Clear Description label to the issue by yourself.

  • 3. Add Component: XXXXX label(s) to the ticket, indicating the components it may be related to.

  • 4. Verify that the issue is reproducible on 2.3-develop branch

    Details- Add the comment @magento-engcom-team give me 2.3-develop instance to deploy test instance on Magento infrastructure.
    - If the issue is reproducible on 2.3-develop branch, please, add the label Reproduced on 2.3.x.
    - If the issue is not reproducible, add your comment that issue is not reproducible and close the issue and stop verification process here!

  • 5. Verify that the issue is reproducible on 2.2-develop branch.

    Details- Add the comment @magento-engcom-team give me 2.2-develop instance to deploy test instance on Magento infrastructure.
    - If the issue is reproducible on 2.2-develop branch, please add the label Reproduced on 2.2.x

  • 6. Add label Issue: Confirmed once verification is complete.

  • 7. Make sure that automatic system confirms that report has been added to the backlog.

@ghost ghost added Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed Component: NewRelicReporting labels Apr 1, 2019
@ghost ghost removed their assignment Apr 1, 2019
@magento-engcom-team magento-engcom-team added the Fixed in 2.3.x The issue has been fixed in 2.3 release line label Apr 26, 2019
@magento-engcom-team
Copy link
Contributor

Hi @PiotrSiejczuk. Thank you for your report.
The issue has been fixed in #22059 by @lbajsarowicz in 2.3-develop branch
Related commit(s):

The fix will be available with the upcoming 2.3.2 release.

magento-engcom-team added a commit that referenced this issue Apr 26, 2019
…ame #22059

 - Merge Pull Request #22059 from lbajsarowicz/magento2:feature/newrelic-cli-transaction-name
 - Merged commits:
   1. a1661a5
   2. 07f8a65
   3. 638b73a
   4. bb861cc
   5. 9cd00fa
@PiotrSiejczuk
Copy link
Author

Hi @magento-engcom-team, thank you for your information. Although commits from @lbajsarowicz are not addressing the whole scope of the reported issue. It is perfect that CLI CRON commands are being correctly Tracked @ NewRelic now. Although it is not tracking correctly ATOMIC Transactions executed within standard CRON execution. That being said: this ticket should not be CLOSED as the FIX is not addressing the whole scope of the ISSUE described initially

@VladimirZaets VladimirZaets added the Fixed in 2.4.x The issue has been fixed in 2.4-develop branch label Dec 29, 2019
@VladimirZaets
Copy link
Contributor

Hi @PiotrSiejczuk. Thank you for your report.
The issue has been fixed in #25957 by @lbajsarowicz in 2.4-develop branch
Related commit(s):

The fix will be available with the upcoming 2.4.0 release.

This was referenced May 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: NewRelicReporting Fixed in 2.3.x The issue has been fixed in 2.3 release line Fixed in 2.4.x The issue has been fixed in 2.4-develop branch Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed
Projects
None yet
Development

No branches or pull requests

4 participants