使用 Apache CODI 评估 ResourceHandler 中的 ValueExpression

发布于 2025-01-06 04:58:48 字数 467 浏览 3 评论 0原文

我的 Web 应用程序在带有 Apache CODI 1.0.1 的 Websphere 8.0.0.2 上运行,我遇到了与 primefaces 的 ResourceHandler 实现相关的问题。

Primefaces 计算资源处理程序中的值表达式以检索动态内容,原因和方式并不重要。事实上,ResourceHandler 在 JSF 生命周期中的所有其他内容之前被调用。

我正在使用 ViewAccessScope 作为 bean,该 bean 应该使用 ResourceHandler 中的值表达式进行评估。我调试了一下,发现 ValueExpression 的 CODI-Wrapper 尝试检索 FacesContext 的视图根,或更准确地说是它的视图 id。问题是,此时视图根为 null,因此评估以 CODI 类中的 NullPointerException 结束。

谁负责这个问题,我应该在哪个问题跟踪器上发布错误? 我也很感激有关解决方法的建议:D

My Webapp is running on Websphere 8.0.0.2 with Apache CODI 1.0.1 and I have an issue related to the ResourceHandler implementation of primefaces.

Primefaces evaluates a value expression within the resource handler to retrieve dynamic content, why and how is not important. The fact is, that the ResourceHandler is called before everything else within the JSF Lifecycle.

I am using the ViewAccessScope for the bean which should be evaluated with the value expression within the ResourceHandler. I debugged into it and found out that the CODI-Wrapper for the ValueExpression tries to retriev the view root of the FacesContext or more exactly the view id of it. The problem is, that the view root is null at that time, so the evaluation ends with a NullPointerException in a CODI class.

Who is responsible for this issue, on which issue tracker should i post a bug?
I would also appreciate suggestions for workarounds :D

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

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

发布评论

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

评论(2

冬天旳寂寞 2025-01-13 04:58:49

CODI 类中的 NullPointerException。

如果 NullPointerException 不是由您作为最终用户可以控制的任何参数/变量引起的,并且它不是 < em>显式被代码抛出或断言,那么它可能是 CODI 类中的错误。向 CODI 报告。

a NullPointerException in a CODI class.

If the NullPointerException isn't caused by any of the arguments/variables which you, as enduser, can have control over, and it's not explicitly been thrown or asserted by the code, then it's likely a bug in the CODI class. Report it to CODI.

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