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

[Improvement] Replace raw use of RuntimeException #752

Closed
2 of 3 tasks
kaijchen opened this issue Mar 22, 2023 · 0 comments · Fixed by #753
Closed
2 of 3 tasks

[Improvement] Replace raw use of RuntimeException #752

kaijchen opened this issue Mar 22, 2023 · 0 comments · Fixed by #753

Comments

@kaijchen
Copy link
Contributor

Code of Conduct

Search before asking

  • I have searched in the issues and found no similar issues.

What would you like to be improved?

Raw use of RuntimeException is difficult to catch.
Because other runtime Exceptions will be catched as well.
We should avoid using raw RuntimeException.

How should we improve?

The simple solution is to replace RuntimeException with RssException.

The best solution is to replace RuntimeException with specific exception.
We might need to create new Exception class for more expressive.

Are you willing to submit PR?

  • Yes I am willing to submit a PR!
jerqi pushed a commit that referenced this issue Mar 22, 2023
### What changes were proposed in this pull request?

Replace raw use of `RuntimeException` with `RssException` in src/main.
Enable spotbugs check: [THROWS_METHOD_THROWS_RUNTIMEEXCEPTION][1]

[1]: https://spotbugs.readthedocs.io/en/stable/bugDescriptions.html#throws-method-intentionally-throws-runtimeexception-throws-method-throws-runtimeexception

### Why are the changes needed?

Fix: #752 

### Does this PR introduce _any_ user-facing change?

No.

### How was this patch tested?

Tested by spotbugs and existing tests.
xianjingfeng pushed a commit to xianjingfeng/incubator-uniffle that referenced this issue Apr 5, 2023
…ache#753)

### What changes were proposed in this pull request?

Replace raw use of `RuntimeException` with `RssException` in src/main.
Enable spotbugs check: [THROWS_METHOD_THROWS_RUNTIMEEXCEPTION][1]

[1]: https://spotbugs.readthedocs.io/en/stable/bugDescriptions.html#throws-method-intentionally-throws-runtimeexception-throws-method-throws-runtimeexception

### Why are the changes needed?

Fix: apache#752 

### Does this PR introduce _any_ user-facing change?

No.

### How was this patch tested?

Tested by spotbugs and existing tests.
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 a pull request may close this issue.

1 participant