0

Has anyone around gotten Openfaces 3.0 to run on WebSphere 7.0?

I keep on getting the following error:

java.lang.NullPointerException
at javax.faces.application.ResourceWrapper.getRequestPath(ResourceWrapper.java:118)
at org.openfaces.application.OpenFacesResource.getRequestPath(OpenFacesResource.java:36)
at org.openfaces.util.Resources.getInternalURL(Resources.java:133)
at org.openfaces.util.Resources.getUtilJsURL(Resources.java:234)
at org.openfaces.util.UtilPhaseListener.appendHeaderContent(UtilPhaseListener.java:60)
at org.openfaces.application.OpenFacesApplication.headAddedToView(OpenFacesApplication.java:79)

Any ideas? Thanks in advance.

floshton.

floshton
  • 41
  • 4

1 Answers1

0

I don't do OpenFaces/Websphere, so I can't go in detail about this, but given the fact that ResourceWrapper#getRequestPath() delegates as per its source code the call as follows

return getWrapped().getRequestPath();

Where ResourceWrapper#getWrapped() is an abstract method which is to be implemented properly by the implementor. Given the trace, it's the org.openfaces.application.OpenFacesResource which is incorrectly returning null on getWrapped().

What the underlying cause is, is unclear since I don't have the hands on OpenFaces source code directly. I'd start by reporting this issue to the OpenFaces guys on their forum and/or issue tracker.

BalusC
  • 1,082,665
  • 372
  • 3,610
  • 3,555
  • First of all, thanks BalusC four your reply. I've seen you in a number of Stack Overflow posts and I am an avid follower of your blog. After a lot of research, I found out that OpenFaces 3.0 needs Mojarra 2.0.3 to run effectively, and I was using 2.0.2. So I just replaced the jar files and voila! I've been reading the Mojarra 2.0.3 Release Notes (http://javaserverfaces.java.net/nonav/rlnotes/2.0.3/whatsnew.html), but I am frankly not sure about the reason it now does work. Anyway, thanks a lot. floshton – floshton Feb 25 '11 at 23:32
  • You're welcome. Sicne you already solved the problem by yourself (upgrading to 2.0.3), you're obligated to repost this as an answer and then mark it accepted :) – BalusC Feb 25 '11 at 23:43