myfaces

How to survive viewscoped beans/viewmap after session destroy (using client side saving)?

半世苍凉 提交于 2019-12-02 07:47:43
I'm using Myfaces 2.2 with Client-side state saving . I see that the ViewScoped beans & data stored in viewmap is lost after the user session is destroyed. I came to know, not sure if it is correct, that this is the expected behavior but then what's the way to avoid view expired exceptions after session destroy? My problem is that I destroy the user session pretty quickly after some inactivity period(like after 20 minutes) but I want the viewscope data to survive even after that(when using client saving) so that when the user comes back after session destroy, he doesn't need to do a page

importing dynamic web project in eclipse ?

老子叫甜甜 提交于 2019-12-02 05:05:00
i use eclipse 3.6.2[Helios] and tomcat 7 and myfaces 1.2.10 i have a problem when i want to import a dynamic web project . i import the project in my workspace and perform the configurations and set jar files but when i run that in tomcat i will have this problem HTTP Status 404 - type Status report message description The requested resource () is not available. Apache Tomcat/6.0.33 and in console display this error : SEVERE: Error starting static Resources java.lang.IllegalArgumentException: Document base C:\Eclipse\Workspaces\Wsp2\.metadata\.plugins\org.eclipse.wst.server.core\tmp0

PrimeFaces 4.0 FileUpload works with Mojarra 2.2 but not MyFaces 2.2

拥有回忆 提交于 2019-12-02 04:07:02
I am having an interesting problem with the PrimeFaces 4.0 final FileUpload element. I am trying to run: PrimeFaces 4.0 final Apache MyFaces 2.2.0-beta Tomcat 7.0.27 I have a very simple setup right now, XHTML page: <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xmlns:h="http://java.sun.com/jsf/html" xmlns:f="http://java.sun.com/jsf/core" xmlns:p="http://primefaces.org/ui"> <h:head> </h:head> <h:body> <h:form> <p:fileUpload

IllegalArgumentException: duplicate key (JSF)

╄→гoц情女王★ 提交于 2019-12-02 04:02:37
I'm using Tomcat 7, Richfaces 4.2.2, MyFaces 2.1.5 and Facelets. When I start Tomcat I get the error: An error occured while initializing MyFaces: duplicate key: class javax.faces.convert.BooleanConverter java.lang.IllegalArgumentException: duplicate key: class javax.faces.convert.BooleanConverter at com.google.common.base.Preconditions.checkArgument(Preconditions.java:115) at com.google.common.collect.RegularImmutableMap.<init>(RegularImmutableMap.java:72) at com.google.common.collect.ImmutableMap$Builder.fromEntryList(ImmutableMap.java:221) at com.google.common.collect.ImmutableMap$Builder

NullPointerException in MyFaces facelet inclusion

喜你入骨 提交于 2019-12-02 03:20:50
I'm trying to migrate simple JSF2.2 prototype from Mojarra 2.2.5 (... where works fine ...) to MyFaces 2.2.3 but a NullPointerException occurs. What I normally do using Mojarra is to include (inject) programmatically a JSF page within a container. The sample inclusion page ( inclusion.xhtml ) is: <h:panelGroup id="container"> </h:panelGroup> <h:form> <h:commandButton value="Include page" action="#{inclusion.include('included.xhtml')}" /> </h:form> The included page ( included.xhtml ) contains something like: <h:outputText value="INCLUDED TEXT ..." /> This is the managed bean : @ManagedBean

java.io.NotSerializableException - org.omnifaces.taghandler.Converter

安稳与你 提交于 2019-12-02 02:15:52
问题 I have an application using Primefaces 3.5 with Omnifaces 1.5 on Jboss 6, using myfaces 2.1.5 on trying to use the o:converter I am getting the follow error. org.omnifaces.taghandler.Converter viewId=/xhtml/propelModules/initiatePropel.xhtml location=C:\jboss-6.1.0.Final\server\default\deploy\PropelEAR.ear\PropelWeb.war\xhtml\propelModules\initiatePropel.xhtml phaseId=RENDER_RESPONSE(6) Caused by: java.io.NotSerializableException - org.omnifaces.taghandler.Converter at java.io

java.io.NotSerializableException - org.omnifaces.taghandler.Converter

允我心安 提交于 2019-12-01 23:42:39
I have an application using Primefaces 3.5 with Omnifaces 1.5 on Jboss 6, using myfaces 2.1.5 on trying to use the o:converter I am getting the follow error. org.omnifaces.taghandler.Converter viewId=/xhtml/propelModules/initiatePropel.xhtml location=C:\jboss-6.1.0.Final\server\default\deploy\PropelEAR.ear\PropelWeb.war\xhtml\propelModules\initiatePropel.xhtml phaseId=RENDER_RESPONSE(6) Caused by: java.io.NotSerializableException - org.omnifaces.taghandler.Converter at java.io.ObjectOutputStream.writeObject0(Unknown Source) The code concerned is ... <p:selectManyCheckbox value="#

t:inputFileUpload not uploading the file

℡╲_俬逩灬. 提交于 2019-12-01 14:46:39
I am using myfaces ExtensionFilter to upload a file, but the file is not getting set to my bean for further processing. Here is the code : <h:form id="uploadFileForm" enctype="multipart/form-data"> <tom:inputFileUpload id="file" value="#{paramUpload.uploadFile}"> <f:valueChangeListener type="com.bosch.de.plcd.plugin.ParamFileUpload" /> </tom:inputFileUpload> <a4j:commandButton value="#{tpMsgs.upload}" styleClass="button" action="#{paramUpload.uploadParamFile}" onclick="javascript:updateParentScreen();"> </a4j:commandButton> </h:form> and web.xml configuration is as below <filter> <filter-name

Custom JSF component: Using “startElement” with “script” results in a comment

非 Y 不嫁゛ 提交于 2019-12-01 13:20:18
I'm rendering a custom JSF component. In the method encodeBegin I want to include some java script. public void encodeBegin(FacesContext context) throws IOException { ResponseWriter writer = context.getResponseWriter(); writer.startElement("script", this); writer.writeAttribute("type", "text/javascript", null); writer.writeText("var width=400",null); writer.endElement("script"); } When rendering the component the content of the script tag is commented out. <script type="text/javascript"><!-- var width=400; //--></script> Can anybody explain why this comment appears and how I get rid of it?

t:inputFileUpload not uploading the file

北慕城南 提交于 2019-12-01 12:47:09
问题 I am using myfaces ExtensionFilter to upload a file, but the file is not getting set to my bean for further processing. Here is the code : <h:form id="uploadFileForm" enctype="multipart/form-data"> <tom:inputFileUpload id="file" value="#{paramUpload.uploadFile}"> <f:valueChangeListener type="com.bosch.de.plcd.plugin.ParamFileUpload" /> </tom:inputFileUpload> <a4j:commandButton value="#{tpMsgs.upload}" styleClass="button" action="#{paramUpload.uploadParamFile}" onclick="javascript