users@javaserverfaces.java.net

h:message - Warning: FacesMessage(s) have been enqueued, but may not have been displayed.

From: Todd Patrick <Todd.Patrick_at_dtn.com>
Date: Fri, 9 Mar 2007 09:01:16 -0600

1.) I have the following in my .jsp page: <h:message id="searchErrorFilter" for="filter" showDetail="true" showSummary="false" styleClass="Error"/> 2.) I want to display the h:message component when I catch the following exception: if (results.isEmpty()) { throw new PetroException("No Results"); .... snippet ... } catch (PetroException e) { message.setSeverity(FacesMessage.SEVERITY_ERROR); message.setSummary(e.getMessage()); context.addMessage("tbForm:transactionBrowserBorder:searchErrorFilter", message); logger.error("Transaction Browser Exception:", e); } FacesContext.getCurrentInstance().renderResponse(); 3.) However, what happens - the error is logged correctly, but I get this warning message: WARNING: FacesMessage(s) have been enqueued, but may not have been displayed. I'm not for sure what causes this warning and why it prevents my h:message component to be displayed. I'd appreciate any thoughts or directions on this. Thanks, --Todd [server.log] [#|2007-03-09T08:55:00.310-0600|INFO|sun-appserver-pe9.0|javax.enterpris e.system.stream.out|_ThreadID=15;_ThreadName=httpWorkerThread-8080-0;|15 846 [httpWorkerThread-8080-0] ERROR com.dtn.petro2.petroadmin.transactionbrowser.TransactionBrowser - Transaction Browser Exception: com.dtn.petro2.petro_lib.PetroException: Empty Results. |#] [#|2007-03-09T08:55:00.454-0600|INFO|sun-appserver-pe9.0|javax.enterpris e.resource.webcontainer.jsf.lifecycle|_ThreadID=15;_ThreadName=httpWorke rThread-8080-0; sourceId=tbForm:transactionBrowserBorder:searchErrorFilter[severity=(ERR OR 2), summary=(Empty Results.), detail=(Empty Results.)];|WARNING: FacesMessage(s) have been enqueued, but may not have been displayed. sourceId=tbForm:transactionBrowserBorder:searchErrorFilter[severity=(ERR OR 2), summary=(Empty Results.), detail=(Empty Results.)]|#] ----------------------------------------- NOTICE: This email message is for the sole use of the intended recipient(s) and may contain confidential and privileged information. Any unauthorized use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply email and destroy all copies of the original message.