JSF Error Tomcat NullPointer restart

I have developed an application in Tomcat55 and JSF, everything goes well
when I start for the first time Tomcat, the problem comes when a new update
on unemployment Tomcat, I introduce a new war in the webapp and restarted
the tomcat, reload does well but when I ask the web, I get this error.
[http-81-Processor25] ERROR
org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[SitioWeb].[j
sp]
- Servlet.service() para servlet jsp lanz� excepci�n
java.lang.NullPointerException
at
org.ajax4jsf.framework.ajax.AjaxViewHandler.createView(AjaxViewHandler.java:
78)
at
org.apache.myfaces.lifecycle.LifecycleImpl.restoreView(LifecycleImpl.java:14
4)
at org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:66)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:197)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
FilterChain.java:269)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java:188)
at
org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.
java:691)
at
org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDis
patcher.java:469)
at
org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatch
er.java:403)
at
org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher
java:301)
at
org.apache.jasper.runtime.PageContextImpl.doForward(PageContextImpl.java:686
at
org.apache.jasper.runtime.PageContextImpl.forward(PageContextImpl.java:656)
at org.apache.jsp.index_jsp._jspService(index_jsp.java:48)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:98)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:3
31)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
FilterChain.java:269)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java:188)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
va:213)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
va:174)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java
:108)
at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151)
at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:874)
at
org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processC
onnection(Http11BaseProtocol.java:665)
at
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.jav
a:528)
at
org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWo
rkerThread.java:81)
at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.jav
a:689)
at java.lang.Thread.run(Thread.java:595)
State and looking information and are no longer what might happen.
Edited by: Scra on Dec 17, 2007 9:37 AM

Doesn't look like a Sun JSF RI issue to me. Post this issue at the forum/mailinglist of Ajax4jsf.

