7 Replies Latest reply on Jul 30, 2007 7:30 PM by Igor Shabalov

    start with richfaces and netbeans

    Mario Ramos Newbie

      i´m trying to start an application in netbeans but always shows a page with "The requested resource () is not available." error message.

      i added the beanutils, collections, digester and loggging libraries.

      what can i do?, where can i find a good tutorial about richfaces?

        • 1. Re: start with richfaces and netbeans
          Igor Shabalov Apprentice

          Do you have any stacktrace somewhere in a log file?

          • 2. Re: start with richfaces and netbeans
            Mario Ramos Newbie

            DetailsTimestamp: 30-jul-2007 16:49:03.343
            Log Level: SEVERE
            Logger: javax.enterprise.system.container.web
            Name-Value Pairs: _ThreadID=11;_ThreadName=httpWorkerThread-4848-0;_RequestID=2f088768-aa74-40b3-91d5-91d016a1f9fd;
            Record Number: 984
            Message ID: WebModule[/WebApplication3]Exception starting filter ajax4jsf java.lang.NoClassDefFoundError

            • 3. Re: start with richfaces and netbeans
              Mario Ramos Newbie

              the WEB.xml is:

              <?xml version="1.0" encoding="UTF-8"?>
              <web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
              <context-param>
              <param-name>com.sun.faces.verifyObjects</param-name>
              <param-value>false</param-value>
              </context-param>
              <context-param>
              <param-name>com.sun.faces.validateXml</param-name>
              <param-value>true</param-value>
              </context-param>
              <context-param>
              <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
              <param-value>client</param-value>
              </context-param>
              <context-param>
              <param-name>org.ajax4jsf.SKIN</param-name>
              <param-value>blueSky</param-value>
              </context-param>

              <display-name>Ajax4jsf Filter</display-name>
              <filter-name>ajax4jsf</filter-name>
              <filter-class>org.ajax4jsf.Filter</filter-class>

              <filter-mapping>
              <filter-name>ajax4jsf</filter-name>
              <servlet-name>Faces Servlet</servlet-name>
              REQUEST
              FORWARD
              INCLUDE
              </filter-mapping>

              <servlet-name>Faces Servlet</servlet-name>
              <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
              <load-on-startup>1</load-on-startup>

              <servlet-mapping>
              <servlet-name>Faces Servlet</servlet-name>
              <url-pattern>/faces/*</url-pattern>
              </servlet-mapping>
              <session-config>
              <session-timeout>
              30
              </session-timeout>
              </session-config>
              <welcome-file-list>
              <welcome-file>faces/welcomeJSF.jsp</welcome-file>
              </welcome-file-list>
              </web-app>

              • 4. Re: start with richfaces and netbeans
                Igor Shabalov Apprentice

                Do you have any more lines in exception java.lang.NoClassDefFoundError
                The vital information is what class is missing or from what row that exception was thrown.
                But something is definitely missing from a classpath.

                • 5. Re: start with richfaces and netbeans
                  Mario Ramos Newbie

                  this is the complete message :

                  org/apache/commons/collections/map/LRUMap at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:620) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124) at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:1955) at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:945) at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1411) at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1275) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319) at org.ajax4jsf.cache.LRUMapCacheFactory.createCache(LRUMapCacheFactory.java:49) at org.ajax4jsf.framework.resource.InternetResourceService.init(InternetResourceService.java:106) at org.ajax4jsf.framework.ajax.xmlfilter.BaseFilter.init(BaseFilter.java:149) at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:239) at org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:333) at org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:89) at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4104) at org.apache.catalina.core.StandardContext.start(StandardContext.java:4765) at com.sun.enterprise.web.WebModule.start(WebModule.java:292) at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1095) at org.apache.catalina.core.StandardHost.start(StandardHost.java:907) at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1095) at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:520) at org.apache.catalina.startup.Embedded.start(Embedded.java:920) at com.sun.enterprise.web.WebContainer.start(WebContainer.java:784) at com.sun.enterprise.web.PEWebContainer.startInstance(PEWebContainer.java:722) at com.sun.enterprise.web.PEWebContainerLifecycle.onStartup(PEWebContainerLifecycle.java:72) at com.sun.enterprise.server.ondemand.ServiceGroup.startLifecycleServices(ServiceGroup.java:266) at com.sun.enterprise.server.ondemand.WebServiceGroup.startLifecycleServices(WebServiceGroup.java:210) at com.sun.enterprise.server.ondemand.WebServiceGroup.start(WebServiceGroup.java:60) at com.sun.enterprise.server.ondemand.ServiceGroup$1.run(ServiceGroup.java:180) at java.security.AccessController.doPrivileged(Native Method) at com.sun.enterprise.server.ondemand.ServiceGroup.startChildren(ServiceGroup.java:177) at com.sun.enterprise.server.ondemand.MainServiceGroup.start(MainServiceGroup.java:45) at com.sun.enterprise.server.ondemand.ServerEntryListenerImpl.notifyEntry(ServerEntryListenerImpl.java:72) at com.sun.enterprise.server.ondemand.entry.ServerEntryHelper.sendEvent(ServerEntryHelper.java:62) at com.sun.enterprise.server.ondemand.entry.ServerEntryHelper.generateAppLoaderEntryContext(ServerEntryHelper.java:47) at com.sun.enterprise.server.AbstractLoader.generateEntryContext(AbstractLoader.java:827) at com.sun.enterprise.server.AbstractLoader.notifyAppEvent(AbstractLoader.java:833) at com.sun.enterprise.server.DummyWebModuleLoader.load(DummyWebModuleLoader.java:62) at com.sun.enterprise.server.AbstractManager.load(AbstractManager.java:206) at com.sun.enterprise.server.ApplicationLifecycle.onStartup(ApplicationLifecycle.java:201) at com.sun.enterprise.server.ApplicationServer.onStartup(ApplicationServer.java:326) at com.sun.enterprise.server.ondemand.OnDemandServer.onStartup(OnDemandServer.java:112) at com.sun.enterprise.server.PEMain.run(PEMain.java:326) at com.sun.enterprise.server.PEMain.main(PEMain.java:260) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at com.sun.enterprise.server.PELaunch.main(PELaunch.java:272)

                  • 6. Re: start with richfaces and netbeans
                    Igor Shabalov Apprentice

                    Apache common collections is missing.

                    Here is list of dependecies in case of Tomcat5.5/JSF1.2/Faceletes/FastFilter
                    commons-beanutils-1.7.0.jar
                    commons-collections-3.2.jar
                    commons-digester-1.8.jar
                    commons-logging-1.0.4.jar
                    el-api-1.0.jar
                    el-impl-1.0.jar
                    jsf-api-1.1_02.jar
                    jsf-facelets-1.1.12.jar
                    jsf-impl-1.1_02.jar
                    jstl-1.0.jar
                    nekohtml-0.9.5.jar
                    richfaces-api-3.1.0-SNAPSHOT.jar
                    richfaces-impl-3.1.0-SNAPSHOT.jar
                    richfaces-ui-3.1.0-SNAPSHOT.jar
                    xercesImpl-2.4.0.jar

                    It *may* be variation in other environments.

                    • 7. Re: start with richfaces and netbeans
                      Igor Shabalov Apprentice

                      I guess you are on Glassfish?I will recommend you to add jars one-by-one and see when it will works. Plus I will recommend you to use FastFilter - that may be mucg faster on big pages. Plus I will recommend you to switch to server state saving - that will keep page size much smaller (again huge performance gain).