Skip to content

Conversation

@stebet
Copy link
Contributor

@stebet stebet commented May 25, 2020

Proposed Changes

This PR fixes those cases where exceptions were rethrown in a way that polluted the stackframes, making debugging/troubleshooting harder.

This is in line with the .NET guidelines on rethrowing exceptions:
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca2200?view=vs-2019
https://docs.microsoft.com/en-us/archive/msdn-magazine/2015/november/essential-net-csharp-exception-handling#throwing-existing-exceptions-without-replacing-stack-information

Types of Changes

  • Bug fix (non-breaking change)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause an observable behavior change in existing systems)
  • Documentation improvements (corrections, new content, etc)
  • Cosmetic change (whitespace, formatting, etc)

Checklist

  • I have read the CONTRIBUTING.md document
  • I have signed the CA (see https://cla.pivotal.io/sign/rabbitmq)
  • All tests pass locally with my changes
  • I have added tests that prove my fix is effective or that my feature works
  • I have added necessary documentation (if appropriate)
  • Any dependent changes have been merged and published in related repositories

@michaelklishin michaelklishin merged commit 81cfa56 into rabbitmq:master May 26, 2020
michaelklishin added a commit that referenced this pull request May 26, 2020
Fixing rethrown exceptions to properly preserve stackframes.

(cherry picked from commit 81cfa56)
@michaelklishin
Copy link
Contributor

Backported to 6.x.

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.

2 participants