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

Skip any action on missing New Relic source segments. #5307

Merged
merged 3 commits into from
Apr 17, 2023

Conversation

janos-mands
Copy link
Contributor

🚨 IMPORTANT: Please do not create a Pull Request without creating an issue first.

Any change needs to be discussed before proceeding. Failure to do so may result in the rejection of
the pull request.

Description

Please include a summary of the change and which issue is fixed. Please also include relevant
motivation and context. List any dependencies that are required for this change.

Fixes # (issue)

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as
    expected)
  • This change requires a documentation update

Screenshots/Sandbox (if appropriate/relevant):

Adding links to sandbox or providing screenshots can help us understand more about this PR and take
action on it as appropriate

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can
reproduce. Please also list any relevant details for your test configuration

  • Test A
  • Test B

Test Environment:

  • OS:
  • @graphql-mesh/...:
  • NodeJS:

Checklist:

  • I have followed the
    CONTRIBUTING doc and the
    style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests and linter rules pass locally with my changes
  • Any dependent changes have been merged and published in downstream modules

Further comments

If this is a relatively large or complex change, kick off the discussion by explaining why you chose
the solution you did and what alternatives you considered, etc...

@changeset-bot
Copy link

changeset-bot bot commented Apr 6, 2023

🦋 Changeset detected

Latest commit: f5564c0

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@graphql-mesh/plugin-newrelic Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@ardatan
Copy link
Owner

ardatan commented Apr 6, 2023

Could you add a changeset using yarn changeset? Thanks!

@Urigo
Copy link
Collaborator

Urigo commented Apr 9, 2023

is there also a possible test that could cover that case to make sure it won't happen again?

@janos-mands
Copy link
Contributor Author

is there also a possible test that could cover that case to make sure it won't happen again?

@Urigo, that would be ideal, I agree, but I have not found any test for this plugin (pls let me know if I have missed it). This is a very small change, I would have been happy to add a test case for this change to the current tests, but would you mind if I do not set-up the tests for this plugin from scratch, so skip the test for this case, and rely on review only?

cc: @ardatan

@ardatan
Copy link
Owner

ardatan commented Apr 17, 2023

I think we can add tests later but still we need to make the reason clear. @janos-mands if you have any clue how to reproduce it clearly, please let us know.

@ardatan ardatan merged commit f36c6c2 into ardatan:master Apr 17, 2023
@janos-mands
Copy link
Contributor Author

@ardatan This situation happens a few percentage (<1%) of the requests for us in production, that I could not reproduce locally yet. It is just assumed that there is some problem with the new relic agent instrumentation,and so the transaction could not be created for those scenarios. Based on my analysis, it seems that the same query passes most of the times and fails in a small percentage only, so the code execution should be the same, and so the error should not depend on which code branch was executed, but probably due to some race condition.

Luckily the stack trace gave a clean hint how we could prevent exception in this code, when the transaction could not be created, but it is much more difficult to figure out why the transaction is not created in these cases. I have reported it to New Relic Support as well. I'll get back to you if they find something.

@ardatan
Copy link
Owner

ardatan commented Apr 19, 2023

Thank you @janos-mands 🙏

@theguild-bot theguild-bot mentioned this pull request Apr 24, 2023
This was referenced Apr 30, 2024
This was referenced May 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants