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

Protect against stackoverflow when printing advice exceptions #3159

Merged
merged 7 commits into from Jun 7, 2023

Conversation

JonasKunz
Copy link
Contributor

@JonasKunz JonasKunz commented Jun 1, 2023

What does this PR do?

Tries to mitigate #3152 .

Checklist

  • This is a bugfix
    • I have updated CHANGELOG.asciidoc
    • I have added tests that would fail without this fix not feasible to produce a StackOverflow in a test while keeping the system in a known state.

@elastic-apm-tech elastic-apm-tech added this to In Progress in APM-Agents (OLD) Jun 1, 2023
@JonasKunz JonasKunz added the ci:agent-integration Enables agent integration tests in build pipeline label Jun 1, 2023
@apmmachine
Copy link
Collaborator

apmmachine commented Jun 1, 2023

💚 Build Succeeded

the below badges are clickable and redirect to their specific view in the CI or DOCS
Pipeline View Test View Changes Artifacts preview previewSnapshots

Expand to view the summary

Build stats

  • Start Time: 2023-06-07T11:59:57.144+0000

  • Duration: 19 min 55 sec

❕ Flaky test report

No test was executed to be analysed.

🤖 GitHub comments

Expand to view the GitHub comments

To re-run your PR in the CI, just comment with:

  • /test : Re-trigger the build.

  • run benchmark tests : Run the benchmark tests.

  • run jdk compatibility tests : Run the JDK Compatibility tests.

  • run integration tests : Run the Agent Integration tests.

  • run end-to-end tests : Run the APM-ITs.

  • run windows tests : Build & tests on windows.

  • run elasticsearch-ci/docs : Re-trigger the docs validation. (use unformatted text in the comment!)

# Conflicts:
#	apm-agent-core/src/main/java/co/elastic/apm/agent/impl/ElasticApmTracer.java
@JonasKunz JonasKunz marked this pull request as ready for review June 6, 2023 07:34
@github-actions
Copy link

github-actions bot commented Jun 6, 2023

/test

@JonasKunz JonasKunz requested a review from a team June 6, 2023 07:47
…tstrapDispatcher.java

Co-authored-by: jackshirazi <jacks@fasterj.com>
@JonasKunz JonasKunz enabled auto-merge (squash) June 7, 2023 07:20
@JonasKunz JonasKunz disabled auto-merge June 7, 2023 07:46
Copy link
Contributor

@jackshirazi jackshirazi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fine without a test but, if you feel like it, you could add a test with a non-tail recursive call that logs on each call until it hits actual stack overflow and confirm the expected "should never happen"

@JonasKunz JonasKunz enabled auto-merge (squash) June 7, 2023 11:59
@JonasKunz JonasKunz merged commit 87b4c28 into elastic:main Jun 7, 2023
14 checks passed
APM-Agents (OLD) automation moved this from In Progress to Done Jun 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
agent-java ci:agent-integration Enables agent integration tests in build pipeline
Projects
Development

Successfully merging this pull request may close these issues.

None yet

3 participants