2

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

Christian Beikov
  • 15,141
  • 2
  • 32
  • 58

2 Answers2

0

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.

BalusC
  • 1,082,665
  • 372
  • 3,610
  • 3,555
  • I already did, the problem I see is that if a ResourceHandler is invoked, the JSF Lifecycle is not invoked at all. As far as I know the fact that the ViewRestore Phase is not invoked will break the functionallity of the ViewAccessScope. The problem is probably with the implementation of primefaces. – Christian Beikov Feb 16 '12 at 15:59
  • As I learned today it is not a bug of MyFaces CODI. I read http://myfaces.markmail.org/search/?q=#query:%20list%3Aorg.apache.myfaces.users+page:1+mid:kz6obow6nk3s7e34+state:results – Dar Whi Feb 16 '12 at 21:09