OpenWebbeans CDI 装饰器抛出 InspirationTargetException

发布于 2024-12-14 04:55:12 字数 131 浏览 5 评论 0原文

我有一个 CDI 装饰器,它调用委托,并且委托抛出一个自定义的异常。现在的问题是,它是在 throws 子句中声明的,但被包装在 InvocableTargetException 中,并且该方法的调用者永远不会知道真正的异常是什么。这有什么问题吗?

I have a CDI decorator which calls the delegate and the delegate throws a self defined exception. Now the problem is, that it is declared in the throws clause, but is wrapped within an InvocationTargetException and the caller of the method will never know what the real exception was. What is the problem about that?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

心舞飞扬 2024-12-21 04:55:12

几个这样的错误已经被解决,但如果存在这样的挥之不去的情况,即异常没有正确解包,我不会感到惊讶。我建议打开错误报告。

Several bugs like this have been shaken out, but I would not be surprised if there are lingering cases like this where exceptions are not properly unwrapped. I'd suggest opening a bug report.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文