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

【Chaosblade-exec-jvm】use throwCustomException throws a custom exception, and the custom exception corresponding to catch cannot be caught in code. Is there any good solution for this #1061

Open
Light-long opened this issue Aug 9, 2024 · 0 comments

Comments

@Light-long
Copy link

Issue Description

I have written a plugin myself, which can implement the Exception throwing when calling xxx, and the exception thrown can be a subclass of java.lang. exception, for example:
./blade create xxx throwCustomException --pid 1 --exception com.xxx.CustomException --exception-message test
The current performance does throw an Exception, but I've found that if a catch CustomException isn't catch-able, only a catch Exception is

Describe what you expected to happen

Our purpose: When injecting CustomException, we can validate the downgrade by catching CustomException in our code
Do you have any good solutions?

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

No branches or pull requests

1 participant