Re: Upgraded to 3.3.2 from 3.3.0; Failed to load configuration

Splash Forums PrettyFaces Users Upgraded to 3.3.2 from 3.3.0; Failed to load configuration Re: Upgraded to 3.3.2 from 3.3.0; Failed to load configuration

#21561

Thanks for sending the logs. I cannot find any reason my the NPE is suddenly thrown. The most interesting part of the log file is this:

<WebClassesFinder> <processDirectory> Processing directory: file:/Users/clemmonsm/.jdeveloper/system11.1.1.5.37.60.13/o.j2ee/drs/dreeshomes/ViewControllerWebApp.war/WEB-INF/classes/
<WebClassesFinder> <processDirectory> Processing directory: file:/Users/clemmonsm/.jdeveloper/system11.1.1.5.37.60.13/o.j2ee/drs/dreeshomes/ViewControllerWebApp.war/WEB-INF/classes/META-INF/
<WebClassesFinder> <processDirectory> Processing directory: file:/Users/clemmonsm/.jdeveloper/system11.1.1.5.37.60.13/o.j2ee/drs/dreeshomes/ViewControllerWebApp.war/WEB-INF/classes/model/
<WebClassesFinder> <processDirectory> Processing directory: file:/Users/clemmonsm/.jdeveloper/system11.1.1.5.37.60.13/o.j2ee/drs/dreeshomes/ViewControllerWebApp.war/WEB-INF/classes/gr/
<WebClassesFinder> <processDirectory> Processing directory: file:/Users/clemmonsm/.jdeveloper/system11.1.1.5.37.60.13/o.j2ee/drs/dreeshomes/ViewControllerWebApp.war/WEB-INF/classes/gr/dim/
<WebClassesFinder> <processDirectory> Processing directory: file:/Users/clemmonsm/.jdeveloper/system11.1.1.5.37.60.13/o.j2ee/drs/dreeshomes/ViewControllerWebApp.war/WEB-INF/classes/gr/dim/stas/
<WebClassesFinder> <processDirectory> Processing directory: file:/Users/clemmonsm/.jdeveloper/system11.1.1.5.37.60.13/o.j2ee/drs/dreeshomes/ViewControllerWebApp.war/WEB-INF/classes/gr/dim/stas/view/
<WebClassesFinder> <processDirectory> Processing directory: file:/Users/clemmonsm/.jdeveloper/system11.1.1.5.37.60.13/o.j2ee/drs/dreeshomes/ViewControllerWebApp.war/WEB-INF/classes/gr/dim/stas/view/utils/
<Nov 15, 2011 3:53:42 PM EST> <Error> <HTTP> <BEA-101165> <Could not load user defined filter in web.xml: com.ocpsoft.pretty.PrettyFilter.
com.ocpsoft.pretty.PrettyException: Failed to load configuration.
at com.ocpsoft.pretty.faces.config.PrettyConfigurator.configure(PrettyConfigurator.java:90)
at com.ocpsoft.pretty.PrettyFilter.init(PrettyFilter.java:316)
at weblogic.servlet.internal.FilterManager$FilterInitAction.run(FilterManager.java:332)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
Truncated. see log file for complete stacktrace
Caused By: java.lang.NullPointerException
at com.ocpsoft.pretty.faces.config.annotation.WebClassesFinder.processDirectory(WebClassesFinder.java:117)
at com.ocpsoft.pretty.faces.config.annotation.WebClassesFinder.processDirectory(WebClassesFinder.java:193)
at com.ocpsoft.pretty.faces.config.annotation.WebClassesFinder.processDirectory(WebClassesFinder.java:193)
at com.ocpsoft.pretty.faces.config.annotation.WebClassesFinder.processDirectory(WebClassesFinder.java:193)
at com.ocpsoft.pretty.faces.config.annotation.WebClassesFinder.processDirectory(WebClassesFinder.java:193)
Truncated. see log file for complete stacktrace
>

The problems seems to be that the following method call returns null:

servletContext.getResourcePaths("/WEB-INF/classes/gr/dim/stas/view/utils/");

This is really very strange. Anything special about that package?

I committed a minor fix yesterday that will simply ignore directories for which getResourcePaths() returns null (to prevent the NPE). Could you perhaps give “3.3.2-SNAPSHOT” a try. Don’t be confused by the version numbers. The snapshot should actually be named “3.3.3-SNAPSHOT” but we didn’t update the version numbers till now. So simply use “3.3.2-SNAPSHOT” for the moment. You can find all details on how to use the snapshots here:

https://github.com/ocpsoft/prettyfaces/wiki/Snapshots

Looking forward to hear about your results.

Christian