mojarra

Server-state serialization in a session in Mojarra

你。 提交于 2019-12-07 17:31:46
问题 Going through an abstract in a book, I came across this: On the server side, the state can be stored as a shallow copy or as a deep copy. In a shallow copy, the state is not serialized in the session. By default, JSF Mojarra uses shallow copy. I seriously couldn't understand this. Since in the above case, we will have- javax.faces.STATE_SAVING_METHOD set to server , and an input hidden field javax.faces.ViewState with a value somewhat like this "2870966362946771868:-8449289062699033744" .

How to download Mojarra JSF nightly builds

孤街浪徒 提交于 2019-12-07 13:53:19
问题 I was glad to see that f:ajax now have built in delay support. Not so glad that it doesn't work though. There's a bug that makes it fail, seemingly caused by that the method recieving the specified delay expects a number and not a string. Anyway, it will be fixed in version 2.2.4 but I have no idea how to get that version or if it's even possible before it's publicly released. My question is if someone can explain how to get the nightly build of version 2.2.4 or if there's some workaround.

Ajax view updates doesn't work properly in custom components with dedicated java class

给你一囗甜甜゛ 提交于 2019-12-07 09:33:31
I have a bigger problem than the one I'll describe here, but since it would be difficult to explain and debug my code, I created a smaller (and dumb) problem to reproduce the same error. In my view I want to print a list of strings, this list is calculated based in an offset. In my java class I have a huge static array of Strings. To calculate my list of strings (that will be printed in the page) I copy the values in my static array to my list, starting from the value of "offset". In my page I also have a button "Increment offset" that increments the value of "offset" via an ajax request and

primefaces datatable selectionMode multiple not working with mojarra

╄→尐↘猪︶ㄣ 提交于 2019-12-06 16:45:19
Recently I switched to mojarra from myfaces and noticed that primefaces datatable checkbox multiple row selection is not working. I have tried the exact sample program available at http://www.primefaces.org/showcase/ui/datatableRowSelectionRadioCheckbox.jsf With myfaces both single and multiple selection are working ,but with mojarra multiple selection is not working(selectedCars.length is 0 in setSelectedCars method) I have tried with mojarra 2.0.3 and mojarra 2.1.0 with primefaces 2.2.1 Adding 'f:view contentType="text/html"' solved the problem. Read this in http://www.primefaces.org/faq

h:outputScript with target=“head” not working with Primefaces 3.5

江枫思渺然 提交于 2019-12-06 11:58:04
I have a JSF application with some scripts inserted using target="head" attribute, but after including Primefaces 3.5 to the classpath, these scripts stop rendering. Here is the page code: <!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:ui="http://java.sun.com/jsf/facelets" xmlns:h="http://java.sun.com/jsf/html" xmlns:f="http://java.sun.com/jsf/core"> <h:head> </h:head> <h:body> <h:outputScript target="head"> function a(){}; </h:outputScript> </h:body> </html> Removing the

Mojarra 2.1.14 flash scope messages and redirect to different path

流过昼夜 提交于 2019-12-06 10:17:54
According to this: http://java.net/jira/browse/JAVASERVERFACES-2136 flash-"scoped" messages should survive a redirect to a page on a different path.. I wanted to use something like this in my application so i downloaded javax.faces-2.1.14-20121003.074348-10 snapshot from here https://maven.java.net/content/repositories/snapshots/org/glassfish/javax.faces/2.1.14-SNAPSHOT/ to test. My situation is this: I have a page (call it test.xhtml) in the root directory that in the view-scoped backing bean during the call of the constructor does a check and conditionally sets a message using Omnifaces

ViewExpiredException after upgrade to jsf2

眉间皱痕 提交于 2019-12-06 02:23:32
问题 We recently upgraded a major platform from jsf 1.2 to 2.0. After upgrading we're getting several ViewExpiredException errors each hour. From reading up on the topic it seems that this is an expected exception when sessions expire, however we've reviewed the access logs and we are getting these exceptions even when requests are only 5 minutes apart in some cases. My questions are as follows: 1) Other than session expiration, what other conditions might cause ViewExpiredException? 2) The

JSF 2 Mojarra and Primefaces in WebSphere 7+

落爺英雄遲暮 提交于 2019-12-05 22:36:47
I have been struggling with the unholy alliance that is WebSphere 7+ and Mojarra 2.0.4 and have run into something of a showstopper. I followed the directions as specified at this forum post and got Mojarra 2.0.4 initializing properly: http://forum.primefaces.org/viewtopic.php?f=3&t=6860 Basically I created an isolated classloader shared library that refers externally to the Mojarra and Primefaces jars, added the shared library to the webapp and reversed the classloader to go PARENT_LAST. All of that works. When I attempt to access my web app http://server:port/context/index.xhtml it is

How to download Mojarra JSF nightly builds

三世轮回 提交于 2019-12-05 18:30:36
I was glad to see that f:ajax now have built in delay support. Not so glad that it doesn't work though. There's a bug that makes it fail, seemingly caused by that the method recieving the specified delay expects a number and not a string. Anyway, it will be fixed in version 2.2.4 but I have no idea how to get that version or if it's even possible before it's publicly released. My question is if someone can explain how to get the nightly build of version 2.2.4 or if there's some workaround. You can get the daily snapshot in flavor of loose library, sources and javadoc JAR files from here: jsf

@SessionScoped bean injected as @ManagedProperty of a @ViewScoped acts like @RequestScoped in MyFaces, works fine in Mojarra

心已入冬 提交于 2019-12-05 02:11:24
问题 Here is my simple example: Index.xhtml in root: <?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"> <h:head> <title>Title</title> </h:head> <h:body> <h:form> <h:inputText value="#{index.variable}"></h:inputText> <h:commandButton action="#{index.submit()}" type="submit"></h:commandButton> </h:form> </h