Similar Messages

  • JSF error on Tomcat

    Hi I am getting a strange error when I deploy the war file for JSF on tomcat as follows 2006-12-01 10:19:51 StandardContext[/manager]HTMLManager: start: Starting web application at '/campman'
    2006-12-01 10:19:51 StandardContext[/campman]Exception sending context initialized event to listener instance of class com.sun.faces.config.ConfigureListener
    javax.faces.FacesException: com.sun.faces.lifecycle.LifecycleFactoryImpl
         at javax.faces.FactoryFinder.getImplGivenPreviousImpl(FactoryFinder.java:553)
         at javax.faces.FactoryFinder.getImplementationInstance(FactoryFinder.java:411)
         at javax.faces.FactoryFinder.getFactory(FactoryFinder.java:229)
         at com.sun.faces.config.ConfigureListener.configure(ConfigureListener.java:702)
         at com.sun.faces.config.ConfigureListener.configure(ConfigureListener.java:398)
         at com.sun.faces.config.ConfigureListener.contextInitialized(ConfigureListener.java:328)
         at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3827)
         at org.apache.catalina.core.StandardContext.start(StandardContext.java:4343)
         at org.apache.catalina.core.StandardHostDeployer.start(StandardHostDeployer.java:830)
         at org.apache.catalina.core.StandardHost.start(StandardHost.java:991)
         at org.apache.catalina.manager.ManagerServlet.start(ManagerServlet.java:1322)
         at org.apache.catalina.manager.HTMLManagerServlet.start(HTMLManagerServlet.java:530)
         at org.apache.catalina.manager.HTMLManagerServlet.doGet(HTMLManagerServlet.java:104)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
         at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
         at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152)
         at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
         at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:540)
         at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
         at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
         at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
         at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
         at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
         at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705)
         at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
         at java.lang.Thread.run(Thread.java:534)
    Caused by: javax.faces.FacesException: ApplicationFactory
         at javax.faces.FactoryFinder.getImplGivenPreviousImpl(FactoryFinder.java:540)
         at javax.faces.FactoryFinder.getImplementationInstance(FactoryFinder.java:426)
         at javax.faces.FactoryFinder.getFactory(FactoryFinder.java:229)
         at com.sun.faces.lifecycle.RestoreViewPhase.<init>(RestoreViewPhase.java:69)
         at com.sun.faces.lifecycle.LifecycleImpl.<init>(LifecycleImpl.java:53)
         at com.sun.faces.lifecycle.LifecycleFactoryImpl.<init>(LifecycleFactoryImpl.java:69)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
         at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
         at java.lang.reflect.Constructor.newInstance(Constructor.java:274)
         at java.lang.Class.newInstance0(Class.java:308)
         at java.lang.Class.newInstance(Class.java:261)
         at javax.faces.FactoryFinder.getImplGivenPreviousImpl(FactoryFinder.java:551)
         ... 40 more
    Caused by: java.lang.ClassNotFoundException: ApplicationFactory
         at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1340)
         at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1189)
         at javax.faces.FactoryFinder.getImplGivenPreviousImpl(FactoryFinder.java:528)
         ... 52 more
    2006-12-01 10:19:51 StandardContext[/manager]HTMLManager: list: Listing contexts for virtual host 'localhost'
    2006-12-01 10:19:55 StandardContext[/manager]HTMLManager: start: Starting web application at '/campman'
    2006-12-01 10:19:55 StandardContext[/campman]Exception sending context initialized event to listener instance of class com.sun.faces.config.ConfigureListener
    javax.faces.FacesException: com.sun.faces.lifecycle.LifecycleFactoryImpl
         at javax.faces.FactoryFinder.getImplGivenPreviousImpl(FactoryFinder.java:553)
         at javax.faces.FactoryFinder.getImplementationInstance(FactoryFinder.java:411)
         at javax.faces.FactoryFinder.getFactory(FactoryFinder.java:229)
         at com.sun.faces.config.ConfigureListener.configure(ConfigureListener.java:702)
         at com.sun.faces.config.ConfigureListener.configure(ConfigureListener.java:398)
         at com.sun.faces.config.ConfigureListener.contextInitialized(ConfigureListener.java:328)
         at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3827)
         at org.apache.catalina.core.StandardContext.start(StandardContext.java:4343)
         at org.apache.catalina.core.StandardHostDeployer.start(StandardHostDeployer.java:830)
         at org.apache.catalina.core.StandardHost.start(StandardHost.java:991)
         at org.apache.catalina.manager.ManagerServlet.start(ManagerServlet.java:1322)
         at org.apache.catalina.manager.HTMLManagerServlet.start(HTMLManagerServlet.java:530)
         at org.apache.catalina.manager.HTMLManagerServlet.doGet(HTMLManagerServlet.java:104)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:237)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
         at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
         at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152)
         at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
         at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:540)
         at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
         at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
         at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
         at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
         at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
         at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705)
         at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
         at java.lang.Thread.run(Thread.java:534)
    Caused by: javax.faces.FacesException: ApplicationFactory
         at javax.faces.FactoryFinder.getImplGivenPreviousImpl(FactoryFinder.java:540)
         at javax.faces.FactoryFinder.getImplementationInstance(FactoryFinder.java:426)
         at javax.faces.FactoryFinder.getFactory(FactoryFinder.java:229)
         at com.sun.faces.lifecycle.RestoreViewPhase.<init>(RestoreViewPhase.java:69)
         at com.sun.faces.lifecycle.LifecycleImpl.<init>(LifecycleImpl.java:53)
         at com.sun.faces.lifecycle.LifecycleFactoryImpl.<init>(LifecycleFactoryImpl.java:69)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
         at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
         at java.lang.reflect.Constructor.newInstance(Constructor.java:274)
         at java.lang.Class.newInstance0(Class.java:308)
         at java.lang.Class.newInstance(Class.java:261)
         at javax.faces.FactoryFinder.getImplGivenPreviousImpl(FactoryFinder.java:551)
         ... 40 more
    Caused by: java.lang.ClassNotFoundException: ApplicationFactory
         at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1340)
         at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1189)
         at javax.faces.FactoryFinder.getImplGivenPreviousImpl(FactoryFinder.java:528)
         ... 52 more
    2006-12-01 10:19:55 StandardContext[/manager]HTMLManager: list: Listing contexts for virtual host 'localhost'

    Sounds like a classloader problem. Do you have multiple jsf-api.jar files in your environment? Check the shared lib directories.
    If you have the flexibility to use a different app server for development, GlassFish is the best JSF application server (IMO): https://glassfish.dev.java.net
    Ken Paulsen
    https://jsftemplating.dev.java.net

  • Error message on restart: finder unexpectedly quit...and can do nothing! help please

    error message on restart: 'finder unexpectedly quit'...and then can do nothing! help please

    thank you hatter....repaired drive but problem persists....can you please explain what i am to do with the library or point me in the direction to read what to do?

  • When I try to start my macbook it gives an error of Please restart your computer, but when i do this i get the same error.

    When I try to start my macbook it gives an error of Please restart your computer, but when i do this i get the same error. This occured after my macbook pro shut down (because of low battery) while it was installing some updates. Please Help?

    Try reinstalling OS X. What version did you have installed? If it's Snow Leopard do this:
    Reinstall OS X without erasing the drive
    Do the following:
    1. Repair the Hard Drive and Permissions
    Boot from your Snow Leopard Installer disc. After the installer loads select your language and click on the Continue button. When the menu bar appears select Disk Utility from the Utilities menu. After DU loads select your hard drive entry (mfgr.'s ID and drive size) from the the left side list.  In the DU status area you will see an entry for the S.M.A.R.T. status of the hard drive.  If it does not say "Verified" then the hard drive is failing or failed. (SMART status is not reported on external Firewire or USB drives.) If the drive is "Verified" then select your OS X volume from the list on the left (sub-entry below the drive entry,) click on the First Aid tab, then click on the Repair Disk button. If DU reports any errors that have been fixed, then re-run Repair Disk until no errors are reported. If no errors are reported click on the Repair Permissions button. Wait until the operation completes, then quit DU and return to the installer.
    If DU reports errors it cannot fix, then you will need Disk Warrior and/or Tech Tool Pro to repair the drive. If you don't have either of them or if neither of them can fix the drive, then you will need to reformat the drive and reinstall OS X.
    2. Reinstall Snow Leopard
    If the drive is OK then quit DU and return to the installer.  Proceed with reinstalling OS X.  Note that the Snow Leopard installer will not erase your drive or disturb your files.  After installing a fresh copy of OS X the installer will move your Home folder, third-party applications, support items, and network preferences into the newly installed system.
    Download and install the Combo Updater for the version you prefer from support.apple.com/downloads/.

  • JSF error messages

    has anybody successful using JSF error messages. Im using JSF portlet framework to display error msgs using h:messages tag. Im able to display validation/conversion errors with h:message tag.
    Im unable to display general messages that are result of an application exception. Has anybody ever done that?
    Help would be appreciated.
    Thanks
    -Sri

    If I understand you correctly ...
    FacesContext context = FacesContext.getCurrentInstance();
    FacesMessage message = new FacesMessage("New Message");
    context.addMessage(null, message);

  • Ipod errors out and restarts my computer!

    I got a new computer and I downloaded iTunes, but everytime I connect my iPod to it, I receive a stop error and it restarts the entire computer. Any ideas?!?!

    Click the Apple icon, then Force Quit. Force quit Mail. That should let you shut down.

  • I'm trying to update to CC (2014) and keep getting this message: "Installation Failed. Installation encountered an error. Please restart your system and try again. (15) I've done the restart, same problem.

    I'm trying to update to CC (2014) and keep getting this message: "Installation Failed. Installation encountered an error. Please restart your system and try again. (15) I've done the restart, same problem.
    Help!

    Hi stijill2,
    In case you are facing issues uninstalling the app's then please try manual cleanup of Adobe from your machine by following the below mentioned steps:
    1. Navigate to Applications and trash all Adobe app's and Adobe folder.
    2. Navigate to Applications/Utilities/ and trash Adobe Application Manager,Adobe Creative Cloud, Adobe Installer folder.
    3. Go to Library/Application Support and trash Adobe.
    4.Go to ~/Library/Application Support and trash Adobe.
    Try installing the CC app's and let us know if still the error persists.
    Regards,
    Romit Sinha

  • An error occurred while restarting "home".

    -Xrs -server -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=5000 -Xdebug -Xnoagent -Djava.compiler=NONE -verbose:gc -Xms512m -Xmx1024m -Xss128k -Djava.security.policy=$ORACLE_HOME/j2ee/home/config/java2.policy -Djava.awt.headless=true -XX:+UseParallelGC -XX:+UseAdaptiveSizePolicy -XX:+PrintGCDetails -XX:+PrintGCTimeStamps -Djdbc.connection.debug=true
    Through application server EM console in home instance-server properties i am setting -java options like above.when i restart home instance i am getting this error
    OC4J : home - failed to set the process status to ProcStatusRestart
    OC4J : home - failed to restart a managed process after the maximum retry limit
    An error occurred while restarting "home".

    Chaituu:
    Probably you have encountered a JVM bug. To see if this is the case, can you try, as I said before,
    java yourOptions -jar oc4j.jar
    Then see what is happening.
    What I got with my Windows XP + java 1.4.2_08 is 
    =================== dos window ===== =================
    C:\oc4j\r1012\j2ee\home>java -Xrs -server -Xrunjdwp:transport=dt_socket,server=y
    ,suspend=n,address=5000 -Xdebug -Xnoagent -Djava.compiler=NONE -verbose:gc -Xms5
    12m -Xmx1024m -Xss128k -Djava.security.policy=$ORACLE_HOME/j2ee/home/config/java
    2.policy -Djava.awt.headless=true -XX:+UseParallelGC -XX:+UseAdaptiveSizePolicy
    -XX:+PrintGCDetails -XX:+PrintGCTimeStamps -Djdbc.connection.debug=true -jar oc4
    j.jar
    0.000: [GC 18168K->34148K(522816K), 0.0150368 secs]
    0.016: [Full GC#
    # HotSpot Virtual Machine Error, Internal Error
    # Please report this error at
    # http://java.sun.com/cgi-bin/bugreport.cgi
    # Java VM: Java HotSpot(TM) Server VM (1.4.2_08-b03 mixed mode)
    # Error happened during: parallel gc system gc
    # Error ID: 50532D41524B33574545500E435050011A
    # Thread requesting VM operation: prio=5 tid=0x02f59760 nid=0xaf8 runnable
    Heap at VM Abort:
    Heap
    PSYoungGen      total 56768K, used 34148K [0x10010000, 0x138f0000, 0x171d0000)
      eden space 11072K, 0% used [0x10010000,0x10010000,0x10ae0000)
      from space 45696K, 74% used [0x10ae0000,0x12c39178,0x13780000)
      to   space 1472K, 0% used [0x13780000,0x13780000,0x138f0000)
    PSOldGen        total 466048K, used 0K [0x171d0000, 0x338f0000, 0x50010000)
      object space 466048K, 0% used [0x171d0000,0x171d0000,0x338f0000)
    PSPermGen       total 16384K, used 7029K [0x50010000, 0x51010000, 0x54010000)
      object space 16384K, 42% used [0x50010000,0x506ed708,0x51010000)
    ==================== dos window ======================
    The same error ID happens with my Solaris + java 1.4.2_04. It has nothing to do oc4j since it also happens to a very simple java program I wrote long ago.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • A new approach to JSF error handling?

    Hi.
    I would like to run an idea by the community to check that I am not being crazy in doing this stuff. I would appreciate any comments, criticism or ideas.
    I was thinking about JSF's error processing mechanism, specifically about how label text gets associated with an input field. So, I am talking about this kind of stuff:
    <h:outputLabel for="firstName" value='#{msgs["applicant.search.firstName"]}: ' />
    <h:inputText id="firstName" value='#{applicantDetailsBackingBean.firstName}' required=�true�/>If the value is not entered into the input field, we will get an error message saying:
    �First Name�: is required.
    So HtmlMessageRenderer has replaced the field id in the FacesMessage with the label text by using the association set up with the 'for' attribute on the label. All of this message "decoration" work happens in the RENDER phase in a centralized location. I see a couple of weaknesses in this approach
    1) It is too late for resolving label text data if the label is inside a data table
    2) JSF establishes associations between label text and the input fields by using the label components to point to their input fields. Although this seems more natural, it limits label text sources to just the label components present on the current page (or whatever is nested under them), which makes it impossible to associate input field messages with label text that does not exist on the page in its entirety.
    Let's look at a couple examples, both of which I ran into in my application:
    1) Consider a situation in which we have a dataTable where every row consists of a student name and an input field for entering their assignment mark. The validation on the input field will be restricted to valid letter grades only. If the user enters an invalid grade, we want them to see an error message of the form: +�The mark entered for <student name> is invalid�.+ Since <student name> is dependent on the row in which the error occurred, this error message is not possible to generate with bare JSF functionality.
    2) Another situation that gets us in trouble is when the label text we want in our error message is not on the page (or not in it's entirety). For example, your page could be split up into multiple parts with those parts having input fields with the same name. We would want the error message to include the page part as well as the field name. This is not easily achieved with the bare JSF functionality.
    So to generalize, any situation where a label component with a static value throughout the lifecycle is not available will cause difficulty.
    Please correct me if I am wrong on any of these points.
    Since in my app I had a lot of complicated pages to deal with, I solved my difficulties by writing a very simple framework that I called Message Decorator Framework (MDF). It enabled me to easily construct much more detailed error messages than what the standard JSF approach seems to allows for. MDF provides a mechanism to specify the label text to be applied to a validation or a conversion message by either a literal, an el expression or via an id of another ValueHolder and all of these work in data tables.
    The idea is a s such, and this is what i would like your opinion on:
    MDF provides more flexible message decoration by adapting the opposite approach to the one used by the JSF:
    1) Message decoration is decentralized. MDF wraps converters and validators on individual input fields and performs message text replacement right on the spot in the PROCESS_VALIDATIONS phase, when all of the pertinent data for resolving the label text is still available.(i.e the components in data tables would still have the correct values for the current row being validated)
    2) The label text to be used is specified by the input field, not the label. This allows the developer to reference any text value, instead of tying them to a specific label component.
    Pictures are better than words, so here is an architectural diagram:
    http://www.imagehosting.com/out.php/i1259440_ArchitectureDiagram.png
    The framework consists of two main classes, ConverterMessageDecorator and ValidatorMessageDecorator. I will just talk about the converter part, b/c the validator part is very similar but wraps a list of validators instead of one converter.
    So ConverterMessageDecorator is a JSF converter. Its purpose is to wrap the converter that is going to do the actual conversion work and decorate the FacesMessage inside ConverterException if one was thrown.
    The converter to wrap can be either determined automatically based on the type of the value reference of the input field or specified explicitly. This converter decorates the message by replacing all instances of the input field�s id with the resolved label text. The power of this approach is that not only do you get a much more flexible way to specify what the label text is (either fieldLabel or fieldLabelComponent attributes), but now data tables are no longer a problem.
    Here are some usage examples:
    <h:inputText value='#{section33SetupBackingBean.contribution.sampleGatePct}'>
       <md:decorateConverterMessage fieldLabel= '#{msgs["section.34.setup.contribution.initial.sampling.gate.max.size"]}' />
    </h:inputText>
    �etc�
    <h:inputText value='#{section33SetupBackingBean.payment.sampleGatePct}'>
       <md:decorateConverterMessage fieldLabel= '#{msgs["section.34.setup.payment.initial.sampling.gate.max.size"]}' />
    </h:inputText>The two input fields have exactly the same labels on the screen (they are in two different parts of the page), so if we used their respective labels, the error messages would look the same for these two input fields.
    More complicated example:
    <h:dataTable value="#{paymentCalcBackingBean.currentPaymentPercentages}" var="currentPercentage" >
    <h:column>
      <ops:refDataDescription id="provinceLabelTextId" refDataType="provinceStateType"
                code="${currentPercentage.programProvince.provinceStateTypeCode}" />
    </h:column>
    <h:column>
      <h:inputText value="${currentPercentage.federalPercentage}">
    <md:decorateConverterMessage fieldLabelComponent="provinceLabelTextId"  valueRequired="true" >
       <f:converter converterId="ops.PercentageConverter" />
    </md:decorateConverterMessage>
    <md:decorateValidatorMessage fieldLabelComponent="provinceLabelTextId" >
       <f:validator validatorId="ops.PercentageValidator" />
    </md:decorateValidatorMessage>
    </h:column>
    �etc�
    </h:dataTable>This would produce errors shown in this screenshot: http://www.imagehosting.com/out.php/i1259418_Example3.png
    Here is another example that shows off what you can do by referencing other ValueHolders on the page.
    The code is exactly the same as the snippet shown above, but the inputText component is referencing a text box, so the label text is going to be whatever the user types into the text box:
    http://www.imagehosting.com/out.php/i1259467_Example4.png
    Does this approach seem reasonable to people, or am I reinventing the wheel? Please let me know.
    Val

    Try restarting the DTR application and see if the problem persists.

  • JSF on Tomcat /4.1.31 and 4.1.36

    Hi,
    i have problems deploying my jsf-app from development Tomcat 4.1.31 to Tomcat 4.1.36:
    /opt/jakarta_tomcat/work/Standalone/localhost/rnm/pages/login_jsp.java:8: cannot access javax.servlet.jsp.HttpJspPage
    bad class file: /opt/jakarta_tomcat/webapps/rnm/WEB-INF/lib/jsp-api.jar(javax/servlet/jsp/HttpJspPage.class)
    class file has wrong version 49.0, should be 48.0
    Please remove or make sure it appears in the correct subdirectory of the classpath.
    public class login_jsp extends HttpJspBase {
           ^
    1 error
         at org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:85)
         at org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:248)
         at org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:315)
         at org.apache.jasper.compiler.Compiler.compile(Compiler.java:328)
         at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:427)
         at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:142)
         at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:240)
         at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:187)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:809)
         at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:627)
         at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:382)
         at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:306)
         at org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1056)
         at org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestProcessor.java:261)
         at org.apache.struts.action.RequestProcessor.internalModuleRelativeForward(RequestProcessor.java:994)
         at org.apache.struts.tiles.TilesRequestProcessor.internalModuleRelativeForward(TilesRequestProcessor.java:343)
         at org.apache.struts.action.RequestProcessor.processForward(RequestProcessor.java:553)
         at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:211)
         at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1164)
         at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:397)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:696)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:809)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:200)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:146)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:209)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:144)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
         at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:445)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:594)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
         at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2358)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:133)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
         at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:118)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:594)
         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:116)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:594)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:127)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:596)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:433)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:948)
         at org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:152)
         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
         at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:705)
         at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
         at java.lang.Thread.run(Thread.java:534)Is there a solution without upgrading Tomcat?
    regards,
    ak

    class file has wrong version 49.0, should be 48.0The mentioned class was compiled with a newer javac version than the java version which is used to run this class.
    E.g. compiled with JDK 1.5 and running with JDK 1.4 will cause this kind of error. The solution might be obvious: (re)compile it with same JDK as you want to run it with.

  • JSF error hangs entire application

    Hi,
    I'm building my first JSF application and an issue has arisen during testing which has us all stumped! Whenever an error occurs for a particular user, the entire application then falls over and all other users then see (different) error messages too.
    I can easily replicate this issue by introducing a typo to a component's EL binding. The initial error message is
    javax.servlet.jsp.JspException: Error getting property 'thisisatypo' from bean of type com.mypackage.MyBeanOther users then see a secondary error message: java.lang.IndexOutOfBoundsExceptionOther applications on the app server are not affected.
    Is there a way to configure the application to better handle exceptions so that the application itself doesn't hang and other users can continue to use it? Would using an error page resolve this? (I'm currently catching exceptions in try...catch blocks and displaying the error messages using the <h:messages> component.)
    Or is this an issue with the application server, which requires reconfiguration to fix it?
    A previous thread mentions a similar issue, bit no-one has answered it: [http://forums.sun.com/thread.jspa?forumID=881&threadID=5049367|http://forums.sun.com/thread.jspa?forumID=881&threadID=5049367]
    My environment:
    JSF: v1.1_02 (Sun JSF RI)
    IDE: JDeveloper 10.1.2.3.0
    Java: 1.4.2_06
    App Server: Oracle App Server 10g (OC4J 9.0.4.0.0)
    (Upgrading to more recent versions of JSF or application server are not options at the moment - my organisation has already scheduled upgrades sometime within the next 12 months or so, but I cannot bring them forward!)

    Hi BalusC, thanks for your response!
    I am using try...catch blocks around my business & database code and I am already using an errorpage. My question is not so much "how to make errors more user friendly" as "how do I prevent the application producing errors for all users when a single user encounters a bug?"
    I'm having difficulty in clearly explaining my issue, probably as I don't understand the JSF architecture sufficiently!
    Let try to describe the scenario.
    1. 10 users are using the main page of the application quite happily.
    2. Another user logs in and visits a different page in the same application. This page contains a bug.
    3. The application serves the error page to this user as an unhandled exception was thrown when processing the request.
    4. The other 10 users also get the error page even though they have not visited the buggy page! The application has fallen over and requires the container to be restarted.
    Steps 1-3 are obvious, but I don't understand step 4 - why should the application fail to continue serving bug-free pages to all other users? Is this the expected behaviour for JSF applications? (Other platforms I've used don't behave this way.)
    When this app goes to production there will be 800+ users. Although I hope to have eliminated most bugs by then, I don't want the entire user base blocked from the app when a single error occurs for a single user.
    If you know what I might have done wrong or what I'm missing, please let me know!
    Thanks.

  • JSF under tomcat 5 ??/

    in the JSFin actions it says : "JSF can work on every standad container like tomcat etc"...
    in my tomcat ver 5.5.29 when i put jsf in some dir and try to open some jsp ...
    it says :opening... and nothink happens .. ideas ?
    the war file is a simple war file created with Sun Studio Creator

    under 5.5.9 there is exceptoin :
    Description: An unhandled exception occurred during the execution of the web application. Please review the following stack trace for more information regarding the error.
    Exception Details: javax.servlet.jsp.JspException
    Cannot find FacesContext
    Possible Source of Error:
    Class Name: javax.faces.webapp.UIComponentTag
    File Name: UIComponentTag.java
    Method Name: doStartTag
    Line Number: 399
    Source not available. Information regarding the location of the exception can be identified using the exception stack trace below.
    Stack trace:
    javax.faces.webapp.UIComponentTag.doStartTag(UIComponentTag.java:399)
    com.sun.faces.taglib.jsf_core.ViewTag.doStartTag(ViewTag.java:105)
    org.apache.jsp.Page1_jsp._jspx_meth_f_view_0(org.apache.jsp.Page1_jsp:83)
    org.apache.jsp.Page1_jsp._jspService(org.apache.jsp.Page1_jsp:61)
    org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
    javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:322)

  • "TNS-12535: TNS:operation timed out" error after listener restart

    I have two related questions:
    Scenario 1:
    1. I have two remote Windows machines with database on each. One is Win 2003 Server (machine A) and another one is Win XP (machine B)
    2. I can ping from A to B.
    3. I can ping from B to A.
    4. I can tnsping from A to B.
    5. I CAN'T tnsping from B to A.
    6. Windows Firewall on both machines are off.
    What could be possible reason for point# 5?
    Scenario 2:
    Now, the second part:
    1. I had an unwanted entry in tnsnames.ora on B which I removed.
    2. Then I restarted the listener on B. Actually, I wanted to restart the one on A to check if that resolves issue mentioned in point# 5 above.
    3. I tried tnsping from A to B but suprisingly it is also giving "operation timed out" error now. So now tnsping not working from either sides.
    I didn't make any changes in listener.ora on B, just stopped it and started again. Only change made was removing unwanted entry in tnsnames.ora on B.
    Why does that affected database connectivity from A to B which was working fine previously?
    If any extra information needed please let me know, and thanks in advance for your answers.
    - Ramesh

    DB names on both machines: ORCL
    listener.ora on B (Win XP) - This was working before listener restart, I mean, I was able to connect to DB on B from A.
    # listener.ora Network Configuration File: C:\app\Test\product\11.2.0\dbhome_1\NETWORK\ADMIN\listener.ora
    # Generated by Oracle configuration tools.
    SID_LIST_LISTENER =
    (SID_LIST =
    (SID_DESC =
    (SID_NAME = CLRExtProc)
    (ORACLE_HOME = C:\app\Test\product\11.2.0\dbhome_1)
    (PROGRAM = extproc)
    (ENVS = "EXTPROC_DLLS=ONLY:C:\app\Test\product\11.2.0\dbhome_1\bin\oraclr11.dll")
    (SID_DESC =
    (GLOBAL_DBNAME = ORCL)
    (ORACLE_HOME = c:\app\Test\product\11.2.0\dbhome_1)
    (SID_NAME = ORCL)
    LISTENER =
    (DESCRIPTION_LIST =
    (DESCRIPTION =
    (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
    (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = testpc)(PORT = 1521))
    ADR_BASE_LISTENER = C:\app\Test
    listener.ora on A (Win 2003 Server) - Never able to connect to DB on this machine from A.
    # listener.ora Network Configuration File: D:\app\Administrator\product\11.2.0\dbhome_1\NETWORK\ADMIN\listener.ora
    # Generated by Oracle configuration tools.
    SID_LIST_LISTENER =
    (SID_LIST =
    (SID_DESC =
    (SID_NAME = CLRExtProc)
    (ORACLE_HOME = D:\app\Administrator\product\11.2.0\dbhome_1)
    (PROGRAM = extproc)
    (ENVS = "EXTPROC_DLLS=ONLY:D:\app\Administrator\product\11.2.0\dbhome_1\bin\oraclr11.dll")
    (SID_DESC =
    (GLOBAL_DBNAME = ORCL)
    (ORACLE_HOME = D:\app\Administrator\product\11.2.0\dbhome_1)
    (SID_NAME = ORCL)
    LISTENER =
    (DESCRIPTION_LIST =
    (DESCRIPTION =
    (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
    (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = NRDBSVR.delldomain1.netreachasia.com)(PORT = 1521))
    ADR_BASE_LISTENER = D:\app\Administrator
    NOTE:
    Machine A = NRDBSVR.delldomain1.netreachasia.com (Win 2003 Server)
    Machine B = testpc (Win XP)

  • Windows 8 system doesn't get internet, says system event log on service has some problem of STOP 0xC000021A error which system restarts very slowly

    Hi, my system runs on windows 8 on hp laptop envy series. All of a sudden, system event log on service stopped, errors which prevented the system to log on services. It displayed error of STOP 0xC000021A when i use system restore to roll back to previous
    configuration. Also when I tried to refresh my pc, it says i can't do changes as log in was switched to prevent the changes by notification.I don't know what to do next, I tried to put recovery dvds which I made when system was bought, now not at all working.
    Internet is not active, not able to resolve by trouble shooting and system taking lot of time to get dsktop. Previously I used to get my desktop in 10 seconds. Now its 10 min. May be I m infected with virus. My files, they are there. I tried to transfer some
    files by pendrive to another system, now the new system(where i put my files in another system) crashed, windows 7 system which does not display desktop, icons etc and not at all workable. 
    Also in my hp system, i m unable to open control panel. if its opened, it will not go off, when i use task manager, it says explorer and shuts down. I had to force restart the system. Please resolve something to get my hp laptop workable. I m waiting for
    my MS thesis to be working on that. My files are locked and no way to transfer, I fear of infected by virus to another computer also. 
    Pls give instructions to hw to set my hp laptop at the earliest without losing any of the files. Idon't want to reinstall and lose all the data for timebeing. Else, inform me the option for copying data safely. I tried to change the adv startup and recovery
    by changing the boot sequence by DVD but this also shows error 0xC000021A and asks us to see the details. I didn't understand all this. Pls help asap.
    Thanks
    venkata
    STOP 0xC000021A

    MV
    If you can boot either from the win 8 dvd or in safe mode we need the DMP files
    We do need the actual DMP file as it contains the only record of the sequence of events leading up to the crash, what drivers were loaded, and what was responsible.  
    WE NEED AT LEAST TWO DMP FILES TO SPOT TRENDS AND CONFIRM THE DIAGNOSIS.
    Please follow our instructions for finding and uploading the files we need to help you fix your computer. They can be found here
    If you have any questions about the procedure please ask
    Wanikiya and Dyami--Team Zigzag

  • JSF error handling when the bean is not correctly loaded

    Hi,
    I am doing some error handling in JSF and I want to do it in an elegant way. I have the following scenario for error handling.
    When the bean is initialized I load the bean with values from DAO which give SQL Exceptions.
    Since the bean is not loaded I properly I have to send the user to an error page showing the error message why I am sending the user to this page.
    I can do it by [ FacesContext.getCurrentInstance.redirect("/error.jsf") ] doing so I will loose all the FacesMessages that are added by the exceptions.
    Instead I want to use the [ FacesContext.getCurrentInstance.dispatch("url") ] which will allow the transfer of the user but I get the following
    16:59:39,341 WARN [lifecycle] executePhase(RESTORE_VIEW 1,com.sun.faces.context.FacesContextImpl@8537f9) threw exception
    java.lang.ClassCastException: javax.faces.component.UIViewRoot
    and the method that I am calling is
    public static void programErrorEnd() {
    logger.info("in the prgmErrorEnd mehod");
    //intializing the contex object
    FacesContext ctx = FacesContext.getCurrentInstance();
    try {
    //ready to dispatch the url.
    //ctx.getExternalContext().redirect("app/error/prgmerror.jsf");
    ctx.getExternalContext().dispatch("error/prgmerror.jsf");
    } catch (IOException e) {
    //TODO what to do when there is an error at this stage.
    finally {
    ctx.responseComplete();
    }Thanks and Regarding
    Edited by: sgatl2 on Aug 28, 2008 2:32 PM
    Edited by: sgatl2 on Aug 28, 2008 2:45 PM

    Just let it throw the exception and define an error-page entry in the web.xml which catches the specified exception (or a superclass of it or a HTTP status code) and displays the error.jsf page accordingly.

Maybe you are looking for

  • Itunes7 and a non-mounting iPod

    After upgrading to v7 (what a mistake). My iPod now no longer appears in iTunes unless I first delete the c:\program files\ipod directory. It also no longer automatically launches iTunes and finally seems to be 'updating' for ever. Is it me! Was itun

  • Dowloading acrobat trial

    I've tried to download the trial version for acrobat x pro. But the 'download now' button doesn't work. I have tried deleting my history and opening and closing browsers, and allowing pop-ups. If I try to download something else, then the download no

  • How can I connect to dynamic link in Adobe After Effects CC ???

    Please help !

  • Camera preview is great, then Aperture destroys it.

    When loading RAW photos from my Fuji X-T1 and Fuji X100 into Aperture, the camera previews are excellent (IMHO). Then, when I select the photo, "Loading..." briefly overlays the photo and then the RAW photo goes flat and lifeless. I spend a lot of ti

  • Why when searching reminders on iPad ios 8, do random dates appear?

    Since iOS 8, when I search my reminders, (I use a list for my shopping list),  random dates appear under the item and above the list the item is in. If I look at the individual item in normal view ( after cancelling the search), there is no date set