Re: FW: Tomcat Security Exceptions on deployment of example war (reformatted)

2016-03-03 Thread Werner Punz

Hi this is clearly a bug.
Can you please put a bugreport on

https://issues.apache.org/jira/browse/MYFACES

Werner



Am 02.03.16 um 23:12 schrieb Neil Richards:

Hi,

I've been having trouble deploying my MyFaces(2.2.9) app on Tomcat 8 with
the security manager enabled, so I then tried deploying the
myfaces-example-simple-1.1.14.war and had the same problem. I need the
security manager enabled as I am deploying in production on a shared Tomcat
instance and the hosts will not allow the   RuntimePermissions on
org.apache.catalina.core, org.apache.catalina.servlets or
org.apache.jasper.compiler. These are the stack traces I get:

02-Mar-2016 22:08:54.902 INFO [localhost-startStop-1]
org.apache.catalina.loader.WebappClassLoaderBase.loadClass Security
Violation, attempt to use Re
stricted Class: org.apache.catalina.servlets.DefaultServlet
  java.security.AccessControlException: access denied
("java.lang.RuntimePermission"
"accessClassInPackage.org.apache.catalina.servlets")
 at
java.security.AccessControlContext.checkPermission(AccessControlContext.java
:472)
 at
java.security.AccessController.checkPermission(AccessController.java:884)
 at
java.lang.SecurityManager.checkPermission(SecurityManager.java:549)
 at
java.lang.SecurityManager.checkPackageAccess(SecurityManager.java:1564)
 at
org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoader
Base.java:1243)
 at
org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoader
Base.java:1142)
 at java.lang.Class.forName0(Native Method)
 at java.lang.Class.forName(Class.java:264)
 at
org.apache.myfaces.ee6.MyFacesContainerInitializer.isDelegatedFacesServlet(M
yFacesContainerInitializer.java:280)
 at
org.apache.myfaces.ee6.MyFacesContainerInitializer.onStartup(MyFacesContaine
rInitializer.java:150)
 at
org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:
5244)
 at
org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:147)
 at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:7
25)
 at
org.apache.catalina.core.ContainerBase.access$000(ContainerBase.java:131)
 at
org.apache.catalina.core.ContainerBase$PrivilegedAddChild.run(ContainerBase.
java:153)
 at
org.apache.catalina.core.ContainerBase$PrivilegedAddChild.run(ContainerBase.
java:143)
 at java.security.AccessController.doPrivileged(Native Method)
 at
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:699)
 at
org.apache.catalina.core.StandardHost.addChild(StandardHost.java:717)
 at
org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:939)
 at
org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1812)
 at
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
 at java.util.concurrent.FutureTask.run(FutureTask.java:266)
 at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:11
42)
 at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:6
17)
 at java.lang.Thread.run(Thread.java:745)

02-Mar-2016 22:08:59.435 INFO [localhost-startStop-1]
org.apache.catalina.loader.WebappClassLoaderBase.loadClass Security
Violation, attempt to use Re
stricted Class: org.apache.jasper.compiler.JspRuntimeContext
  java.security.AccessControlException: access denied
("java.lang.RuntimePermission"
"accessClassInPackage.org.apache.jasper.compiler")
 at
java.security.AccessControlContext.checkPermission(AccessControlContext.java
:472)
 at
java.security.AccessController.checkPermission(AccessController.java:884)
 at
java.lang.SecurityManager.checkPermission(SecurityManager.java:549)
 at
java.lang.SecurityManager.checkPackageAccess(SecurityManager.java:1564)
 at
org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoader
Base.java:1243)
 at
org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoader
Base.java:1142)
 at java.lang.Class.forName0(Native Method)
 at java.lang.Class.forName(Class.java:264)
 at
org.apache.myfaces.webapp.Jsp21FacesInitializer.getJspFactory(Jsp21FacesInit
ializer.java:88)
 at
org.apache.myfaces.webapp.Jsp21FacesInitializer.initContainerIntegration(Jsp
21FacesInitializer.java:62)
 at
org.apache.myfaces.webapp.AbstractFacesInitializer.initFaces(AbstractFacesIn
itializer.java:172)
 at
org.apache.myfaces.webapp.StartupServletContextListener.contextInitialized(S
tartupServletContextListener.java:121)
 at
org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:
4810)
 at
org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:
5255)
 at
org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:147)
 at

Re: javax.faces.ViewState autocomplete

2015-01-13 Thread Werner Punz

Am 09.01.15 um 11:58 schrieb Dan Østerberg:

Hi,

We have a JSF application where we mainly use ViewScoped beans, and add no-cache headers 
for all JSF pages. Navigating back to a previous page correctly recreates the beans, and 
renders new HTML, with a new ViewState ID. But... some browsers autocomplete 
some of the hidden ViewState inputs, overriding the new value with an old ViewState 
value. We have verified this in the browser dev-tools by looking at the response, which 
is correct, and the resulting HTML which is not.

In short, this is a known autocomplete issue, which Mojarra has fixed since 1.2, by adding 
'autocomplete=off' to the hidden ViewState input. Plus a context parameter 
com.sun.faces.autoCompleteOffOnViewState for opting not to use it, since it results in invalid 
XHTML. Adding 'pa:autocomplete=off' explicitly to the whole form also fixes this issue. However, 
at least the MyFaces version that we use (2.2.4) doesn't add this attribute, and doesn't seem to have any 
corresponding configuration either. We also failed to google up alternatives/explanations for this issue 
explicitly in MyFaces. Naturally, we would like to avoid javascript hacks and custom components and renderers.

So the question is - are we missing something? Or should MyFaces be patched to simply 
render 'autocomplete=off' for its hidden javax.faces.ViewState inputs?

Thanx,
Dan Østerberg

Hi this looks like a bug to me, please file a bugreport in the MyFaces 
Bugtracker.

https://issues.apache.org/jira/browse/myfaces


Kind regards

Werner Punz




Re: 2.2.0 and multipart

2014-02-25 Thread Werner Punz

Am 22.02.14 02:58, schrieb Leonardo K. Shikida:

Hi

Just noticed this thread about tomee, myfacs 2.2.0 and multipart request

stackoverflow.com/questions/21948228/how-to-get-jsf-file-upload-to-work-on-tomee-1-6

does anyone know if between 2.1.13 and 2.2.0, multipart request has got any
new bug? could not find anything in JIRA

the guy who posted the stackoverflow question tested with

h:commandButton while I've reproduced the problem just switching
myfaces jars from vanilla tomee 1.6.0 from 2.1.13 to 2.2.0 and using
p:fileUpload

[]

Leo

Hi this could be a new bug, we introduced a fileupload handling with JSF 
2.2 (the h:inputFile tag) maybe the normal multipart request handling 
was broken by the extensions done in this area the best bet is to file a 
bugreport in the myfaces bugtracker 
https://issues.apache.org/jira/browse/MYFACES


Werner






Re: javax.faces.partial.execute=@none still executes decode

2013-05-27 Thread Werner Punz

Am 22.05.13 16:05, schrieb Thomas Andraschko:

Hi,

i found a weird issue that if i use p:ajax on inputText with
process=@none, the InputTextRenderer#decode method will be still invoked.
This works fine with f:ajax in myfaces and mojarra.
p:ajax only works expected on mojarra.

The only difference i found is, that p:ajax sends the
javax.faces.partial.execute param and f:ajax not.

Here is a list with the post params (without my inputs):

PrimeFaces:
javax.faces.ViewState=N%2F6uUZMB9%2BPXSBTJVus5p6rncWDWwUAgQ9UIOweKuerVM0Z7
javax.faces.partial.ajax=true
javax.faces.source=xxx
javax.faces.partial.execute=%40none
javax.faces.partial.render=%40none
javax.faces.behavior.event=change
javax.faces.partial.event=change
form_SUBMIT=1

MyFaces:
javax.faces.ViewState=EHCQlskNw%2BLXSBTJVus5pyzjdxWpT%2B72t7rvnK11Nffi10%2Bl
javax.faces.partial.ajax=true
javax.faces.source=xxx
javax.faces.behavior.event=change
javax.faces.partial.event=change
javax.faces.windowId=2cc
form_SUBMIT=1
form=form

Any idea? Or should i just raise an issue?

Thanks,
Thomas

Hi, to my knowledge Primefaces uses its own ajax cycle and does not 
utilize jsf.ajax.request hence the difference.

Not sure why p:ajax works on mojarra though.
I would raise a bugreport on the Primefaces list and see what they have 
to say, I dont think it is a myfaces issues, since you said it works 
fine with f:ajax. (I fixed the @none issue a while ago in our codebase)




Werner




Re: f:ajax and IE8

2012-12-18 Thread Werner Punz
Hi this looks like a config problem, could it be that the security 
settings on your companies machines block the XMLHttpRequest object.


Just to be precise, does it fail strictly on that line?

var _ret = new XMLHttpRequest();

or later?

Werner



Am 18.12.12 13:24, schrieb Bashirazad, Wahid:

Hi,
This is the output on the scripting console:
LOG: starting send
LOG: defining scope This
LOG: scope This done
LOG: Error:Objekt erwartet
TypeError: Objekt erwartet

When I start debugging into the scripts, in standard mode the error occurs in 
_Runtime.js(374):

var _ret = new XMLHttpRequest();

In the compatibility mode the debugger takes another route into jsf.js(947) and 
calls
new ActiveXObject(Msxml2.XMLHTTP);

I hope you can help us with this information to fix the error.

Regards
Wahid


-Ursprüngliche Nachricht-
Von: Werner Punz [mailto:werner.p...@gmail.com]
Gesendet: Montag, 17. Dezember 2012 10:02
An: users@myfaces.apache.org
Betreff: Re: f:ajax and IE8

Am 15.12.12 15:45, schrieb Werner Punz:

tried your test project with the same result. It works only in the
compatibility mode of IE8. The Same error in the standard mode.

BUT, when I remove the XHTML DocType line both tests work fine!!!

Are you sure that you are not in the compatibility mode in your XP test
environment? The error occurs not only on my local PC but also on every
other IE8 XP installation in our company.

Kind regards
Wahid


Hi I tried now with various patch levels of IE 8 on XP, again no
failure. I will give you a custom project on monday with more detailed
debugging output so that I can get an idea what is happenening there.


Hi I added another testproject which does have a split import of the
entire ajax framework with detailed console output of the part where I
think it fails:

http://people.apache.org/~werpu/testProject2.tar.bz2

You can start it the same way as before.
Following: please open your debugging console with f12 enable javascript
debugging and then give me the last 2-3 lines of the console output
before it fails, this gives me the exact location where the problem is
raised.
You also can debug into it by setting a breakpoint on following section.
File _AjaxRequest.js line 199 function send, then you can step through
and tell me more detailed on where the object excpected error is thrown.

Again thanks for your patience we will nail this down and fix it.



Werner









Re: f:ajax and IE8

2012-12-18 Thread Werner Punz

Ok I now changed the way the xmlhttprequest object is generated
to the ActiveX fallback if XMLHttpRequest is not found.

http://people.apache.org/~werpu/testProject3.tar.bz2

is the project with the changes.

Check if it works.

Werner


Am 18.12.12 13:52, schrieb Werner Punz:

Hi this looks like a config problem, could it be that the security
settings on your companies machines block the XMLHttpRequest object.

Just to be precise, does it fail strictly on that line?

var _ret = new XMLHttpRequest();

or later?

Werner



Am 18.12.12 13:24, schrieb Bashirazad, Wahid:

Hi,
This is the output on the scripting console:
LOG: starting send
LOG: defining scope This
LOG: scope This done
LOG: Error:Objekt erwartet
TypeError: Objekt erwartet

When I start debugging into the scripts, in standard mode the error
occurs in _Runtime.js(374):

var _ret = new XMLHttpRequest();

In the compatibility mode the debugger takes another route into
jsf.js(947) and calls
new ActiveXObject(Msxml2.XMLHTTP);

I hope you can help us with this information to fix the error.

Regards
Wahid


-Ursprüngliche Nachricht-
Von: Werner Punz [mailto:werner.p...@gmail.com]
Gesendet: Montag, 17. Dezember 2012 10:02
An: users@myfaces.apache.org
Betreff: Re: f:ajax and IE8

Am 15.12.12 15:45, schrieb Werner Punz:

tried your test project with the same result. It works only in the
compatibility mode of IE8. The Same error in the standard mode.

BUT, when I remove the XHTML DocType line both tests work fine!!!

Are you sure that you are not in the compatibility mode in your XP test
environment? The error occurs not only on my local PC but also on every
other IE8 XP installation in our company.

Kind regards
Wahid


Hi I tried now with various patch levels of IE 8 on XP, again no
failure. I will give you a custom project on monday with more detailed
debugging output so that I can get an idea what is happenening there.


Hi I added another testproject which does have a split import of the
entire ajax framework with detailed console output of the part where I
think it fails:

http://people.apache.org/~werpu/testProject2.tar.bz2

You can start it the same way as before.
Following: please open your debugging console with f12 enable javascript
debugging and then give me the last 2-3 lines of the console output
before it fails, this gives me the exact location where the problem is
raised.
You also can debug into it by setting a breakpoint on following section.
File _AjaxRequest.js line 199 function send, then you can step through
and tell me more detailed on where the object excpected error is thrown.

Again thanks for your patience we will nail this down and fix it.



Werner













Re: f:ajax and IE8

2012-12-18 Thread Werner Punz

Just to answer myself, I turned off XMLHttpRequest on IE8 and
finally was able to reproduce the error.
Now there are two solutions.
For a quick fix, turn on XMLHttpRequest under  Tools - Internet Options 
- Advanced Tab - Scroll down to Security - Check 'Enable Native 
XMLHTTP Support'.


This will turn on XMLHttpRequest again, for a long fix, as it seems the 
xmlhttprequest fallback to ActiveX even works in Strict mode for IE8, I 
will enable the fallback mode in MyFaces so that the ActiveX mode is 
chosen instead if no window.XMLHttpRequest object is present.




Werner


Am 18.12.12 13:52, schrieb Werner Punz:

Hi this looks like a config problem, could it be that the security
settings on your companies machines block the XMLHttpRequest object.

Just to be precise, does it fail strictly on that line?

var _ret = new XMLHttpRequest();

or later?

Werner



Am 18.12.12 13:24, schrieb Bashirazad, Wahid:

Hi,
This is the output on the scripting console:
LOG: starting send
LOG: defining scope This
LOG: scope This done
LOG: Error:Objekt erwartet
TypeError: Objekt erwartet

When I start debugging into the scripts, in standard mode the error
occurs in _Runtime.js(374):

var _ret = new XMLHttpRequest();

In the compatibility mode the debugger takes another route into
jsf.js(947) and calls
new ActiveXObject(Msxml2.XMLHTTP);

I hope you can help us with this information to fix the error.

Regards
Wahid


-Ursprüngliche Nachricht-
Von: Werner Punz [mailto:werner.p...@gmail.com]
Gesendet: Montag, 17. Dezember 2012 10:02
An: users@myfaces.apache.org
Betreff: Re: f:ajax and IE8

Am 15.12.12 15:45, schrieb Werner Punz:

tried your test project with the same result. It works only in the
compatibility mode of IE8. The Same error in the standard mode.

BUT, when I remove the XHTML DocType line both tests work fine!!!

Are you sure that you are not in the compatibility mode in your XP test
environment? The error occurs not only on my local PC but also on every
other IE8 XP installation in our company.

Kind regards
Wahid


Hi I tried now with various patch levels of IE 8 on XP, again no
failure. I will give you a custom project on monday with more detailed
debugging output so that I can get an idea what is happenening there.


Hi I added another testproject which does have a split import of the
entire ajax framework with detailed console output of the part where I
think it fails:

http://people.apache.org/~werpu/testProject2.tar.bz2

You can start it the same way as before.
Following: please open your debugging console with f12 enable javascript
debugging and then give me the last 2-3 lines of the console output
before it fails, this gives me the exact location where the problem is
raised.
You also can debug into it by setting a breakpoint on following section.
File _AjaxRequest.js line 199 function send, then you can step through
and tell me more detailed on where the object excpected error is thrown.

Again thanks for your patience we will nail this down and fix it.



Werner













Re: f:ajax and IE8

2012-12-18 Thread Werner Punz

Hi I will change the the myfaces scripts
accordingly so that an ActiveX fallback is chosen if
no native XMLHttpRequest object is present.
This will go into the next release.
I will commit the changes into the trunk tomorrow.

Werner


Am 18.12.12 15:58, schrieb Bashirazad, Wahid:

You're right, the native XMLHTTP Support is disabled and that's the reason why 
Ajax doesn't work. I can also confirm that with your changes in Myfaces scripts 
the Ajax call works fine without enabling the XMLHTTP setting.

Thanks a lot for your investigation.

Regards
Wahid



-Ursprüngliche Nachricht-
Von: Werner Punz [mailto:werner.p...@gmail.com]
Gesendet: Dienstag, 18. Dezember 2012 14:45
An: users@myfaces.apache.org
Betreff: Re: f:ajax and IE8

Just to answer myself, I turned off XMLHttpRequest on IE8 and
finally was able to reproduce the error.
Now there are two solutions.
For a quick fix, turn on XMLHttpRequest under  Tools - Internet Options
- Advanced Tab - Scroll down to Security - Check 'Enable Native
XMLHTTP Support'.

This will turn on XMLHttpRequest again, for a long fix, as it seems the
xmlhttprequest fallback to ActiveX even works in Strict mode for IE8, I
will enable the fallback mode in MyFaces so that the ActiveX mode is
chosen instead if no window.XMLHttpRequest object is present.



Werner


Am 18.12.12 13:52, schrieb Werner Punz:

Hi this looks like a config problem, could it be that the security
settings on your companies machines block the XMLHttpRequest object.

Just to be precise, does it fail strictly on that line?

var _ret = new XMLHttpRequest();

or later?

Werner



Am 18.12.12 13:24, schrieb Bashirazad, Wahid:

Hi,
This is the output on the scripting console:
LOG: starting send
LOG: defining scope This
LOG: scope This done
LOG: Error:Objekt erwartet
TypeError: Objekt erwartet

When I start debugging into the scripts, in standard mode the error
occurs in _Runtime.js(374):

var _ret = new XMLHttpRequest();

In the compatibility mode the debugger takes another route into
jsf.js(947) and calls
new ActiveXObject(Msxml2.XMLHTTP);

I hope you can help us with this information to fix the error.

Regards
Wahid


-Ursprüngliche Nachricht-
Von: Werner Punz [mailto:werner.p...@gmail.com]
Gesendet: Montag, 17. Dezember 2012 10:02
An: users@myfaces.apache.org
Betreff: Re: f:ajax and IE8

Am 15.12.12 15:45, schrieb Werner Punz:

tried your test project with the same result. It works only in the
compatibility mode of IE8. The Same error in the standard mode.

BUT, when I remove the XHTML DocType line both tests work fine!!!

Are you sure that you are not in the compatibility mode in your XP test
environment? The error occurs not only on my local PC but also on every
other IE8 XP installation in our company.

Kind regards
Wahid


Hi I tried now with various patch levels of IE 8 on XP, again no
failure. I will give you a custom project on monday with more detailed
debugging output so that I can get an idea what is happenening there.


Hi I added another testproject which does have a split import of the
entire ajax framework with detailed console output of the part where I
think it fails:

http://people.apache.org/~werpu/testProject2.tar.bz2

You can start it the same way as before.
Following: please open your debugging console with f12 enable javascript
debugging and then give me the last 2-3 lines of the console output
before it fails, this gives me the exact location where the problem is
raised.
You also can debug into it by setting a breakpoint on following section.
File _AjaxRequest.js line 199 function send, then you can step through
and tell me more detailed on where the object excpected error is thrown.

Again thanks for your patience we will nail this down and fix it.



Werner
















Re: f:ajax and IE8

2012-12-17 Thread Werner Punz

Am 15.12.12 15:45, schrieb Werner Punz:

tried your test project with the same result. It works only in the
compatibility mode of IE8. The Same error in the standard mode.

BUT, when I remove the XHTML DocType line both tests work fine!!!

Are you sure that you are not in the compatibility mode in your XP test
environment? The error occurs not only on my local PC but also on every
other IE8 XP installation in our company.

Kind regards
Wahid


Hi I tried now with various patch levels of IE 8 on XP, again no
failure. I will give you a custom project on monday with more detailed
debugging output so that I can get an idea what is happenening there.


Hi I added another testproject which does have a split import of the 
entire ajax framework with detailed console output of the part where I 
think it fails:


http://people.apache.org/~werpu/testProject2.tar.bz2

You can start it the same way as before.
Following: please open your debugging console with f12 enable javascript 
debugging and then give me the last 2-3 lines of the console output 
before it fails, this gives me the exact location where the problem is 
raised.

You also can debug into it by setting a breakpoint on following section.
File _AjaxRequest.js line 199 function send, then you can step through 
and tell me more detailed on where the object excpected error is thrown.


Again thanks for your patience we will nail this down and fix it.



Werner






Re: f:ajax and IE8

2012-12-15 Thread Werner Punz

Am 14.12.12 16:54, schrieb Bashirazad, Wahid:



Hi Werner,

I tried your test project with the same result. It works only in the
compatibility mode of IE8. The Same error in the standard mode.

BUT, when I remove the XHTML DocType line both tests work fine!!!

Are you sure that you are not in the compatibility mode in your XP test
environment? The error occurs not only on my local PC but also on every
other IE8 XP installation in our company.

Kind regards
Wahid

Hi I tried now with various patch levels of IE 8 on XP, again no 
failure. I will give you a custom project on monday with more detailed 
debugging output so that I can get an idea what is happenening there.




Werner



Re: f:ajax and IE8

2012-12-13 Thread Werner Punz

Hello

I tried to reproduce the error on Windows 7 with IE8 and WinXP with IE8, 
it was not reproducible.


Following try following project:

http://people.apache.org/~werpu/testProject.tar.bz2

you can start it via maven with mvn clean install tomcat7:run-war
and then point your browser to http://localhost:9080/

If the problem persists on your machine then we have a local config 
problem and probably you have to start to debug on your machine into the 
myfaces javascripts (with my guidance of course), but more details to 
that if we hit the case.


If not then I would really need a war file which shows the problem, to 
isolate and fix it.

Thanks a lot for your patience and help.

Kind regards

Werner Punz



Am 12.12.12 17:45, schrieb Werner Punz:

Hallo

Ok I tried to reproduce the error with your example with stock IE8
I was not able to reproduce it.

Can you provide a war with the isolated code which produces the error so
that I can have a deeper look at it.


Werner


Am 12.12.12 17:12, schrieb Werner Punz:

Thanks for the example, I will look into the issue tomorrow morning, I
will keep you updated.

Werner


Am 12.12.12 16:59, schrieb Bashirazad, Wahid:

Hi,

my Ajax call is in a composite component:

composite:implementation
h:panelGroup id=panel layout=block styleClass=pickList
div class=middle
h:commandLink action=#{cc.attrs.value.nachRechts}
title=hinzufuegen
f:ajax execute=#{cc.id}
render=targetListbox /
/h:commandLink
/div
div class=right
h:selectManyListbox size=10 id=targetListbox
value=#{cc.attrs.value.transferTarget}
f:selectItems
value=#{cc.attrs.value.target}/
/h:selectManyListbox
/div
/h:panelGroup
/composite:implementation

Wahid


An: users@myfaces.apache.org
Betreff: Re: f:ajax and IE8

Hi, can you isolate the problem into a small example so that I can have
a look at it. It seems like you run into something in the
AjaxRequest.send method, which triggers an error internally.

I cannot reproduce the problem here with my testsuite, so an example
would be helpful.

Werner


Am 12.12.12 13:58, schrieb Bashirazad, Wahid:

Hi everybody,

I have a problem with f:ajax tags in combination of newer Myfaces
versions and IE8.

In my test Ajax call doesn't work in MyFaces versions 2.0.16, 2.1.6

and

2.1.10. It works only when I start IE8 in compatibility mode.

With MyFaces versions 2.0.4 and 2.1.1 works everything fine.



In error cases I get the following massage:

Message: object expected

Calling class: myfaces._impl.xhrCore._AjaxRequest

Calling function: send

Error name: sendError



Any Idea?



Regards

Wahid
























Re: f:ajax and IE8

2012-12-12 Thread Werner Punz
Hi, can you isolate the problem into a small example so that I can have 
a look at it. It seems like you run into something in the 
AjaxRequest.send method, which triggers an error internally.


I cannot reproduce the problem here with my testsuite, so an example 
would be helpful.


Werner


Am 12.12.12 13:58, schrieb Bashirazad, Wahid:

Hi everybody,

I have a problem with f:ajax tags in combination of newer Myfaces
versions and IE8.

In my test Ajax call doesn't work in MyFaces versions 2.0.16, 2.1.6 and
2.1.10. It works only when I start IE8 in compatibility mode.

With MyFaces versions 2.0.4 and 2.1.1 works everything fine.



In error cases I get the following massage:

Message: object expected

Calling class: myfaces._impl.xhrCore._AjaxRequest

Calling function: send

Error name: sendError



Any Idea?



Regards

Wahid













Re: f:ajax and IE8

2012-12-12 Thread Werner Punz
Thanks for the example, I will look into the issue tomorrow morning, I 
will keep you updated.


Werner


Am 12.12.12 16:59, schrieb Bashirazad, Wahid:

Hi,

my Ajax call is in a composite component:

composite:implementation
h:panelGroup id=panel layout=block styleClass=pickList
div class=middle
h:commandLink action=#{cc.attrs.value.nachRechts}
title=hinzufuegen
f:ajax execute=#{cc.id}
render=targetListbox /
/h:commandLink
/div
div class=right
h:selectManyListbox size=10 id=targetListbox
value=#{cc.attrs.value.transferTarget}
f:selectItems
value=#{cc.attrs.value.target}/
/h:selectManyListbox
/div
/h:panelGroup
/composite:implementation

Wahid


An: users@myfaces.apache.org
Betreff: Re: f:ajax and IE8

Hi, can you isolate the problem into a small example so that I can have
a look at it. It seems like you run into something in the
AjaxRequest.send method, which triggers an error internally.

I cannot reproduce the problem here with my testsuite, so an example
would be helpful.

Werner


Am 12.12.12 13:58, schrieb Bashirazad, Wahid:

Hi everybody,

I have a problem with f:ajax tags in combination of newer Myfaces
versions and IE8.

In my test Ajax call doesn't work in MyFaces versions 2.0.16, 2.1.6

and

2.1.10. It works only when I start IE8 in compatibility mode.

With MyFaces versions 2.0.4 and 2.1.1 works everything fine.



In error cases I get the following massage:

Message: object expected

Calling class: myfaces._impl.xhrCore._AjaxRequest

Calling function: send

Error name: sendError



Any Idea?



Regards

Wahid
















Re: f:ajax and IE8

2012-12-12 Thread Werner Punz

Hallo

Ok I tried to reproduce the error with your example with stock IE8
I was not able to reproduce it.

Can you provide a war with the isolated code which produces the error so 
that I can have a deeper look at it.



Werner


Am 12.12.12 17:12, schrieb Werner Punz:

Thanks for the example, I will look into the issue tomorrow morning, I
will keep you updated.

Werner


Am 12.12.12 16:59, schrieb Bashirazad, Wahid:

Hi,

my Ajax call is in a composite component:

composite:implementation
h:panelGroup id=panel layout=block styleClass=pickList
div class=middle
h:commandLink action=#{cc.attrs.value.nachRechts}
title=hinzufuegen
f:ajax execute=#{cc.id}
render=targetListbox /
/h:commandLink
/div
div class=right
h:selectManyListbox size=10 id=targetListbox
value=#{cc.attrs.value.transferTarget}
f:selectItems
value=#{cc.attrs.value.target}/
/h:selectManyListbox
/div
/h:panelGroup
/composite:implementation

Wahid


An: users@myfaces.apache.org
Betreff: Re: f:ajax and IE8

Hi, can you isolate the problem into a small example so that I can have
a look at it. It seems like you run into something in the
AjaxRequest.send method, which triggers an error internally.

I cannot reproduce the problem here with my testsuite, so an example
would be helpful.

Werner


Am 12.12.12 13:58, schrieb Bashirazad, Wahid:

Hi everybody,

I have a problem with f:ajax tags in combination of newer Myfaces
versions and IE8.

In my test Ajax call doesn't work in MyFaces versions 2.0.16, 2.1.6

and

2.1.10. It works only when I start IE8 in compatibility mode.

With MyFaces versions 2.0.4 and 2.1.1 works everything fine.



In error cases I get the following massage:

Message: object expected

Calling class: myfaces._impl.xhrCore._AjaxRequest

Calling function: send

Error name: sendError



Any Idea?



Regards

Wahid




















[ANNOUNCE] Apache MyFaces Extension Scripting 1.0.5

2012-12-11 Thread Werner Punz
The Apache MyFaces Ext-Scripting team is pleased to announce the release 
of MyFaces Ext-Scripting 1.0.5.
Apache MyFaces Ext-Scripting is an extension to Apache MyFaces which 
provides scripting language capabilities and dynamic reloading to Apache 
MyFaces.


MyFaces Ext-Scripting 1.0.5 is available in both binary and source 
distributions.


* http://myfaces.apache.org/extensions/scripting/download.html

MyFaces Ext-Scripting is also available in the central Maven repository 
under

Group ID org.apache.myfaces.extensions.scripting.

Release Notes - Ext-Scripting - Version 1.0.5

Apache MyFaces Extension Scripting 1.0.5 is a bugfix and enhancement 
release which adds JRuby and Spring support.


Detailed release notes:

Release Notes - MyFaces Extensions Scripting - Version 1.0.5-FINAL


** Bug
* [EXTSCRIPT-44] - Spring integration
* [EXTSCRIPT-183] - Logical Flaw in the Extscript CDI classloader
* [EXTSCRIPT-184] - Automated tests fail on Linux in the current trunk

** Improvement
* [EXTSCRIPT-136] - Adding an event system
* [EXTSCRIPT-143] - Code cleanup in the garbage collection area
* [EXTSCRIPT-178] - Add the Tomcat Maven plugin
* [EXTSCRIPT-182] - Move all MyFaces Related Classes into their own 
Subproject

* [EXTSCRIPT-185] - Preparations for the 1.0.5 release

** New Feature
* [EXTSCRIPT-177] - Add JRuby support
* [EXTSCRIPT-179] - Prepare the Documentation for the CMS Transition



regards,

Werner Punz



Re: New: MyFaces as default JSF on JBoss AS

2012-11-28 Thread Werner Punz

Hey this is great news.

Werner


Am 27.11.12 17:45, schrieb ssilv...@redhat.com:

Hi MyFaces folks,

I just wanted to announce that after years of talking about this, we
finally have the ability to use MyFaces on JBoss AS in a fully
integrated way.  You can install any version of MyFaces onto JBoss AS
7.2 and even use it as the default JSF implementation.

Details are in my blog and in the design documentation:
http://jsfunit.blogspot.com/2012/11/multi-jsf-is-here-use-any-jsf-in-jboss.html

https://community.jboss.org/wiki/DesignOfAS7Multi-JSFFeature

Hope you like it and have a chance to try it out.  I'd love some early
feedback from the MyFaces community.

Regards,

Stan





Re: Migration to TomEE/CODI: very strange AJAX issue during regression testing

2012-11-23 Thread Werner Punz
Btw. Howard could you blog what you did for the migration, this might 
interest other users as well.



Werner



Am 22.11.12 17:16, schrieb Howard W. Smith, Jr.:

+1 Werner's response, too. Thanks for that response, so I know where to
file relevant issues and which email list to send to, but honestly, I think
this issue should go to TomEE as well as MyFaces user lists, because others
may be using MyFaces Core (like myself).

Mark,

FYI, for some/whatever reason, I added JUEL jar to tomee /lib, and it has
'lived' there ever since, and my app is running well with it (since I have
context-parm in web.xml referencing juel). I just have to find and resolve
any issues I have, and as you have already noticed, I like to communicate
issues I have as well as 'my workarounds' to these issues. I always do what
I can to workaround issues that I'm confronted with. :)

IMHO, some weeks ago, I didn't find tomcat7 'easy' at all, and I 'found'
TomEE 'easier' than tomcat7. That may be a more accurate way of saying
it...at least from the community of users migrating from 'Glassfish' to
tomcat7. TomEE and the really-great (Apache) user community is the
solution!!! :)

File an issue. I love filing issues and providing as many details as
possible. I just need the experiencing of filing a new issue, and then I
should be set/fine, going forward.

I'll read [1][2] that you provided and respond accordingly or as necessary.

Thanks,
Howard


On Thu, Nov 22, 2012 at 5:46 AM, Mark Struberg strub...@yahoo.de wrote:


+1

Howard, as most other stuff is now working, we can continue with getting
back JUEL in place. But please file a tomcat issue for the EL stuff first!

For TomEE it's as easy as for tomcat7. A long time ago I wrote up a
description in our wiki [1] which is basically still true.
There is also some info on the juel page [2].



[1] http://wiki.apache.org/myfaces/HowToEnableEl22
[2] http://juel.sourceforge.net/guide/service.html


- Original Message -

From: Werner Punz werner.p...@gmail.com
To: MyFaces Discussion users@myfaces.apache.org
Cc:
Sent: Thursday, November 22, 2012 9:48 AM
Subject: Re: Migration to TomEE/CODI: very strange AJAX issue during

regression testing


If there is an EL struggling problem then this is probably a tomcat
issue. Tomcat is providing the EL in tomee to my knowledge.


Werner


Am 22.11.12 00:07, schrieb Howard W. Smith, Jr.:

  I think I just solved this issue as follows:

  *CAUSED BY:* p:calendar

*readonlyInput=#{pf_usersController.loggedInViaIpad

  == 'Y' ? 'true' : 'false'}*


  1. Glassfish 3.1.2.2 and MyFaces Core 2.1.9 handles that perfectly
  2. OpenWebBeans and MyFaces Core 2.1.9 seem to struggle with that

EL

for

  whatever reason
  3. So, I made it easy on OpenWebBeans and moved that EL to
  rendered=..., and conditionally render separate components

with a

  readonlyInput=true only for iPad device/endusers

  *CODE CHANGES* below:


  h:outputText value=From: /
  p:calendar id=filterTripDateFrom
   value=#{pf_ordersController.filterTripDateFrom}
   mode=popup showOn=button
   navigator=true effect=fadeIn
   pattern=MM/dd/ size=10
   rendered=#{pf_usersController.loggedInViaIpad ==

'N'}

   p:ajax partialSubmit=false
   event=dateSelect
  listener=#{pf_ordersController.filterTripDateFromSelected}
   update=:ordersBrowseForm:ordersDataTable
  :ordersBrowseForm:formMessages :ordersBrowseForm:_ajax_status /
  /p:calendar
  p:calendar id=filterTripDateFromOnIpad
   value=#{pf_ordersController.filterTripDateFrom}
   mode=popup showOn=button

readonlyInput=true

   navigator=true effect=fadeIn
   pattern=MM/dd/ size=10
   rendered=#{pf_usersController.loggedInViaIpad ==

'Y'}

   p:ajax partialSubmit=false
   event=dateSelect
  listener=#{pf_ordersController.filterTripDateFromSelected}
   update=:ordersBrowseForm:ordersDataTable
  :ordersBrowseForm:formMessages :ordersBrowseForm:_ajax_status /
  /p:calendar
  h:outputText value=To: /
  p:calendar id=filterTripDateTo
  value=#{pf_ordersController.filterTripDateTo}
   mode=popup showOn=button
   navigator=true effect=fadeIn

pattern=MM/dd/ size=10

   rendered=#{pf_usersController.loggedInViaIpad ==

'N'}

   p:ajax partialSubmit=false
   event=dateSelect
  listener=#{pf_ordersController.filterTripDateToSelected}
   update=:ordersBrowseForm:ordersDataTable
  :ordersBrowseForm:formMessages :ordersBrowseForm:_ajax_status /
  /p:calendar
  p:calendar id=filterTripDateToOnIpad
  value=#{pf_ordersController.filterTripDateTo}
   mode=popup showOn=button

readonlyInput=true

   navigator=true effect=fadeIn

pattern=MM/dd/ size=10

   rendered=#{pf_usersController.loggedInViaIpad ==

'Y'}

   p:ajax partialSubmit=false
   event=dateSelect
  listener=#{pf_ordersController.filterTripDateToSelected}
   update=:ordersBrowseForm:ordersDataTable
  :ordersBrowseForm:formMessages

Re: Migration to TomEE/CODI: very strange AJAX issue during regression testing

2012-11-22 Thread Werner Punz
If there is an EL struggling problem then this is probably a tomcat 
issue. Tomcat is providing the EL in tomee to my knowledge.



Werner


Am 22.11.12 00:07, schrieb Howard W. Smith, Jr.:

I think I just solved this issue as follows:

*CAUSED BY:* p:calendar *readonlyInput=#{pf_usersController.loggedInViaIpad
== 'Y' ? 'true' : 'false'}*


1. Glassfish 3.1.2.2 and MyFaces Core 2.1.9 handles that perfectly
2. OpenWebBeans and MyFaces Core 2.1.9 seem to struggle with that EL for
whatever reason
3. So, I made it easy on OpenWebBeans and moved that EL to
rendered=..., and conditionally render separate components with a
readonlyInput=true only for iPad device/endusers

*CODE CHANGES* below:


h:outputText value=From: /
p:calendar id=filterTripDateFrom
 value=#{pf_ordersController.filterTripDateFrom}
 mode=popup showOn=button
 navigator=true effect=fadeIn
 pattern=MM/dd/ size=10
 rendered=#{pf_usersController.loggedInViaIpad == 'N'}
 p:ajax partialSubmit=false
 event=dateSelect
listener=#{pf_ordersController.filterTripDateFromSelected}
 update=:ordersBrowseForm:ordersDataTable
:ordersBrowseForm:formMessages :ordersBrowseForm:_ajax_status /
/p:calendar
p:calendar id=filterTripDateFromOnIpad
 value=#{pf_ordersController.filterTripDateFrom}
 mode=popup showOn=button readonlyInput=true
 navigator=true effect=fadeIn
 pattern=MM/dd/ size=10
 rendered=#{pf_usersController.loggedInViaIpad == 'Y'}
 p:ajax partialSubmit=false
 event=dateSelect
listener=#{pf_ordersController.filterTripDateFromSelected}
 update=:ordersBrowseForm:ordersDataTable
:ordersBrowseForm:formMessages :ordersBrowseForm:_ajax_status /
/p:calendar
h:outputText value=To: /
p:calendar id=filterTripDateTo
value=#{pf_ordersController.filterTripDateTo}
 mode=popup showOn=button
 navigator=true effect=fadeIn pattern=MM/dd/ size=10
 rendered=#{pf_usersController.loggedInViaIpad == 'N'}
 p:ajax partialSubmit=false
 event=dateSelect
listener=#{pf_ordersController.filterTripDateToSelected}
 update=:ordersBrowseForm:ordersDataTable
:ordersBrowseForm:formMessages :ordersBrowseForm:_ajax_status /
/p:calendar
p:calendar id=filterTripDateToOnIpad
value=#{pf_ordersController.filterTripDateTo}
 mode=popup showOn=button readonlyInput=true
 navigator=true effect=fadeIn pattern=MM/dd/ size=10
 rendered=#{pf_usersController.loggedInViaIpad == 'Y'}
 p:ajax partialSubmit=false
 event=dateSelect
listener=#{pf_ordersController.filterTripDateToSelected}
 update=:ordersBrowseForm:ordersDataTable
:ordersBrowseForm:formMessages :ordersBrowseForm:_ajax_status /
/p:calendar



On Wed, Nov 21, 2012 at 3:19 PM, Howard W. Smith, Jr. 
smithh032...@gmail.com wrote:


The following is the XHTML for the *FROM* and *TO* p:calendar components
in PrimeFaces p:dataTable component. Please note that the *mode=popup
showOn=button* is hardcoded in the xhtml below, and is not
conditionally dependent on EL.

As the screen captures will show, I am testing this via my
test/development server, so please do not think I'm testing from iPad
(since there is EL for iPad devices below).

This issue is not happening in the Production environment (Glassfish
3.1.2.2 and MyFaces Core 2.1.9).

 p:calendar id=filterTripDateFrom
 value=#{pf_ordersController.filterTripDateFrom}
 mode=popup showOn=button
readonlyInput=#{pf_usersController.loggedInViaIpad == 'Y' ? 'true' :
'false'}
 navigator=true effect=fadeIn
 pattern=MM/dd/ size=10
 p:ajax partialSubmit=false
 event=dateSelect
listener=#{pf_ordersController.filterTripDateFromSelected}
 update=:ordersBrowseForm:ordersDataTable
:ordersBrowseForm:formMessages :ordersBrowseForm:_ajax_status /
 /p:calendar
 h:outputText value=To: /
 p:calendar id=filterTripDateTo
value=#{pf_ordersController.filterTripDateTo}
 mode=popup showOn=button
readonlyInput=#{pf_usersController.loggedInViaIpad == 'Y' ? 'true' :
'false'}
 navigator=true effect=fadeIn pattern=MM/dd/
size=10
 p:ajax partialSubmit=false
 event=dateSelect
listener=#{pf_ordersController.filterTripDateToSelected}
 update=:ordersBrowseForm:ordersDataTable
:ordersBrowseForm:formMessages :ordersBrowseForm:_ajax_status /
 /p:calendar



On Wed, Nov 21, 2012 at 3:06 PM, Howard W. Smith, Jr. 
smithh032...@gmail.com wrote:


You all know by now that I recently migrated

*FROM*: Glassfish 3.1.2.2, MyFaces 2.1.9, and JSF Managed beans

*TO*: TomEE 1.5 SNAPSHOT, Apache MyFaces CDI Extensions 1.0.6 (CODI),
and CDI managed beans

So, I am regression testing, and I am experiencing a very very strange
issue with *TomEE/CODI* (development/test environment) that I have never
seen with *Glassfish 3.1.2.2 *and* MyFaces 2.1.9* (currently in
production).

Attached you will find screen 

[ANNOUNCE] Apache MyFaces Ext-Scripting 1.0.4 release

2012-10-18 Thread Werner Punz


The Apache MyFaces Ext-Scripting team is pleased to announce the release 
of MyFaces Ext-Scripting 1.0.4.
Apache MyFaces Ext-Scripting is an extension to Apache MyFaces which 
provides scripting language capabilities and dynamic reloading to Apache 
MyFaces.


MyFaces Ext-Scripting 1.0.4 is available in both binary and source 
distributions.


* http://myfaces.apache.org/extensions/scripting/download.html

MyFaces Ext-Scripting is also available in the central Maven repository 
under

Group ID org.apache.myfaces.extensions.scripting.

Release Notes - Ext-Scripting - Version 1.0.4

Apache MyFaces Extension Scripting 1.0.4 is a small enhancement release 
which adds OpenWebbeans support and reenables Windows compatibility.


Detailed release notes:

Release Notes - MyFaces Extensions Scripting - Version 1.0.4-FINAL

** Sub-task
* [EXTSCRIPT-139] - Add on demand compilation

** Bug
* [EXTSCRIPT-165] - java.lang.StringIndexOutOfBoundsException: 
String index out of range: 1 after upgrade to 1.0.3  version

* [EXTSCRIPT-167] - release cleanup and preparations
* [EXTSCRIPT-168] - Concurrentmodification Exception in the CDI part
* [EXTSCRIPT-173] - glassfish startup npe
* [EXTSCRIPT-174] - websphere liberty profile classpath error

** Improvement
* [EXTSCRIPT-107] - CDI Integration
* [EXTSCRIPT-166] - windows compatibility
* [EXTSCRIPT-170] - Documentation doesn't mention required dependencies
* [EXTSCRIPT-172] - Add JAR of source code

** New Feature
* [EXTSCRIPT-175] - Adding needed glassfish config files
* [EXTSCRIPT-176] - Ext-Script 1.0.4 release preparations



regards,

Werner Punz




Re: [Extensions-Scripting] Java code changes not getting picked up

2012-09-19 Thread Werner Punz
Hi Kito, I just got two days from my employer to debug it out, and 
frankly spoken the WAS toolchain did not work for me, I got the server 
up and running standalone, but I could not deploy the hello world war 
(ran out of time to investigate that further probably a missing config 
entry)

The combination with Eclipse did not work at all for me.
Have in mind I am not an expert on WAS I never really have used it.
If anyone from the IBM guys is reading this, I could need some help 
here. Ext-Scripting would be a great extension for WAS if it could be 
made to run on it.


Anyways:

But I was able to debug the thing out for WAS Liberty profile as well as 
Glassfish, here is the info on WAS LB (Glassfish should now work out of 
the box with the latest snapshot and myfaces in)


I noticed that WAS LB does not unpack the wars as other app servers do, 
hence the compilation failed due to the compiler not having the jars 
available.

What you can do is following

a) Build the latest snapshot from the trunk, should be self contained 
within the maven repos, so no additional work is needed mvn clean 
install should suffice.


b) Replace the 1.0.2 jars with the ones from the Snapshot

in your web.xml add following:

   context-param
descriptionSome containers do not expand their war/ear files 
and do not return a proper classpath for the

compilers.
For those you can set an additional classpath as comma 
separated list of paths so that the compiler can pick
up dependencies from other directories. Wildcarding regarding 
jar and zip files is allowed.

/description

param-nameorg.apache.myfaces.extensions.scripting.ADDITIONAL_CLASSPATH/param-name

param-value/whatever/myfaces20-extscript-helloworld/target/myfaces20-extscript-helloworld-1.0.4-SNAPSHOT/WEB-INF/lib/*.jar,

/whatever/myfaces20-extscript-helloworld/target/myfaces20-extscript-helloworld-1.0.4-SNAPSHOT/WEB-INF/classes/param-value
/context-param


adjust the paths to your needs so that the compiler can pick up the 
paths with the jars as needed.
This works at least under WAS liberty profile, give it a shot with the 
snapshot release.
also one change, the servlet filter is not needed anymore, it still is 
in with auto setup, but you wont need the filter in your web.xml 
anymore, it either is picked up doing nothing or not does not matter.

(I will remove the servlet filter asap to avoid confusion)

Werner



Am 11.09.12 15:35, schrieb Kito Mann:

Hello Werner,

Have you had a chance to debug this yet?
___

Kito D. Mann | @kito99 | Author, JSF in Action
Virtua, Inc. | http://www.virtua.com | JSF/Java EE training and consulting
http://www.JSFCentral.com - JavaServer Faces FAQ, news, and info | @jsfcentral
+1 203-404-4848 x246

* Listen to the latest headlines in the JSF and Java EE newscast:
http://blogs.jsfcentral.com/JSFNewscast/
* Sign up for the JSFCentral Newsletter: http://oi.vresp.com/?fid=ac048d0e17


On Tue, Sep 4, 2012 at 3:15 PM, Werner Punz werner.p...@gmail.com wrote:

Ext-scripting registers short lived classloaders which register the newly to
be loaded classes and drops the classloaders afterwards.
(so called throw away classloaders)

there is no long lived classloader pushed into the system on top of it to
avoid container problems.

Either way thanks for all the links and debugging hints, I will have a look
at it.

Werner


Am 04.09.12 21:09, schrieb Rohit Kelapure:


For further classloader debugging you can enable the WebSphere Classloader
viewer service which will show you the exact set of classes loaded in your
app. I also suggest enabling verbose classloading.
In order to reload the class in WAS, the application classloader needs to
be unloaded and reloaded back again. Not sure how Ext-Scripting achieves
this.
If you are interested in further deep dive debugging these are the steps
...


 -

MustGather:
http://www-01.ibm.com/support/docview.wss?uid=swg21196187
-

   Diagnostic Trace  com.ibm.ws.classloader.*=all
   -

   JVM  Verbose class loading
   -

   JVM  Custom Properties - ws.ext.debug=true


 -

Verbose class loading:

http://publib.boulder.ibm.com/infocenter/wasinfo/v6r1/topic/com.ibm.websphere.nd.multiplhttp://publib.boulder.ibm.com/infocenter/wasinfo/v6r1/topic/com.ibm.websphere.nd.multiplatform.doc/info/ae/ae/urun_rconfproc_jvm.html

atform.doc/info/ae/ae/urun_rconfproc_jvm.htmlhttp://publib.boulder.ibm.com/infocenter/wasinfo/v6r1/topic/com.ibm.websphere.nd.multiplatform.doc/info/ae/ae/urun_rconfproc_jvm.html
-

   Prints each class that was loaded and the absolute path of the
JAR.


 -

ws.ext.debug goes to native_stdout.log or SystemOut.log
-

   See also ws.ext.dirs in SystemOut.log which is the classpath
   passed into com.ibm.ws.bootstrap.ExtClassLoader (which
details of which are
   printed due to ws.ext.debug).
   -

On the IBM JDK

Re: [Extensions-Scripting] Java code changes not getting picked up

2012-09-04 Thread Werner Punz
 Servlet/servlet-name
 servlet-classjavax.faces.webapp.FacesServlet/servlet-class
 load-on-startup1/load-on-startup
 /servlet
 servlet-mapping
 servlet-nameFaces Servlet/servlet-name
 url-pattern/faces/*/url-pattern
 /servlet-mapping
 servlet-mapping
 servlet-nameFaces
 Servlet
 /servlet-name
 url-pattern*.jsf/url-pattern
 /servlet-mapping
 servlet-mapping
 servlet-nameFaces Servlet/servlet-name
 url-pattern*.faces/url-pattern
 /servlet-mapping
 servlet-mapping
 servlet-nameFaces Servlet/servlet-name
 url-pattern*.xhtml/url-pattern
 /servlet-mapping
 mime-mapping
 extensionpng/extension
 mime-typeimage/png/mime-type
 /mime-mapping
 login-config
 auth-methodFORM/auth-method
 realm-namedevelopinjava/realm-name
 form-login-config
 form-login-page/login.xhtml/form-login-page
 form-error-page/error.jspx/form-error-page
 /form-login-config
 /login-config
 error-page
 exception-typejava.lang.Exception/exception-type
 location/faces/error.xhtml/location
 /error-page
 error-page
 error-code500/error-code
 location/faces/error.xhtml/location
 /error-page
 session-config
 session-timeout30/session-timeout
 /session-config
/web-app
___

Kito D. Mann | @kito99 | Author, JSF in Action
Virtua, Inc. | http://www.virtua.com | JSF/Java EE training and consulting
http://www.JSFCentral.com - JavaServer Faces FAQ, news, and info |
@jsfcentral
+1 203-404-4848 x246

* Listen to the latest headlines in the JSF and Java EE newscast: *
http://blogs.jsfcentral.com/JSFNewscast/*
* Sign up for the JSFCentral Newsletter: http://oi.vresp.com/?fid=ac048d0e17



On Mon, Sep 3, 2012 at 7:59 AM, Werner Punz werner.p...@gmail.com wrote:


Am 03.09.12 13:52, schrieb Werner Punz:


Am 31.08.12 21:44, schrieb Kito Mann:

  I'm trying to get MyFaces Extensions-Scripting running on RAD 8.0 with

WAS
8.0 on Win 7 (no this isn't my choice of tools...) The goal is to use the
dynamic Java class loading to avoid the hideously long WAS publish times.
For the most part, everything is working fine now, and Ext-Scripting
notices when the class has changed and outputs the full list of classes
that are being loaded to the console. Unfortunately, the changes aren't
being picked up by the application. I've tried several different
scenarios
(using a specific LOADER_PATH, the default WEB-INF/java path, changing
the
publishing settings, turning Build Automatically on or off, etc.), but I
haven't had any luck. Perhaps WAS is doing something different at the
classloader level than Ext-Scripting expects? Any ideas?
___

Kito D. Mann | @kito99 | Author, JSF in Action
Virtua, Inc. | http://www.virtua.com | JSF/Java EE training and
consulting
http://www.JSFCentral.com - JavaServer Faces FAQ, news, and info |
@jsfcentral
+1 203-404-4848 x246

* Listen to the latest headlines in the JSF and Java EE newscast: *
http://blogs.jsfcentral.com/**JSFNewscast/*http://blogs.jsfcentral.com/JSFNewscast/*
* Sign up for the JSFCentral Newsletter:
http://oi.vresp.com/?fid=**ac048d0e17http://oi.vresp.com/?fid=ac048d0e17

  Mhh Hi Kito, currently Ext-Scripting is not tested on WAS, normally it

should be picked up, normally the files should be picked up as soon as
you have the loader path set or WEB-INF/java is set.
Sorry for not having been able to test Ext-Scripting on the big irons
currently.


  Also I forgot, can you post your web.xml configuration?

You might have missed the init plugin for myfaces.


Werner











Re: [Extensions-Scripting] Java code changes not getting picked up

2012-09-04 Thread Werner Punz

Am 04.09.12 20:40, schrieb Kito Mann:

On Tue, Sep 4, 2012 at 2:30 PM, Werner Punz werner.p...@gmail.com wrote:


The config looks correct to me



Ok. Thanks for looking at it.



I guess that we will have an incompatibility with WAS then.
I have tested the code only on servlet runners like tomcat and Jetty.
I will try to get hold on a WAS 8.0 testlicense to debug that out.
Won´t happen this week anymore though due to time constraints.
Are you running in an EAR environment or simple WAR environment?



It's running in an EAR environment. One other nuance: MyFaces Core is
loaded as part of a WAS shared library,  and Ext-Scripting is bundled
with the WAR/EAR. That seems logical to me, but should Ext-Scripting be in
the shared library instead?

Mhh just a wild guess here, ext-scripting is trying to avoid a 
classloaders for compatibility reasons in EAR containers, instead it 
uses a classloading plugin which myfaces loads upon initialisation, 
could be that the plugin is not found by myfaces due to different 
library environments.
At least it sounds like the plugin is not loaded into myfaces for 
whatever reason.


Give it a try with ext-scripting at the same position as myfaces, 
otherwise I will debug it out with the current trunk ASAP.


Werner





Re: [Extensions-Scripting] Java code changes not getting picked up

2012-09-04 Thread Werner Punz

Am 04.09.12 20:56, schrieb Werner Punz:

Am 04.09.12 20:40, schrieb Kito Mann:

On Tue, Sep 4, 2012 at 2:30 PM, Werner Punz werner.p...@gmail.com
wrote:


The config looks correct to me



Ok. Thanks for looking at it.



I guess that we will have an incompatibility with WAS then.
I have tested the code only on servlet runners like tomcat and Jetty.
I will try to get hold on a WAS 8.0 testlicense to debug that out.
Won´t happen this week anymore though due to time constraints.
Are you running in an EAR environment or simple WAR environment?



It's running in an EAR environment. One other nuance: MyFaces Core is
loaded as part of a WAS shared library,  and Ext-Scripting is bundled
with the WAR/EAR. That seems logical to me, but should Ext-Scripting
be in
the shared library instead?


Mhh just a wild guess here, ext-scripting is trying to avoid a
classloaders for compatibility reasons in EAR containers, instead it
uses a classloading plugin which myfaces loads upon initialisation,
could be that the plugin is not found by myfaces due to different
library environments.
At least it sounds like the plugin is not loaded into myfaces for
whatever reason.

Give it a try with ext-scripting at the same position as myfaces,
otherwise I will debug it out with the current trunk ASAP.


Sorry I meant it tries to avoid to register a custom classloader,
the context classloader of course is used to register the newly loaded 
classes.

So we have two possible point of failures
a) the plugin was not found by myfaces
b) the classloader which registers the classes is the wrong one

Either way, this needs some debugging.


Werner





Re: [Extensions-Scripting] Java code changes not getting picked up

2012-09-04 Thread Werner Punz
/javadump_tags_classes.html


-

   http://www-128.ibm.com/developerworks/java/library/j-dclp1/
   -

   http://www-128.ibm.com/developerworks/java/library/j-dclp2.html
   -

   http://www-128.ibm.com/developerworks/java/library/j-dclp3/
   -

   http://www-128.ibm.com/developerworks/java/library/j-dclp4/
   -

   http://www.redbooks.ibm.com/redpapers/pdfs/redp4307.pdf
   -


   
http://www.ibm.com/developerworks/websphere/library/techarticles/0112_deboer/deboer.html

-cheers,
Rohit


On Tue, Sep 4, 2012 at 2:38 PM, Kito Mann kito.m...@virtua.com wrote:


On Tue, Sep 4, 2012 at 2:36 PM, Rohit Kelapure kelap...@gmail.com wrote:


WAS 8 is free for developers. No license needed.
See  http://www.ibm.com/developerworks/downloads/ws/wasdevelopers/

What is the exact symptom of the problem ?



Basically, Ext-Scripting thinks it is re-loading classes, but it has no
affect on the runtime. It's almost like it's using the wrong class loader
or something.



-cheers,
ROhit


On Tue, Sep 4, 2012 at 2:30 PM, Werner Punz werner.p...@gmail.com

wrote:



The config looks correct to me
I guess that we will have an incompatibility with WAS then.
I have tested the code only on servlet runners like tomcat and Jetty.
I will try to get hold on a WAS 8.0 testlicense to debug that out.
Won´t happen this week anymore though due to time constraints.
Are you running in an EAR environment or simple WAR environment?



Werner

Am 04.09.12 17:02, schrieb Kito Mann:

  Hello Werner,


Thanks for looking into this. Here is the web.xml. I just realized

that

it's set to Servlet 2.5 instead of 3.0; could that be the problem?

?xml version=1.0 encoding=UTF-8?
web-app xmlns:xsi=http://www.w3.org/**2001/XMLSchema-instance

http://www.w3.org/2001/XMLSchema-instance


  xmlns=http://java.sun.com/**xml/ns/javaee

http://java.sun.com/xml/ns/javaee

xmlns:web=
http://java.sun.com/xml/ns/**javaee/web-app_2_5.xsd

http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd


  xsi:schemaLocation=http://**java.sun.com/xml/ns/javaee

http://java.sun.com/xml/ns/javaee

http://java.sun.com/xml/ns/**javaee/web-app_2_5.xsd

http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd


  id=WebApp_ID version=2.5

  filter
  filter-namescriptingFilter/**filter-name

filter-classorg.apache.**myfaces.extensions.scripting.**servlet.**
ScriptingServletFilter/**filter-class
  /filter
  filter-mapping
  filter-namescriptingFilter/**filter-name
  url-pattern/faces/*/url-**pattern
  dispatcherREQUEST/**dispatcher
  dispatcherFORWARD/**dispatcher
  dispatcherINCLUDE/**dispatcher
  dispatcherERROR/dispatcher
  /filter-mapping
  context-param
  description Initializes the plugins for our scripting

support

/description
  param-nameorg.apache.**myfaces.FACES_INIT_PLUGINS/**
param-name

param-valueorg.apache.**myfaces.extensions.scripting.**servlet.**
StartupServletContextPluginCha**inLoader/param-value
  /context-param

  context-param
  descriptionAdditional comma separated loader paths to allow
direct editing on the sources directory instead of the deployment dir
/description

param-nameorg.apache.**myfaces.extensions.scripting.**
java.LOADER_PATHS/param-name
  param-valueC:/workspaces/**src/param-value
  /context-param

  context-param
  param-name**log4jConfigLocation/param-**name
  param-value/WEB-INF/log4j.**properties/param-value
  /context-param

  context-param
  param-namejavax.faces.**PROJECT_STAGE/param-name
  param-valueDevelopment/**param-value
  /context-param
  context-param


  param-namejavax.faces.**FACELETS_REFRESH_PERIOD/**param-name

  param-value1/param-value
  /context-param
  context-param
  param-namejavax.faces.STATE_**SAVING_METHOD/param-name
  param-valueserver/param-**value
  /context-param
  context-param

param-namejavax.faces.**validator.DISABLE_DEFAULT_**
BEAN_VALIDATOR/param-name
  param-valuetrue/param-**value
  /context-param
  context-param

param-nameorg.apache.**myfaces.NUMBER_OF_VIEWS_IN_**
SESSION/param-name
  param-value25/param-value
  /context-param
  context-param
  param-namejavax.faces.**FACELETS_LIBRARIES/param-**name
  param-value/WEB-INF/custom.**taglib.xml/param-value
  /context-param
  context-param


  param-namejavax.faces.**VALIDATE_EMPTY_FIELDS/param-**name

  param-valuetrue/param-**value
  /context-param
  context-param
  param-namejavax.faces.**PARTIAL_STATE_SAVING/param-**name
  param-valuetrue/param-**value
  /context-param

  context-param
  param-nameprimefaces.THEME/**param-name
  param-valuenone/param-**value
  /context-param

  context-param
  param-nameprimefaces.SUBMIT**/param-name
  param-valuepartial/param-**value
  /context-param

Re: [Extensions-Scripting] Java code changes not getting picked up

2012-09-03 Thread Werner Punz

Am 31.08.12 21:44, schrieb Kito Mann:

I'm trying to get MyFaces Extensions-Scripting running on RAD 8.0 with WAS
8.0 on Win 7 (no this isn't my choice of tools...) The goal is to use the
dynamic Java class loading to avoid the hideously long WAS publish times.
For the most part, everything is working fine now, and Ext-Scripting
notices when the class has changed and outputs the full list of classes
that are being loaded to the console. Unfortunately, the changes aren't
being picked up by the application. I've tried several different scenarios
(using a specific LOADER_PATH, the default WEB-INF/java path, changing the
publishing settings, turning Build Automatically on or off, etc.), but I
haven't had any luck. Perhaps WAS is doing something different at the
classloader level than Ext-Scripting expects? Any ideas?
___

Kito D. Mann | @kito99 | Author, JSF in Action
Virtua, Inc. | http://www.virtua.com | JSF/Java EE training and consulting
http://www.JSFCentral.com - JavaServer Faces FAQ, news, and info |
@jsfcentral
+1 203-404-4848 x246

* Listen to the latest headlines in the JSF and Java EE newscast: *
http://blogs.jsfcentral.com/JSFNewscast/*
* Sign up for the JSFCentral Newsletter: http://oi.vresp.com/?fid=ac048d0e17

Mhh Hi Kito, currently Ext-Scripting is not tested on WAS, normally it 
should be picked up, normally the files should be picked up as soon as 
you have the loader path set or WEB-INF/java is set.
Sorry for not having been able to test Ext-Scripting on the big irons 
currently.



Werner





Re: [Extensions-Scripting] Java code changes not getting picked up

2012-09-03 Thread Werner Punz

Am 03.09.12 13:52, schrieb Werner Punz:

Am 31.08.12 21:44, schrieb Kito Mann:

I'm trying to get MyFaces Extensions-Scripting running on RAD 8.0 with
WAS
8.0 on Win 7 (no this isn't my choice of tools...) The goal is to use the
dynamic Java class loading to avoid the hideously long WAS publish times.
For the most part, everything is working fine now, and Ext-Scripting
notices when the class has changed and outputs the full list of classes
that are being loaded to the console. Unfortunately, the changes aren't
being picked up by the application. I've tried several different
scenarios
(using a specific LOADER_PATH, the default WEB-INF/java path, changing
the
publishing settings, turning Build Automatically on or off, etc.), but I
haven't had any luck. Perhaps WAS is doing something different at the
classloader level than Ext-Scripting expects? Any ideas?
___

Kito D. Mann | @kito99 | Author, JSF in Action
Virtua, Inc. | http://www.virtua.com | JSF/Java EE training and
consulting
http://www.JSFCentral.com - JavaServer Faces FAQ, news, and info |
@jsfcentral
+1 203-404-4848 x246

* Listen to the latest headlines in the JSF and Java EE newscast: *
http://blogs.jsfcentral.com/JSFNewscast/*
* Sign up for the JSFCentral Newsletter:
http://oi.vresp.com/?fid=ac048d0e17


Mhh Hi Kito, currently Ext-Scripting is not tested on WAS, normally it
should be picked up, normally the files should be picked up as soon as
you have the loader path set or WEB-INF/java is set.
Sorry for not having been able to test Ext-Scripting on the big irons
currently.


Btw. also give the latest trunk version a try i fixed several windows 
bugs in 1.0.3 along the way, it might work out for your.






Re: [Extensions-Scripting] Java code changes not getting picked up

2012-09-03 Thread Werner Punz

Am 03.09.12 13:52, schrieb Werner Punz:

Am 31.08.12 21:44, schrieb Kito Mann:

I'm trying to get MyFaces Extensions-Scripting running on RAD 8.0 with
WAS
8.0 on Win 7 (no this isn't my choice of tools...) The goal is to use the
dynamic Java class loading to avoid the hideously long WAS publish times.
For the most part, everything is working fine now, and Ext-Scripting
notices when the class has changed and outputs the full list of classes
that are being loaded to the console. Unfortunately, the changes aren't
being picked up by the application. I've tried several different
scenarios
(using a specific LOADER_PATH, the default WEB-INF/java path, changing
the
publishing settings, turning Build Automatically on or off, etc.), but I
haven't had any luck. Perhaps WAS is doing something different at the
classloader level than Ext-Scripting expects? Any ideas?
___

Kito D. Mann | @kito99 | Author, JSF in Action
Virtua, Inc. | http://www.virtua.com | JSF/Java EE training and
consulting
http://www.JSFCentral.com - JavaServer Faces FAQ, news, and info |
@jsfcentral
+1 203-404-4848 x246

* Listen to the latest headlines in the JSF and Java EE newscast: *
http://blogs.jsfcentral.com/JSFNewscast/*
* Sign up for the JSFCentral Newsletter:
http://oi.vresp.com/?fid=ac048d0e17


Mhh Hi Kito, currently Ext-Scripting is not tested on WAS, normally it
should be picked up, normally the files should be picked up as soon as
you have the loader path set or WEB-INF/java is set.
Sorry for not having been able to test Ext-Scripting on the big irons
currently.



Also I forgot, can you post your web.xml configuration?
You might have missed the init plugin for myfaces.


Werner





Re: Redirecting JUL Logging to other logging systems -- do we need to revisit our logging methodology?

2012-09-03 Thread Werner Punz
Just a minor sidequestion, why do you use the SLF4JBridgeHandler JUL 
layer instead of JUL directly?


Werner


Am 23.08.12 16:40, schrieb Mike Kienenberger:

Did you ever say something you really regretted?

I really regret saying that I strongly preferred JUL over SL4J on the
logging vote two years back[1].

[1] 
http://mail-archives.apache.org/mod_mbox/myfaces-dev/200906.mbox/%3c8f985b960906060447g30bb216ew62102b39be2a1...@mail.gmail.com%3E

I am currently using the SLF4JBridgeHandler for JUL during
development, and incurring the performance hits.

Barring other events, my plans are to default back to JUL logging for
production.

How are other people handling this?  I know at the time of the
discussion many people were switching to SL4J or still using log4j or
JCL, all of which would have the same performance issues.

Is it time to revisit our logging yet again, now that we know the
theoretical flexibility of JUL didn't live up to the practical reality
of using it?

slf4j and myfaces
http://mail-archives.apache.org/mod_mbox/myfaces-dev/200906.mbox/%3c2332f63b0906050818q6c74e615u2edc7cc2ec9f5...@mail.gmail.com%3E

[VOTE] jul instead of commons-logging
http://mail-archives.apache.org/mod_mbox/myfaces-dev/200906.mbox/%3c2332f63b0906091132y10cd0dadu4eb4a36dda6ae...@mail.gmail.com%3E

[VOTE] use of jul or commons logging on myfaces core 2.0
http://mail-archives.apache.org/mod_mbox/myfaces-dev/200910.mbox/%3cf6c92360909301905g104297a5m3bba5fb3d057...@mail.gmail.com%3E

https://issues.apache.org/jira/browse/MYFACES-2378






Re: Redirecting JUL Logging to other logging systems -- do we need to revisit our logging methodology?

2012-09-03 Thread Werner Punz

I back then voted for JUL mainly because I felt that one dependency less
is always a good thing for the core lib and jul seemed like a good 
choice given that it is part of the core lib.


Werner

Am 23.08.12 20:38, schrieb Ertio Lew:

Why doesn't Myfaces allows the flexibility to plug in your desired logging
SL4J implementation instead of restricting users to JUL/ Commons logging or
otherwise incurring the overheads of using bridgeHandlers etc ?!

On Thu, Aug 23, 2012 at 8:10 PM, Mike Kienenberger mkien...@gmail.comwrote:


Did you ever say something you really regretted?

I really regret saying that I strongly preferred JUL over SL4J on the
logging vote two years back[1].

[1]
http://mail-archives.apache.org/mod_mbox/myfaces-dev/200906.mbox/%3c8f985b960906060447g30bb216ew62102b39be2a1...@mail.gmail.com%3E

I am currently using the SLF4JBridgeHandler for JUL during
development, and incurring the performance hits.

Barring other events, my plans are to default back to JUL logging for
production.

How are other people handling this?  I know at the time of the
discussion many people were switching to SL4J or still using log4j or
JCL, all of which would have the same performance issues.

Is it time to revisit our logging yet again, now that we know the
theoretical flexibility of JUL didn't live up to the practical reality
of using it?

slf4j and myfaces

http://mail-archives.apache.org/mod_mbox/myfaces-dev/200906.mbox/%3c2332f63b0906050818q6c74e615u2edc7cc2ec9f5...@mail.gmail.com%3E

[VOTE] jul instead of commons-logging

http://mail-archives.apache.org/mod_mbox/myfaces-dev/200906.mbox/%3c2332f63b0906091132y10cd0dadu4eb4a36dda6ae...@mail.gmail.com%3E

[VOTE] use of jul or commons logging on myfaces core 2.0

http://mail-archives.apache.org/mod_mbox/myfaces-dev/200910.mbox/%3cf6c92360909301905g104297a5m3bba5fb3d057...@mail.gmail.com%3E

https://issues.apache.org/jira/browse/MYFACES-2378








Re: ViewExpiredException with valid session

2012-08-10 Thread Werner Punz

Am 09.08.12 16:04, schrieb Jarosław Szczepankiewicz:




Hmm... which versions of PrimeFaces and MyFaces are you using?
___


Server: tomcat 7, myfaces: 2.1.2, jdk 7, primefaces 3.3.1


2.1.2 is already rathe old, can you update myfaces and check if the 
problem goes away.





Re: ViewExpiredException with valid session

2012-08-10 Thread Werner Punz

Am 10.08.12 18:35, schrieb Werner Punz:

Am 09.08.12 16:04, schrieb Jarosław Szczepankiewicz:




Hmm... which versions of PrimeFaces and MyFaces are you using?
___


Server: tomcat 7, myfaces: 2.1.2, jdk 7, primefaces 3.3.1



2.1.2 is already rathe old, can you update myfaces and check if the
problem goes away.




The newest version is 2.1.8

Werner




Re: h:outputScript is not being loaded when located in ui:include that is initially rendered=false

2012-05-10 Thread Werner Punz
Hi, this looks like a bug to me, can you file a bugreport with an 
example on  https://issues.apache.org/jira/browse/MYFACES, so that

the fix will make it into the next release.

Werner


Am 10.05.12 08:05, schrieb Daniel Reznick:

Forgot to add that after I click on the show button and the script was
supposed to be loaded , it gets loaded if I click F5 / Ctrl + F5 / or hit
Enter in the URL of the browser...

Thanks again.

On Wed, May 9, 2012 at 6:11 PM, Daniel Reznickvedm...@gmail.com  wrote:


Hi

I'm trying to load some heavy js file only after a user have clicked on
button

so basically when user loads the main page there is a hidden page inside
ui:include

  h:body
 h:form
 h:commandButton value=ClickMe action=#{myBean.callme()}
 f:ajax render=includeWrapper/f:ajax
 /h:commandButton
 h:panelGroup id=includeWrapper
 wrapper
 h:panelGroup rendered=#{myBean.show}
 ui:include src=/page2.xhtml/ui:include
 /h:panelGroup
 /h:panelGroup
 /h:form
 /h:body


that hidden page goth:outputScript that should be rendered when  user
will click on the commandButton


page2.xhtml looks like this

ui:composition 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;
 xmlns:c=http://java.sun.com/jsp/jstl/core;


 #{myBean.show}
 h:outputScript library=js name=myscript.js
rendered=#{myBean.show}/
 Ww
/ui:composition


and my callme looks like this

 public void callme(){
 show = !show;
 System.out.println(cl me\t+show);
 }

This works perfectly in my mojarra sandbox , but for some reason it is not
being loaded in my Myfaces 2.0.11 application I even tried the latest 2.1.8
snapshot

Is there any web.xml configuration that I'm missing

Thanks ahead,


Daniel.








Re: ViewExpiredException

2012-05-08 Thread Werner Punz

To my knowledge the issue will be addressed by the JSF 2.2 spec.
So please be patient.


Werner


Am 08.05.12 12:21, schrieb Michael Heinen:

As far as I know there is still no better fix or workaround.
The portlet case is supported out of the box and the other 90% of the
real world projects need this workaorund.

Michael

Am 08.05.2012 12:11, schrieb Paul Rivera:

Hi Guys,

I just had a similar problem as with the one posted in this issue:
https://issues.apache.org/jira/browse/MYFACES-3159

Its about 1 year later since then. I was wondering if there is a
better fix/workaround for this aside from inserting the js snippet in
the link?

Best Regards,
Paul Rivera








Re: Is it possible to modify the (x,y) position of a graphical component ?

2012-05-05 Thread Werner Punz

Am 03.05.12 15:51, schrieb ayouB __:

hi every body,

I want to know please if there's a possibility to modify the (x,y) position of 
a JavaServer Faces graphical component (e.g : Button, inputText, Calendar ...) 
during the execution of the web application.

PS : I'm using JSF 2.0 (Apache MyFaces) and JBoss Richfaces 4.

Thanks in advance:) 

Hi Ayoub you have to use html + css + javascript for that.





Re: no parallel ajax requests anymore with JSF 2.1?

2012-04-23 Thread Werner Punz

Hi

Hard to say whether it is a good or bad feature, since I was not part of 
the discussion when they went for the serialized model I only can guess 
why it is like that. As I stated before, not being serialized would pose 
problems to the backend more precisely to the viewstate history.


You will lose viewstates and in the end will run into a viewexpired 
exception. Hence my two proposals on how to deal with a long running 
operation either push it out of the jsf domain or simply poll it while 
it performs in the background.


The Myfaces Queue Control adheres to the spec and does not allow 
parallel requests, I dont know about the Richfaces queue whether it is 
more flexible in this area.




Werner



Am 23.04.12 03:47, schrieb Paul Rivera:

Hi Werner,

I would have to agree with Michael.  Doesn't this spec constraint of having 
ajax calls serialized make one of the best features of ajax ineffective?  
Assuming that we can manage these requests properly, I think that there is a 
real advantage of allowing concurrent ajax calls.  Is there any way of 
configuring the jsf queue to allow this?


Best Regards,
Paul Rivera




  From: Werner Punzwerner.p...@gmail.com
To: users@myfaces.apache.org
Sent: Friday, 30 March 2012 6:50 PM
Subject: Re: no parallel ajax requests anymore with JSF 2.1?

Speaking of the spec, there is a reason why the requests are serialized,
you simply cannot do it without loosing the viewstate over time for the
long running request. The best bet to workaround this issue is to
offload the long running request to something outside of JSF
Servlet/Restful service whatever.

Another solution would be to trigger a short running request which in
the backend triggers a background operation which you can poll for being
finished. That would work within the limits of the JSF spec.



Werner



Am 30.03.12 08:46, schrieb Michael Heinen:

Hi Milo,

are you really 100% sure that this is possible with JSF 2.1 and
Richfaces 4.2?
Did you verify that the requests are in parallel via logging or breakpoins?

I tried a few combinations of the richfaces queues which were not
working in parallel.
Afaik the richfaces queues are on top of the JSF queue.
Nick Baleavski from Richfaces said this also (07/2011):
https://community.jboss.org/message/614023#614023
JSF 2 does not allow parallel AJAX requests, they are all being queued
and then sent in the serial order.

Another comment from Richfaces discussions, looking for concurrent
requests: https://community.jboss.org/message/648601#648601


For me this seems to be a major regression in JSF!
It does support jax now but no Ajax!
Could anybody explain this to me? It worked well with JSF 1.2.

Now I have to start new threads manually in a web container, which I
really don't like.
And the migration to another JSF version is again not estimable at all.

vG
Michael



Am 29.03.2012 15:45, schrieb Milo van der Zee:

Hello Michael,

in RichFaces you could add multiple queues and they won't wait for
eachother.

MAG,
Milo van der Zee


On Thu, 2012-03-29 at 15:30 +0200, Michael Heinen wrote:

Hi all,

I'm still converting my application (mayfaces, tomahawk and richfaces)
from JSF 1.2 to 2.1.

Now I noticed that parallel ajax requests are not working at all!
E.g. a long running request which calculates something and parallel poll
requests to fetch status or partial results until the first request is
finished.

I stumbled over Werner's Blog (at
http://werpublogs.blogspot.de/2011/07/apache-myfaces-jsfjs-queue-control.html)

which contains following statement:
The official spec enforces following behavior: if you submit an Ajax
post it is either sent directly if no other submit is running or
enqueued until the running ajax submit has terminated and then the
submit is issued.

Question:
Are there any workarounds to allow parallel requests?
Or do I have to start new threads manually in my backing beans, which I
really do not like?

Is there something like a migration guide available?
I read many documents and ppts about JSF 2 but never read anything about
this new queing so far.

Michael













[RELEASE] Apache MyFaces Ext-Scripting 1.0.2 and 1.0.3

2012-04-12 Thread Werner Punz

The Apache MyFaces team is pleased to announce the release of MyFaces
Ext-Scripting 1.0.2 and 1.0.3.

Apache MyFaces Ext-Scripting is a dynamic reloading Extension for Apache 
MyFaces, which adds support for various scripting languages as well as 
reloading of Java and various webartifacts.


Note due to changes in the codebase 1.0.2 and 1.0.3 is a combined 
announcement since 1.0.2 is the last release supporting MyFaces 1.2.x 
and MyFaces 2.0.x. From now on only MyFaces 2.1.x will be supported for 
the time being.


Source and binary distributions can be found under:
http://myfaces.apache.org/extensions/scripting/download.html

Extensive documentation can be found under:
http://myfaces.apache.org/extensions/scripting/

Short summary of new Features:
1.0.2 is a bugfix release, which reenables compatibility to the latest 
Myfaces versions.


1.0.3 is a major refactoring release which drops support for legacy 
myfaces versions and java 5 (java6 is the new baseline)
Additionally as new major feature, Scala dynamic reloading support has 
been added.




Release Notes - MyFaces Extensions Scripting - Version 1.0.3-FINAL

** Bug
* [EXTSCRIPT-126] - Ext-Val fails in Hello World page
* [EXTSCRIPT-155] - Some artifacts are not yet reloading
* [EXTSCRIPT-156] - dynamic annotations broken
* [EXTSCRIPT-158] - Dependency detection fails in certain scenarii
* [EXTSCRIPT-161] - Code improvement

** Improvement
* [EXTSCRIPT-154] - Code Rewrite/Refactoring

** New Feature
* [EXTSCRIPT-159] - Add scala language support if possible

Release Notes - MyFaces Extensions Scripting - Version 1.0.2-FINAL

** Improvement
* [EXTSCRIPT-150] - pom dependency fix and documentation update
* [EXTSCRIPT-151] - Make Ext-Scripting codecompatible with the 
latest myfaces versions


** Task
* [EXTSCRIPT-153] - Preparations for 1.0.2 final




Re: PPS ?

2012-04-03 Thread Werner Punz

Ok that is the explanation.
Ajax4JSF introduces its own ajax lifecycle, it bypasses the standard JSF 
Javascripts introduced with JSF 2.0. The question is more along the 
lines, do you still need a4j or is the standard Ajax stuff enough.

The blog entries I wrote about pps and the no_portlet_env only adheres
to what MyFaces 2.x brings out of the box, I cannot speak about 
extension frameworks there which run their own ajax lifecycle.



Werner


Am 02.04.12 16:18, schrieb Michael Heinen:

Hi Werner,

I tested various combinations with execute set to either @this or to
@region.
The usage of myfaces.config.pps=true does not result is less submitted
fields (checked with Fiddler2).
I use a4j:commandButtons (without children) for the submits.

myfaces.config.pps is set in the document head on initial page load,
right after myfaces.config.no_portlet_env=true.

Michael





Re: use collections with selectManyCheckboxes and JSF 2.1?

2012-04-03 Thread Werner Punz

Ok this seems like a bug to me, can you file a bugreport on

https://issues.apache.org/jira/browse/MYFACES

So that it will be fixed until the next release.
Leonardo our core maintainer is pretty quick in fixing bugs.

Werner


Am 02.04.12 15:45, schrieb Michael Heinen:

I use a List of SelectItems for the inner f:selectItems tag.
The value attribute of selectManyCheckbox points to an ArrayList with
Strings, representing the selected values.
The checkboxes are initially correctly checked, but after ajax
submission my model (MapSting,Object) contains StringArrays instead of
ArrayLists.

Indeed this worked well since JSF 1.0, but it does not work with 2.1
anymore in my case.
BTW: I use Tomcat 6.0.35 (and selectManyCheckboxes work well with
myfaces 1.2.10 and richfaces 3.3.3)

Michael





Am 02.04.2012 15:30, schrieb Werner Punz:

Am 02.04.12 11:56, schrieb Michael Heinen:


What's going wrong here?
How can I use Collections with selectManyCheckboxes and JSF 2.1?



Hi I usually pass a list of SelectItem Objects that has been working
since JSF 1.0.

Werner











Re: PPS ?

2012-04-03 Thread Werner Punz
Just to go more into details, to use the standard JSF pps you can use 
normal h:commandLinks and f:ajax.


h:commandLink 
  f:ajax execute=control1, control2 render=... /
/h:commandLink

This functionality comes out of the box.
By using this myfaces.config.pps=true should show results.


Werner


Am 03.04.12 09:08, schrieb Werner Punz:

Ok that is the explanation.
Ajax4JSF introduces its own ajax lifecycle, it bypasses the standard JSF
Javascripts introduced with JSF 2.0. The question is more along the
lines, do you still need a4j or is the standard Ajax stuff enough.
The blog entries I wrote about pps and the no_portlet_env only adheres
to what MyFaces 2.x brings out of the box, I cannot speak about
extension frameworks there which run their own ajax lifecycle.


Werner


Am 02.04.12 16:18, schrieb Michael Heinen:

Hi Werner,

I tested various combinations with execute set to either @this or to
@region.
The usage of myfaces.config.pps=true does not result is less submitted
fields (checked with Fiddler2).
I use a4j:commandButtons (without children) for the submits.

myfaces.config.pps is set in the document head on initial page load,
right after myfaces.config.no_portlet_env=true.

Michael









Re: AJAX Request - No Cache

2012-04-03 Thread Werner Punz
Hi the ajax cache control as such is not part of the spec afair. But 
normally you can assume that only dynamic data is served hence the 
no-cache. (This is just a guess from me)


The easiest way to enable caching might be over a servlet filter or a 
custom from the standard JSF Servlet derived from the standard servlet.
Outside of that you probably can plug in your own PartialViewContextImpl 
one way or the other (which probably will be harder)


Turning off caching for all ajax is a bad idea, but you might be able to 
turn it off selectively with whatever you do by passing down a custom 
parameter which then enables your overrides.



Werner



Am 03.04.12 10:12, schrieb Thomas Andraschko:

Hi,

as far as i can see, the PartialViewContextImpl sets No-Cache to all AJAX
requests.
Is this required in all cases?

We have an application with nearly static data which will changed only at
night.
Our search queries are implemented via URL params and the cache-header is
set to expires at 22:00.

In one list, we must implement an filter function via AJAX and this will
not be cached.

Any idea if this could produce any other problems?
Should i overwrite this behavior for this view? How can i do it without
much effort?

Or it is better to implement this also via URL params?

Thanks and best regards,
Thomas






Re: PPS ?

2012-04-03 Thread Werner Punz

Btw. the standard ajax calls also have an oncomplete over their listeners.
You can register listeners globally or dynamically for a single call 
which shows you following phases:


begin... before the ajax request is issued
complete... after the ajax request has completed but before the response 
is issued

success... once everything has completed successfully

in case of an error an error handler can be set.


To register a listener you can use following ways:
jsf.ajax.addOnEvent(function(evt) {
if(evt.status === complete) {
//do something here
}
});
you also can do it for a single request

f:ajax onevent=myeventHandler onerror=myErrorHandler /

As for our integrated queue control, you have read my blog regarding it :-)
It is of course not as extensive as the a4j queues.

Werner



Am 03.04.12 09:41, schrieb Michael Heinen:

Thanks Werner for your quick repsonses.
Good to know, that it's not compatible with a4j/richfaces.

a4j contains some useful adons ( e.g. oncomplete for custom javascript
calls after ajax calls, better queues, selfrendered outputpanels
etcetc). It's too much effort at the moment to replace all ajax commands
with standard components.

Michael


Am 03.04.2012 09:08, schrieb Werner Punz:

Ok that is the explanation.
Ajax4JSF introduces its own ajax lifecycle, it bypasses the standard
JSF Javascripts introduced with JSF 2.0. The question is more along
the lines, do you still need a4j or is the standard Ajax stuff enough.
The blog entries I wrote about pps and the no_portlet_env only adheres
to what MyFaces 2.x brings out of the box, I cannot speak about
extension frameworks there which run their own ajax lifecycle.


Werner


Am 02.04.12 16:18, schrieb Michael Heinen:

Hi Werner,

I tested various combinations with execute set to either @this or to
@region.
The usage of myfaces.config.pps=true does not result is less submitted
fields (checked with Fiddler2).
I use a4j:commandButtons (without children) for the submits.

myfaces.config.pps is set in the document head on initial page load,
right after myfaces.config.no_portlet_env=true.

Michael












Re: PPS ?

2012-04-02 Thread Werner Punz

Am 30.03.12 15:52, schrieb Michael Heinen:

Hi again,

I read an article about PPS at
http://werpublogs.blogspot.de/2011/07/apache-myfaces-jsfjs-queue-control.html

If I understand this correctly then the data passed to the server should
be reduced in ajax calls.

Correct, only the controls with are in the execute part should be 
submitted as values.




I added myfaces.config.pps = true on clientside as a script during
initial page load.
With Fiddler2 I cannot see any difference in the requests. The data sent
to the server with ajax (via Richfaces) seems to be identical.
Google does to help regarding the parameter.
My project runs with MyFaces 2.1.6.

The parameter is relatively beta, I will check if the functionality is 
broken tomorrow quickly

and will drop a note regarding it.


lG

Werner






Re: PPS ?

2012-04-02 Thread Werner Punz
Ok I did a quick check, pps should be enabled, however if you for 
instance have an execute=form then all the form values will be encoded

I have to do a deep investigation whether the param is broken or not.


Werner


Am 02.04.12 14:52, schrieb Werner Punz:

Am 30.03.12 15:52, schrieb Michael Heinen:

Hi again,

I read an article about PPS at
http://werpublogs.blogspot.de/2011/07/apache-myfaces-jsfjs-queue-control.html


If I understand this correctly then the data passed to the server should
be reduced in ajax calls.


Correct, only the controls with are in the execute part should be
submitted as values.



I added myfaces.config.pps = true on clientside as a script during
initial page load.
With Fiddler2 I cannot see any difference in the requests. The data sent
to the server with ajax (via Richfaces) seems to be identical.
Google does to help regarding the parameter.
My project runs with MyFaces 2.1.6.


The parameter is relatively beta, I will check if the functionality is
broken tomorrow quickly
and will drop a note regarding it.


lG

Werner










Re: PPS ?

2012-04-02 Thread Werner Punz
Ok I also did a function check, for me the pps param works. What is your 
ajax request, (jsf.ajax.request) call do you have the execute on a 
parent element which needs its childs executed or on single childs.


Werner


Am 02.04.12 14:59, schrieb Werner Punz:

Ok I did a quick check, pps should be enabled, however if you for
instance have an execute=form then all the form values will be encoded
I have to do a deep investigation whether the param is broken or not.


Werner


Am 02.04.12 14:52, schrieb Werner Punz:

Am 30.03.12 15:52, schrieb Michael Heinen:

Hi again,

I read an article about PPS at
http://werpublogs.blogspot.de/2011/07/apache-myfaces-jsfjs-queue-control.html



If I understand this correctly then the data passed to the server should
be reduced in ajax calls.


Correct, only the controls with are in the execute part should be
submitted as values.



I added myfaces.config.pps = true on clientside as a script during
initial page load.
With Fiddler2 I cannot see any difference in the requests. The data sent
to the server with ajax (via Richfaces) seems to be identical.
Google does to help regarding the parameter.
My project runs with MyFaces 2.1.6.


The parameter is relatively beta, I will check if the functionality is
broken tomorrow quickly
and will drop a note regarding it.


lG

Werner














Re: use collections with selectManyCheckboxes and JSF 2.1?

2012-04-02 Thread Werner Punz

Am 02.04.12 11:56, schrieb Michael Heinen:


What's going wrong here?
How can I use Collections with selectManyCheckboxes and JSF 2.1?


Hi I usually pass a list of SelectItem Objects that has been working 
since JSF 1.0.


Werner




Re: no parallel ajax requests anymore with JSF 2.1?

2012-03-30 Thread Werner Punz
Speaking of the spec, there is a reason why the requests are serialized, 
you simply cannot do it without loosing the viewstate over time for the 
long running request. The best bet to workaround this issue is to 
offload the long running request to something outside of JSF 
Servlet/Restful service whatever.


Another solution would be to trigger a short running request which in 
the backend triggers a background operation which you can poll for being 
finished. That would work within the limits of the JSF spec.




Werner



Am 30.03.12 08:46, schrieb Michael Heinen:

Hi Milo,

are you really 100% sure that this is possible with JSF 2.1 and
Richfaces 4.2?
Did you verify that the requests are in parallel via logging or breakpoins?

I tried a few combinations of the richfaces queues which were not
working in parallel.
Afaik the richfaces queues are on top of the JSF queue.
Nick Baleavski from Richfaces said this also (07/2011):
https://community.jboss.org/message/614023#614023
JSF 2 does not allow parallel AJAX requests, they are all being queued
and then sent in the serial order.

Another comment from Richfaces discussions, looking for concurrent
requests: https://community.jboss.org/message/648601#648601


For me this seems to be a major regression in JSF!
It does support jax now but no Ajax!
Could anybody explain this to me? It worked well with JSF 1.2.

Now I have to start new threads manually in a web container, which I
really don't like.
And the migration to another JSF version is again not estimable at all.

vG
Michael



Am 29.03.2012 15:45, schrieb Milo van der Zee:

Hello Michael,

in RichFaces you could add multiple queues and they won't wait for
eachother.

MAG,
Milo van der Zee


On Thu, 2012-03-29 at 15:30 +0200, Michael Heinen wrote:

Hi all,

I'm still converting my application (mayfaces, tomahawk and richfaces)
from JSF 1.2 to 2.1.

Now I noticed that parallel ajax requests are not working at all!
E.g. a long running request which calculates something and parallel poll
requests to fetch status or partial results until the first request is
finished.

I stumbled over Werner's Blog (at
http://werpublogs.blogspot.de/2011/07/apache-myfaces-jsfjs-queue-control.html)

which contains following statement:
The official spec enforces following behavior: if you submit an Ajax
post it is either sent directly if no other submit is running or
enqueued until the running ajax submit has terminated and then the
submit is issued.

Question:
Are there any workarounds to allow parallel requests?
Or do I have to start new threads manually in my backing beans, which I
really do not like?

Is there something like a migration guide available?
I read many documents and ppts about JSF 2 but never read anything about
this new queing so far.

Michael













Re: Best charting and reporting tools

2012-03-27 Thread Werner Punz

Am 26.03.12 17:43, schrieb ayouB __:


Hi every body,

I want know please which one is the best as an open source java and why :

1) charting library : JFreeChart, Charts4J ... etc.
2) Reporting library : JasperReport, IReport, SeamReports ... etc.


Thanks. 

For reports I would go with Jasper, this is a proven horse.




Re: Does JSF2.0 supports HTML5 ?!

2012-03-26 Thread Werner Punz

Am 26.03.12 12:11, schrieb ayouB __:


Hi every body,

I wanna know please if JSF2.0(MyFaces 2.1.6 core) supports HTML5 components ?!

Thanks. 
Hello, no not directly, you can use html5 constructs however in the html 
markup of the facelets, but there is no direct support yet.





Re: Help : tasks supported by RichFaces

2012-03-26 Thread Werner Punz

Am 26.03.12 13:55, schrieb Michael Heinen:

Did you try the richfaces forum?
https://community.jboss.org/en/richfaces?view=discussions

Am 26.03.2012 12:13, schrieb ayouB __:

Hello,

Does RichFaces4 supports :

1) Mobile components as it's the case for PrimeFaces.
2) Charts components (graphs)
3) Reporting components (PDF, Excel, Word, ...).

Thank you all.




Check the richfaces component docs for that.




Re: Problem with myfaces 2.1.7-SNAPSHOT (ClassCastException during RV(1) )

2012-03-20 Thread Werner Punz

Best bet is to file a bugreport to get this fixed asap.

Werner


Am 19.03.12 22:14, schrieb Wojtek K:

Hello!



Recently we switched from myfaces 2.1.6 to 2.1.7-SNAPSHOT (in 2.1.6 we have 
problems with ui:repeat).



With 2.1.7-SNAPSHOT sometimes we see this stacktrace:



Caused by: java.lang.ClassCastException: 
org.apache.myfaces.renderkit.html.HtmlTextRenderer cannot be cast to 
javax.faces.event.ComponentSystemEventListener
at 
javax.faces.component.UIComponent$EventListenerWrapper.restoreState(UIComponent.java:1600)
at 
javax.faces.component.UIComponentBase.restoreAttachedState(UIComponentBase.java:1878)
at javax.faces.component._DeltaList.restoreState(_DeltaList.java:254)
at 
javax.faces.component.UIComponentBase.restoreAttachedState(UIComponentBase.java:1878)
at 
javax.faces.component.UIComponentBase.restoreFullSystemEventListenerClassMap(UIComponentBase.java:2181)
at javax.faces.component.UIComponentBase.restoreState(UIComponentBase.java:2021)
at javax.faces.component.UIOutput.restoreState(UIOutput.java:209)
at 
javax.faces.component.UIComponentBase.processRestoreState(UIComponentBase.java:1593)
at 
org.apache.myfaces.view.facelets.DefaultFaceletsStateManagementStrategy$2.invokeContextCallback(DefaultFaceletsStateManagementStrategy.java:441)
at javax.faces.component.UIComponent.invokeOnComponent(UIComponent.java:227)
at 
javax.faces.component.UIComponentBase.invokeOnComponent(UIComponentBase.java:1136)
at javax.faces.component.UIComponent.invokeOnComponent(UIComponent.java:238)
at 
javax.faces.component.UIComponentBase.invokeOnComponent(UIComponentBase.java:1136)



Our views are very complicated so i can't find what is wrong.

Can this be bug in myfaces? or it is problem in ours views?



web.xml



context-param
 
param-nameorg.apache.myfaces.REFRESH_TRANSIENT_BUILD_ON_PSS_PRESERVE_STATE/param-name
 param-valuetrue/param-value
 /context-param

 context-param
 
param-nameorg.apache.myfaces.REFRESH_TRANSIENT_BUILD_ON_PSS/param-name
 param-valuetrue/param-value
 /context-param

 context-param
 param-namejavax.faces.PARTIAL_STATE_SAVING/param-name
 param-valuetrue/param-value
 /context-param


thanks



wojtek








Re: how to build a JSF 2.0 (MyFaces/Facelets) Project

2012-03-15 Thread Werner Punz

Am 15.03.12 01:33, schrieb Guy Rouillier:

On 3/14/2012 12:47 PM, ayouB __ wrote:


Hello every one,

I have sent a mail before that one where i explained problems i faced
while configuring the developpement environnement, unfortunately that
let me no where i spent a lot of time trying to find a solution but i
didn't anyway thank you all for your replies and your collaboration :)
The problem now is how to create and configure a jsf project under
eclipse helios IDE, what JARs i need, how to dowload them and where
can i find them, what version, and where should i put them (in my
class path, in my web app ...).
I'm really confused and i don't know what to do ! Please Help ^_^


http://www.eclipse.org/webtools/jsf/main.php


My personal opinion is if you want to get started with JSF dont bother 
with Eclipse just use Netbeans and whatever comes bundled with it 
(Mojarra in that case). It simply is a way superior plug and play 
solution than whatever comes with Eclipse. The IDE generally is easier 
to handle for beginners and less flakey.


But thats just my 2c.
Maven etc... is a little bit to hard and given how flakey Eclipses Maven 
plugin was the last time I had a look at it I cannot recommend it.





Re: how to build a JSF 2.0 (MyFaces/Facelets) Project

2012-03-14 Thread Werner Punz

Here is the relevant maven info
https://cwiki.apache.org/confluence/display/MYFACES/MyFaces+Archetypes+for+Maven

Cannot help with Eclipse.


Werner

Am 14.03.12 19:42, schrieb Leonardo Uribe:

Hi

In eclipse you can use the archetype and then load the project using
m2eclipse plugin: http://www.sonatype.org/m2eclipse .

regards,

Leonardo

El día 14 de marzo de 2012 13:35, José Luis Cetina
maxtorz...@gmail.com  escribió:

Helo ayouB im using Netbeans an is so easy to create a JSF Faceletes
proyect, why you dont test with netbeans?

2012/3/14 Mark Strubergstrub...@yahoo.de


Best is to use Maven.


$  mvn archetype:generate -DarchetypeGroupId=org.apache.myfaces.buildtools
-DarchetypeArtifactId=myfaces-archetype-helloworld20-owb

LieGrue,
strub



- Original Message -

From: ayouB __ayb-2...@hotmail.fr
To: users@myfaces.apache.org
Cc:
Sent: Wednesday, March 14, 2012 5:47 PM
Subject: how to build a JSF 2.0 (MyFaces/Facelets) Project


Hello every one,

I have sent a mail before that one where i explained problems i faced

while

configuring the developpement environnement, unfortunately that let me

no where

i spent a lot of time trying to find a solution but i didn't anyway thank
you all for your replies and your collaboration :)
The problem now is how to create and configure a jsf project under

eclipse

helios IDE, what JARs i need, how to dowload them and where can i find

them,

what version, and where should i put them (in my class path, in my web

app ...).

I'm really confused and i don't know what to do ! Please Help ^_^

Thanks.

AYOUB







--
---
*SCJA. José Luis Cetina*
---







Re: Both MyFaces and the RI are on your classpath. Please make sure to use only one of the two JSF-implementations.

2012-03-13 Thread Werner Punz
Mhh this looks like a bug in Glassfish to me, the entries  in the 
glassfish-web.xml look correct to me. Problem is generally that 
glassfish is not to keen on overrides of its system libs in my 
experience. Even while myfaces runs, try to replace Weld for instance 
and you run into a mess.

Glassfish as good as it is is an all or nothing pack in many cases.
But it has been some time since I last touched Glassfish, things might 
have changed.




Werner


Am 12.03.12 17:40, schrieb José Luis Cetina:

Im triying to start a new project for first time with myfaces, i always
used Mojarra but know i want to change but im having problems at the start:

My only requierement is use Glassfish 3.1.2.1.

Hi i have this WARNING:

*Both MyFaces and the RI are on your classpath. Please make sure to use
only one of the two JSF-implementations.*

Why this happend if im using only jars from myfaces?? maybe for glassfish i
think, i have these in my *glassfish-web.xml* file, under WEB-INF folder:

?xml version=1.0 encoding=UTF-8?
!DOCTYPE glassfish-web-app PUBLIC -//GlassFish.org//DTD GlassFish
Application Server 3.1 Servlet 3.0//EN 
http://glassfish.org/dtds/glassfish-web-app_3_0-1.dtd;
glassfish-web-app error-url=
 !--Para establecer el charset a utf8 y remover el mensaje de: PWC4011:
Unable to set request character encoding to UTF-8 from context--
 parameter-encoding default-charset=UTF-8/
 *class-loader delegate=false/*
*property name=useBundledJsf value=true/*
 !--class-loader delegate=true/--
 jsp-config
 property name=keepgenerated value=true
 descriptionKeep a copy of the generated servlet class' java
code./description
 /property
 /jsp-config
/glassfish-web-app

    

This is my web.xml

?xml version=1.0 encoding=UTF-8?
web-app version=3.0 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_3_0.xsd;
 context-param
 param-namejavax.faces.PROJECT_STAGE/param-name
 param-valueDevelopment/param-value
 /context-param
 context-param
 param-namecom.ocpsoft.pretty.DEVELOPMENT/param-name
 param-valuetrue/param-value
 /context-param
 context-param
 param-namejavax.faces.STATE_SAVING_METHOD/param-name
 param-valueserver/param-value
 /context-param
 context-param
 param-name
javax.faces.DATETIMECONVERTER_DEFAULT_TIMEZONE_IS_SYSTEM_TIMEZONE/param-name
 param-valuetrue/param-value
 /context-param
  context-param
 param-namejavax.faces.FACELETS_SKIP_COMMENTS/param-name
 param-valuetrue/param-value
 /context-param
 context-param

param-namecom.sun.faces.enableMissingResourceLibraryDetection/param-name
 param-valuetrue/param-value
 /context-param
 listener
 *
listener-classorg.apache.myfaces.webapp.StartupServletContextListener/listener-class
*
 /listener
 servlet
 servlet-nameFaces Servlet/servlet-name
 servlet-classjavax.faces.webapp.FacesServlet/servlet-class
 load-on-startup1/load-on-startup
 /servlet
 servlet-mapping
 servlet-nameFaces Servlet/servlet-name
 url-pattern/faces/*/url-pattern
 /servlet-mapping
 session-config
 session-timeout
 30
 /session-timeout
 /session-config
 welcome-file-list
 welcome-filefaces/index.xhtml/welcome-file
 /welcome-file-list
/web-app

    

Here are my libraries:

--MYFACES
myfaces-api-2.1.6.jar
myfaces-impl-2.1.6.jar
commons-beanutils-1.8.3.jar
commons-digester-1.8.jar
commons-logging-1.8.jar
commons-codec-1.1.1.jar
commons-collections-3.2.jar
--MYFACES CODI
myfaces-extcdi-alternative-implementation-module-1.0.4
myfaces-extcdi-bv1-module-api-1.0.4
myfaces-extcdi-bv1-module-impl-1.0.4
myfaces-extcdi-core-alternative-configuration-1.0.4
myfaces-extcdi-core-api-1.0.4
myfaces-extcdi-core-impl-1.0.4
myfaces-extcdi-jpa1-module-api-1.0.4
myfaces-extcdi-jpa1-module-impl-1.0.4
myfaces-extcdi-jsf20-module-api-1.0.4
myfaces-extcdi-jsf20-module-impl-1.0.4
myfaces-extcdi-jsf-alternative-configuration-1.0.4
myfaces-extcdi-message-module-api-1.0.4
myfaces-extcdi-message-module-impl-1.0.4
myfaces-extcdi-scripting-module-api-1.0.4
myfaces-extcdi-scripting-module-impl-1.0.4


I dont know if because the WARNING i have other problem:

javax.el.PropertyNotFoundException: Target Unreachable, identifier 'myBean'
resolved to null,

I have in my beans.xml file under WEB-INF this:

?xml version=1.0 encoding=UTF-8?
beans 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/beans_1_0.xsd;
/beans

and in my bean:

@Named
@ViewAccessScoped

Re: Profiling tool for JSF

2012-03-13 Thread Werner Punz

Ok I am dragging this into the users list

You mix things up here, Flex is a pure client side technology which runs 
in a plugin while JSF is server side which renders html into your 
presentation layer.

So if you need memory profiling you have to be clear that following happens

a) Flex everything is loaded into a plugin and runs there, the server 
provides services


b) JSF: You have a server wich renders the html
c) JSF: The browser itself not a runtime renders the page

So in JSFs case usually you have way less happening on the client and an 
occasional page refresh cleans up the memory (of course if you want to 
go entirely refresh less then you have more chances of running into mem 
issues). So most people are not really concerned about the client side 
memory consumption of a web page like most people are not concerned 
about it generally in web applications, if you just follow some golden 
rules regarding the media displayed like image sizes etc...


So for profiling:
a) Server side profiling is easy grab any good old java profiler there 
is and you can do memory and performance profiling on what happens on 
the server side. Netbeans has an excellent integrated profiler for 
instance which comes with the IDE for free.


b) Pure browser profiling, for rendering the pages etc... how many 
objects there are, yslow is ok it gives you not a memory indication (the 
memory display of your os does) but it gives you indication on where a 
page still can be optimized for your loading times.


For javascript performance profiling Firebug does an excellent job if 
your page has lots of javascript and you run into issues.


Javascript memory profiling, i am not aware of any tool by now which is 
free there are some commercial offerings, if someone knows any I would 
be happy to know it myself. For IE6 there is sieve which detects mem 
leaks, but outside of that I am not to aware of anything in this area.


General performance profiling of the webpage/aka load tests JMeter as 
others have pointed out is a great tool.


Sorry for not being able to point towards a all in one solution but you 
comparing JSF with Flex is like comparing apples with oranges.


Werner




Am 12.03.12 18:41, schrieb ayouB __:

Hi,

I want know if can i measure the memory size of my presentation layer (i
give an example with Adobe Flex cause ActionScript Language is an
Oriented Object Language so the presentation layer can be measured by
measuring its patterns which are the ActionScript Objects), can we do
this with JSF and if so what's the most popular plug-in charged to
execute that task ?
PS : I'm a new developper on JSF technology :)

Thanks.

Date: Mon, 12 Mar 2012 13:31:15 -0400
Subject: Re: Profiling tool for JSF
From: kito.m...@virtua.com
To: d...@myfaces.apache.org

Hello,

What are you trying to measure that you can't get from a standard Java
profiler? Or are you just trying to time parts of the life cycle?

On Monday, March 12, 2012, ayouB __ ayb-2...@hotmail.fr
mailto:ayb-2...@hotmail.fr wrote:
  Hi every one,
 
  I'm asking if there is a possibility to do a profiling test for a jsf
application (like what flash builder does for Adobe Flex), my question
is about profiling only the prensentation layer build with MyFaces 2.1.6
+ Richfaces 4 not the whole application (as it's known Adobe Flex is
Rich Client which it's not the case for JSF). If so, is there a tool or
a plug-in which does this ?
 
  Thanks.
 

--
___

Kito D. Mann | twitter: kito99 | Author, JSF in Action
Virtua, Inc. | http://www.virtua.com http://www.virtua.com/ | JSF/Java
EE training and consulting
http://www.JSFCentral.com http://www.jsfcentral.com/ - JavaServer
Faces FAQ, news, and info | twitter: jsfcentral
+1 203-404-4848 x3

* Listen to the latest headlines in the JSF and Java EE newscast:
http://blogs.jsfcentral.com/roller/editorsdesk/category/JSF+and+Java+EE+Newscast
* Sign up for the JSFCentral newsletter: http://oi.vresp.com/?fid=ac048d0e17






Re: Encryption librairies for JSF

2012-03-13 Thread Werner Punz

Set your server to https mode thats it...

Werner


Am 13.03.12 12:13, schrieb ayouB __:


hi,

I want that every client request and every server response be encrypted not just the users 
data login  password from the connection view (My application concern the 
electronic banking sector), so i'm asking if MyFaces can supports both of AES and RSA ?!



Date: Tue, 13 Mar 2012 11:50:19 +0100
From: manuel.ha...@kobil.com
To: users@myfaces.apache.org
Subject: Re: Encryption librairies for JSF

hi

what actually do you want to secure? what is your requirement for public
key cryptography?

Manuel.


Thank you my friend for your reply :)

I want just say that in the example you give me, there's only AES specified as 
the encryption algorithm. I'm wondering if MyFaces supports also RSA not just 
AES ?!



Date: Tue, 13 Mar 2012 11:20:50 +0100
Subject: Re: Encryption librairies for JSF
From: shopov.bogo...@gmail.com
To: users@myfaces.apache.org

http://wiki.apache.org/myfaces/Secure_Your_Application

On 13 March 2012 11:12, ayouB __ayb-2...@hotmail.fr  wrote:



Hi every body,

I'm asking if there is some librairies in JSF(MyFaces) for encryption like : 
Hash SHA for 512 - RSA/AES

Thanks.




--
Bogomil Bogo Shopov

Internet enthusiast in motion
http://about.me/bogo


#JRebel Community Guy, #OpenWeb Hacker, #Pirate Politician, #Web
Programmer and a Father. #Mozilla, #OpenData  #Foss Rebellion.
#Bulgarian Living in #Prague.





--
Dipl. Inform. Manuel Hartl
Software Architect

FlexSecure-Logo KobilGroup-Logo

FlexSecure GmbH
Industriestr. 12
D - 64297 Darmstadt
Tel: +49 (0) 6151 501 23-18
Fax: +49 (0) 6151 501 23-19

E-Mail: ha...@flexsecure.de
Internet: www.flexsecure.de

Geschäftsführer:
Erwin Stallenberger, Markus Ruppert

Amtsgericht Darmstadt HRB 8036
Umsatzsteuernummer: DE 214745269








Re: Buttons not reacting

2012-03-05 Thread Werner Punz
Hi that the oamsubmit.js is loaded is normal, this is a script which 
does the normal onclick behavior for command links.


The html is fine. The oamsubmit used to be inlined in old myfaces 
versions now it is externalized.The oamsubmit definitely is not the 
cause of the issue you face.



Werner



Am 05.03.12 11:57, schrieb Danijel Domazet:

Hi Werner,
Nothing is clicked, just the page is loaded, and yet I get this 
/javax.faces.resource/oamSubmit.js.faces


Here is a peace of generated html:

td colspan=3/td
td align=right height=20 colspan=2
script src=/EWC/javax.faces.resource/oamSubmit.js.faces?ln=org.apache.myfaces 
type=text/javascript
/script
a id=j_id_6:LOGIN onclick=return myfaces.oam.submitForm('j_id_6','j_id_6:LOGIN'); 
href=#
img style=border: none src=images/login.png
/a
/td


and here is the xhtml:

td colspan=3/td
td height=20 colspan=2 align=righth:commandLink id=LOGIN 
action=#{LoginBean.doLogin}h:graphicImage style=border: none value=images/login.png //h:commandLink
/td


Does that help?


Danijel Domazet
Software Developer

www.MainConcept.com
Rovi. Join the Entertainment.

-Original Message-
From: Werner Punz [mailto:werner.p...@gmail.com]
Sent: Saturday, March 03, 2012 12:10 PM
To: users@myfaces.apache.org
Subject: Re: Buttons not reacting

Hi the oamsubmit is the standard submit call rendered from myfaces but
it should not be called automatically, instead if you press a
commandLink/href it should be in the onclick handler.
Can you post your example somewhere so that we can have a look at it on
what is going wrong?
The reason why buttons stop reacting is probably because you lose your
viewstate in your configuration somewhere.

Werner



Am 02.03.12 12:37, schrieb Danijel Domazet:

Seems like this has to do with my initial Faces servlet: I am overriding 
org.apache.myfaces.webapp.MyFacesServlet. When I don't override, it works ok, 
like this:

servlet
servlet-nameFaces Servlet/servlet-name
servlet-classorg.apache.myfaces.webapp.MyFacesServlet/servlet-class
load-on-startup1/load-on-startup
/servlet


This is what happens: my first page is /login.faces. When I open this page, my class that 
owerrides MyFacesServlet is called *twice*. First time login.faces is the caller, and 
next time the caller is /javax.faces.resource/oamSubmit.js.faces, I have no idea where 
this call comes from, I have no java scripts on the page. This second time I execute 
HttpServletResponse.sendRedirect( /login.faces ). When I comment out this 
sendRedirect line all works well.



Danijel Domazet
Software Developer

www.MainConcept.com
Rovi. Join the Entertainment.

-Original Message-
From: Werner Punz [mailto:werner.p...@gmail.com]
Sent: Thursday, February 23, 2012 9:03 PM
To: users@myfaces.apache.org
Subject: Re: Buttons not reacting

Hi if it does not help, could you isolate the case in a small webapp?
So that we can have a deeper look into it.


Werner


Am 23.02.12 14:03, schrieb Danijel Domazet:

I'm using MyFaces.

Switching back from 2.1.5 to 2.0.2 did not help.

Let me check if 2.1.6 is out, even I wouldn't hope it will help.

Thanks.


Danijel Domazet
Software Developer

www.MainConcept.com
Rovi. Join the Entertainment.


-Original Message-
From: Werner Punz [mailto:werner.p...@gmail.com]
Sent: Wednesday, February 22, 2012 10:52 PM
To: users@myfaces.apache.org
Subject: Re: Buttons not reacting

Hi I remember vaguely in issue with myfaces 2.1.5 which sounds familiar
it should be fixed in 2.1.6.
Hence the question which implementation of jsf and which version.

Werner


Am 22.02.12 19:06, schrieb Danijel Domazet:

Hi.
Yes, I also use Tomahawk.
Let me try to switch back to 2.0. Will let you know if that solves the issue.


Danijel Domazet
Software Developer

www.MainConcept.com
Rovi. Join the Entertainment.


-Original Message-
From: Georg Portwich [mailto:portw...@blueskye.de]
Sent: Wednesday, February 22, 2012 5:22 PM
To: MyFaces Discussion
Subject: Re: Buttons not reacting

Hi Danijel,

I have accidentally installed tomahawk together with JSF2.1. In this
installation I have seen a similar strange behavior as you describe.
Switching back to JSF2.0 solved the issue.

Georg

Am 22.02.2012 15:32, schrieb Danijel Domazet:

Hi everyone,
I recently switched my project from JSF 1.2 to JSF 2.1.

Strange thing happens: I set up a project, and it works fine for some short time, and then suddenly 
(maybe after I do clean) stops working in a sense that clicking a button does not 
produce any action, backing bean's method is not called, just nothing happens. I have tried to do 
project clean and Eclipse restart, and even system restart but it did not help. Only 
thing that helped is that I created a brand new workspace, and new project - but same thing 
happened: this too worked only for short time and suddenly stoped working in the same way - buttons 
are just not reacting to clicks, and there is no way I can debug Java code to at least localize the 
problem.

What could

Re: Buttons not reacting

2012-03-03 Thread Werner Punz
Hi the oamsubmit is the standard submit call rendered from myfaces but 
it should not be called automatically, instead if you press a 
commandLink/href it should be in the onclick handler.
Can you post your example somewhere so that we can have a look at it on 
what is going wrong?
The reason why buttons stop reacting is probably because you lose your 
viewstate in your configuration somewhere.


Werner



Am 02.03.12 12:37, schrieb Danijel Domazet:

Seems like this has to do with my initial Faces servlet: I am overriding 
org.apache.myfaces.webapp.MyFacesServlet. When I don't override, it works ok, 
like this:

servlet
servlet-nameFaces Servlet/servlet-name
servlet-classorg.apache.myfaces.webapp.MyFacesServlet/servlet-class
load-on-startup1/load-on-startup
/servlet


This is what happens: my first page is /login.faces. When I open this page, my class that 
owerrides MyFacesServlet is called *twice*. First time login.faces is the caller, and 
next time the caller is /javax.faces.resource/oamSubmit.js.faces, I have no idea where 
this call comes from, I have no java scripts on the page. This second time I execute 
HttpServletResponse.sendRedirect( /login.faces ). When I comment out this 
sendRedirect line all works well.



Danijel Domazet
Software Developer

www.MainConcept.com
Rovi. Join the Entertainment.

-Original Message-
From: Werner Punz [mailto:werner.p...@gmail.com]
Sent: Thursday, February 23, 2012 9:03 PM
To: users@myfaces.apache.org
Subject: Re: Buttons not reacting

Hi if it does not help, could you isolate the case in a small webapp?
So that we can have a deeper look into it.


Werner


Am 23.02.12 14:03, schrieb Danijel Domazet:

I'm using MyFaces.

Switching back from 2.1.5 to 2.0.2 did not help.

Let me check if 2.1.6 is out, even I wouldn't hope it will help.

Thanks.


Danijel Domazet
Software Developer

www.MainConcept.com
Rovi. Join the Entertainment.


-Original Message-
From: Werner Punz [mailto:werner.p...@gmail.com]
Sent: Wednesday, February 22, 2012 10:52 PM
To: users@myfaces.apache.org
Subject: Re: Buttons not reacting

Hi I remember vaguely in issue with myfaces 2.1.5 which sounds familiar
it should be fixed in 2.1.6.
Hence the question which implementation of jsf and which version.

Werner


Am 22.02.12 19:06, schrieb Danijel Domazet:

Hi.
Yes, I also use Tomahawk.
Let me try to switch back to 2.0. Will let you know if that solves the issue.


Danijel Domazet
Software Developer

www.MainConcept.com
Rovi. Join the Entertainment.


-Original Message-
From: Georg Portwich [mailto:portw...@blueskye.de]
Sent: Wednesday, February 22, 2012 5:22 PM
To: MyFaces Discussion
Subject: Re: Buttons not reacting

Hi Danijel,

I have accidentally installed tomahawk together with JSF2.1. In this
installation I have seen a similar strange behavior as you describe.
Switching back to JSF2.0 solved the issue.

Georg

Am 22.02.2012 15:32, schrieb Danijel Domazet:

Hi everyone,
I recently switched my project from JSF 1.2 to JSF 2.1.

Strange thing happens: I set up a project, and it works fine for some short time, and then suddenly 
(maybe after I do clean) stops working in a sense that clicking a button does not 
produce any action, backing bean's method is not called, just nothing happens. I have tried to do 
project clean and Eclipse restart, and even system restart but it did not help. Only 
thing that helped is that I created a brand new workspace, and new project - but same thing 
happened: this too worked only for short time and suddenly stoped working in the same way - buttons 
are just not reacting to clicks, and there is no way I can debug Java code to at least localize the 
problem.

What could be the reason for such a strange behaviour?

Thanks in advance.



Danijel Domazet
Software Developer

www.MainConcept.com
Rovi. Join the Entertainment.














Re: Buttons not reacting

2012-02-23 Thread Werner Punz

Hi if it does not help, could you isolate the case in a small webapp?
So that we can have a deeper look into it.


Werner


Am 23.02.12 14:03, schrieb Danijel Domazet:

I'm using MyFaces.

Switching back from 2.1.5 to 2.0.2 did not help.

Let me check if 2.1.6 is out, even I wouldn't hope it will help.

Thanks.


Danijel Domazet
Software Developer

www.MainConcept.com
Rovi. Join the Entertainment.


-Original Message-
From: Werner Punz [mailto:werner.p...@gmail.com]
Sent: Wednesday, February 22, 2012 10:52 PM
To: users@myfaces.apache.org
Subject: Re: Buttons not reacting

Hi I remember vaguely in issue with myfaces 2.1.5 which sounds familiar
it should be fixed in 2.1.6.
Hence the question which implementation of jsf and which version.

Werner


Am 22.02.12 19:06, schrieb Danijel Domazet:

Hi.
Yes, I also use Tomahawk.
Let me try to switch back to 2.0. Will let you know if that solves the issue.


Danijel Domazet
Software Developer

www.MainConcept.com
Rovi. Join the Entertainment.


-Original Message-
From: Georg Portwich [mailto:portw...@blueskye.de]
Sent: Wednesday, February 22, 2012 5:22 PM
To: MyFaces Discussion
Subject: Re: Buttons not reacting

Hi Danijel,

I have accidentally installed tomahawk together with JSF2.1. In this
installation I have seen a similar strange behavior as you describe.
Switching back to JSF2.0 solved the issue.

Georg

Am 22.02.2012 15:32, schrieb Danijel Domazet:

Hi everyone,
I recently switched my project from JSF 1.2 to JSF 2.1.

Strange thing happens: I set up a project, and it works fine for some short time, and then suddenly 
(maybe after I do clean) stops working in a sense that clicking a button does not 
produce any action, backing bean's method is not called, just nothing happens. I have tried to do 
project clean and Eclipse restart, and even system restart but it did not help. Only 
thing that helped is that I created a brand new workspace, and new project - but same thing 
happened: this too worked only for short time and suddenly stoped working in the same way - buttons 
are just not reacting to clicks, and there is no way I can debug Java code to at least localize the 
problem.

What could be the reason for such a strange behaviour?

Thanks in advance.



Danijel Domazet
Software Developer

www.MainConcept.com
Rovi. Join the Entertainment.











Re: Buttons not reacting

2012-02-22 Thread Werner Punz

Hello

First of all, which implementation and which version of the implementation.
Do you get any errors in the log?
Can you show us some sample code of what you are doing?

Werner

Am 22.02.12 15:32, schrieb Danijel Domazet:

Hi everyone,
I recently switched my project from JSF 1.2 to JSF 2.1.

Strange thing happens: I set up a project, and it works fine for some short time, and then suddenly 
(maybe after I do clean) stops working in a sense that clicking a button does not 
produce any action, backing bean's method is not called, just nothing happens. I have tried to do 
project clean and Eclipse restart, and even system restart but it did not help. Only 
thing that helped is that I created a brand new workspace, and new project - but same thing 
happened: this too worked only for short time and suddenly stoped working in the same way - buttons 
are just not reacting to clicks, and there is no way I can debug Java code to at least localize the 
problem.

What could be the reason for such a strange behaviour?

Thanks in advance.



Danijel Domazet
Software Developer

www.MainConcept.com
Rovi. Join the Entertainment.






Re: Buttons not reacting

2012-02-22 Thread Werner Punz

Hi I remember vaguely in issue with myfaces 2.1.5 which sounds familiar
it should be fixed in 2.1.6.
Hence the question which implementation of jsf and which version.

Werner


Am 22.02.12 19:06, schrieb Danijel Domazet:

Hi.
Yes, I also use Tomahawk.
Let me try to switch back to 2.0. Will let you know if that solves the issue.


Danijel Domazet
Software Developer

www.MainConcept.com
Rovi. Join the Entertainment.


-Original Message-
From: Georg Portwich [mailto:portw...@blueskye.de]
Sent: Wednesday, February 22, 2012 5:22 PM
To: MyFaces Discussion
Subject: Re: Buttons not reacting

Hi Danijel,

I have accidentally installed tomahawk together with JSF2.1. In this
installation I have seen a similar strange behavior as you describe.
Switching back to JSF2.0 solved the issue.

Georg

Am 22.02.2012 15:32, schrieb Danijel Domazet:

Hi everyone,
I recently switched my project from JSF 1.2 to JSF 2.1.

Strange thing happens: I set up a project, and it works fine for some short time, and then suddenly 
(maybe after I do clean) stops working in a sense that clicking a button does not 
produce any action, backing bean's method is not called, just nothing happens. I have tried to do 
project clean and Eclipse restart, and even system restart but it did not help. Only 
thing that helped is that I created a brand new workspace, and new project - but same thing 
happened: this too worked only for short time and suddenly stoped working in the same way - buttons 
are just not reacting to clicks, and there is no way I can debug Java code to at least localize the 
problem.

What could be the reason for such a strange behaviour?

Thanks in advance.



Danijel Domazet
Software Developer

www.MainConcept.com
Rovi. Join the Entertainment.








Re: Myfaces 2.1.6 change of behaviour for h:outputScript

2012-02-13 Thread Werner Punz

Am 09.02.12 19:19, schrieb Bruno Aranda:

Good, that works. Thanks. Only that IntelliJ IDEA does not like it much.

Thats a bug in IDEA, I would suggest to file a bugreport. I cannot 
remember if I already filed one regarding this issue.





Re: onsumit not exeucted for ajax requests - alternative?

2012-02-06 Thread Werner Punz

Hi if you need to execute commands before any arbitrary ajax call
then you can add your own global ajax request listener via
jsf.ajax.addOnEvent(callback)


The callback is called three times per request, same as if you would
set it directly within the request, but on a global scale.

http://docs.oracle.com/cd/E17802_01/j2ee/javaee/javaserverfaces/2.0/docs/js-api/symbols/jsf.ajax.html

Unfortunately a deregistration is not possible within the jsf api within 
myfaces there is a way but that would break the compatibility of the 
code with Mojarra.



Werner





Am 02.02.12 11:05, schrieb Michael Heinen:

Hi,

I am currently migrating an application to JSF 2.1

I have a lot of ajax commands (richfaces) and some new f:ajax tags.
My forms contain some js functions which should be called during
onsubmit but unfortunately onsubmit is not called for ajax requests.

How can I specify some JS functions that should be executed before any
ajax call?
I do not want to add them to a few hundred commands manually and would
like to define the calls on a few spots as possible.

Thanks,
Michael






Re: onsumit not exeucted for ajax requests - alternative?

2012-02-06 Thread Werner Punz
The onsubmit is a simple callback coming from the dom tree, it is not 
executed during ajax because there is no form submit performed.


Have in mind on some browsers you dont even get the event with special 
dom configurations (aka, simple form posts not by submit buttons etc...)
or the event cannot be blocked, so do not entirely rely on this event, 
it is flakey.


For the ajax case:

You can use the global listeners however, set yourself a marker class or 
an attribute in your form element which should trigger the listener
and if you get an ajax request you can check for this marker whether you 
should intercept with your code or not.


Here is a short pseudo code example:
function submitHandler(data) {
if(data.status == begin) {
var src = data.source;

var form = getParentForm(src);
if(hasClass(form, myMarker)) {
intercept();
}
}
}


You cannot cancel the request that way, but at least you have a 
callback. Practically by throwing an error in your code the request then 
will be cancelled and an error handler will be called.

That might be a dirty way to cancel the request upfront.




Am 06.02.12 14:12, schrieb Michael Heinen:

Thanks Werner for the suggestion.

I created meanwhile a JIRA issue for this:
https://issues.apache.org/jira/browse/MYFACES-3460

A global js listener is unfortunately not what I need.
In my case it depends on the form, whether a js should be executed
during submission or not.
Some requests can run in parallel (e.g. autocompletion, pulls) while
others are blocking.

Do you know why the simple onsubmit of a form is not executed for ajax
requests?

Michael

Am 06.02.2012 14:02, schrieb Werner Punz:

Hi if you need to execute commands before any arbitrary ajax call
then you can add your own global ajax request listener via
jsf.ajax.addOnEvent(callback)


The callback is called three times per request, same as if you would
set it directly within the request, but on a global scale.

http://docs.oracle.com/cd/E17802_01/j2ee/javaee/javaserverfaces/2.0/docs/js-api/symbols/jsf.ajax.html


Unfortunately a deregistration is not possible within the jsf api
within myfaces there is a way but that would break the compatibility
of the code with Mojarra.


Werner





Am 02.02.12 11:05, schrieb Michael Heinen:

Hi,

I am currently migrating an application to JSF 2.1

I have a lot of ajax commands (richfaces) and some new f:ajax tags.
My forms contain some js functions which should be called during
onsubmit but unfortunately onsubmit is not called for ajax requests.

How can I specify some JS functions that should be executed before any
ajax call?
I do not want to add them to a few hundred commands manually and would
like to define the calls on a few spots as possible.

Thanks,
Michael













Re: onsumit not exeucted for ajax requests - alternative?

2012-02-06 Thread Werner Punz

 You can use the global listeners however, set yourself a marker class or
 an attribute in your form element which should trigger the listener
 and if you get an ajax request you can check for this marker whether you
 should intercept with your code or not.

Just forgot to mention in your case to prevent double submits, throwing 
an error to cancel the request is perfectly valid.

For limited time double submit prevention this might be handy as well
http://www.irian.at/de/blog/-/blogs/apache-myfaces-queue-control

Werner


Am 06.02.12 14:42, schrieb Werner Punz:

The onsubmit is a simple callback coming from the dom tree, it is not
executed during ajax because there is no form submit performed.

Have in mind on some browsers you dont even get the event with special
dom configurations (aka, simple form posts not by submit buttons etc...)
or the event cannot be blocked, so do not entirely rely on this event,
it is flakey.

For the ajax case:

You can use the global listeners however, set yourself a marker class or
an attribute in your form element which should trigger the listener
and if you get an ajax request you can check for this marker whether you
should intercept with your code or not.

Here is a short pseudo code example:
function submitHandler(data) {
if(data.status == begin) {
var src = data.source;

var form = getParentForm(src);
if(hasClass(form, myMarker)) {
intercept();
}
}
}


You cannot cancel the request that way, but at least you have a
callback. Practically by throwing an error in your code the request then
will be cancelled and an error handler will be called.
That might be a dirty way to cancel the request upfront.




Am 06.02.12 14:12, schrieb Michael Heinen:

Thanks Werner for the suggestion.

I created meanwhile a JIRA issue for this:
https://issues.apache.org/jira/browse/MYFACES-3460

A global js listener is unfortunately not what I need.
In my case it depends on the form, whether a js should be executed
during submission or not.
Some requests can run in parallel (e.g. autocompletion, pulls) while
others are blocking.

Do you know why the simple onsubmit of a form is not executed for ajax
requests?

Michael

Am 06.02.2012 14:02, schrieb Werner Punz:

Hi if you need to execute commands before any arbitrary ajax call
then you can add your own global ajax request listener via
jsf.ajax.addOnEvent(callback)


The callback is called three times per request, same as if you would
set it directly within the request, but on a global scale.

http://docs.oracle.com/cd/E17802_01/j2ee/javaee/javaserverfaces/2.0/docs/js-api/symbols/jsf.ajax.html



Unfortunately a deregistration is not possible within the jsf api
within myfaces there is a way but that would break the compatibility
of the code with Mojarra.


Werner





Am 02.02.12 11:05, schrieb Michael Heinen:

Hi,

I am currently migrating an application to JSF 2.1

I have a lot of ajax commands (richfaces) and some new f:ajax tags.
My forms contain some js functions which should be called during
onsubmit but unfortunately onsubmit is not called for ajax requests.

How can I specify some JS functions that should be executed before any
ajax call?
I do not want to add them to a few hundred commands manually and would
like to define the calls on a few spots as possible.

Thanks,
Michael

















Re: onsumit not exeucted for ajax requests - alternative?

2012-02-06 Thread Werner Punz
Definitely, our queue mechanisms just implement the bare necessities, 
but advanced queuing like multiple queues are in the Richfaces Queues

to my knowledge, it might be the better choice.

Werner


Am 06.02.12 16:00, schrieb Michael Heinen:

Werner, thanks for the explanation and pointing me to the Blog!
I'll have a look any play around with this.
Maybe RichFaces Queues are also an alternative for me because most of my
ajax commands are from Richfaces.

Thanks,
Michael


Am 06.02.2012 14:47, schrieb Werner Punz:

 You can use the global listeners however, set yourself a marker
class or
 an attribute in your form element which should trigger the listener
 and if you get an ajax request you can check for this marker whether
you
 should intercept with your code or not.

Just forgot to mention in your case to prevent double submits,
throwing an error to cancel the request is perfectly valid.
For limited time double submit prevention this might be handy as well
http://www.irian.at/de/blog/-/blogs/apache-myfaces-queue-control

Werner


Am 06.02.12 14:42, schrieb Werner Punz:

The onsubmit is a simple callback coming from the dom tree, it is not
executed during ajax because there is no form submit performed.

Have in mind on some browsers you dont even get the event with special
dom configurations (aka, simple form posts not by submit buttons etc...)
or the event cannot be blocked, so do not entirely rely on this event,
it is flakey.

For the ajax case:

You can use the global listeners however, set yourself a marker class or
an attribute in your form element which should trigger the listener
and if you get an ajax request you can check for this marker whether you
should intercept with your code or not.

Here is a short pseudo code example:
function submitHandler(data) {
if(data.status == begin) {
var src = data.source;

var form = getParentForm(src);
if(hasClass(form, myMarker)) {
intercept();
}
}
}


You cannot cancel the request that way, but at least you have a
callback. Practically by throwing an error in your code the request then
will be cancelled and an error handler will be called.
That might be a dirty way to cancel the request upfront.




Am 06.02.12 14:12, schrieb Michael Heinen:

Thanks Werner for the suggestion.

I created meanwhile a JIRA issue for this:
https://issues.apache.org/jira/browse/MYFACES-3460

A global js listener is unfortunately not what I need.
In my case it depends on the form, whether a js should be executed
during submission or not.
Some requests can run in parallel (e.g. autocompletion, pulls) while
others are blocking.

Do you know why the simple onsubmit of a form is not executed for ajax
requests?

Michael

Am 06.02.2012 14:02, schrieb Werner Punz:

Hi if you need to execute commands before any arbitrary ajax call
then you can add your own global ajax request listener via
jsf.ajax.addOnEvent(callback)


The callback is called three times per request, same as if you would
set it directly within the request, but on a global scale.

http://docs.oracle.com/cd/E17802_01/j2ee/javaee/javaserverfaces/2.0/docs/js-api/symbols/jsf.ajax.html




Unfortunately a deregistration is not possible within the jsf api
within myfaces there is a way but that would break the compatibility
of the code with Mojarra.


Werner





Am 02.02.12 11:05, schrieb Michael Heinen:

Hi,

I am currently migrating an application to JSF 2.1

I have a lot of ajax commands (richfaces) and some new f:ajax tags.
My forms contain some js functions which should be called during
onsubmit but unfortunately onsubmit is not called for ajax requests.

How can I specify some JS functions that should be executed before
any
ajax call?
I do not want to add them to a few hundred commands manually and
would
like to define the calls on a few spots as possible.

Thanks,
Michael
























Re: c:forEach stopped to work after switching to 2.0.11 , (2.0.5 2.0.8 was working just fine)

2012-01-18 Thread Werner Punz
Actually for him a backend component generation and appending the 
columns as child elements to the table from the backend (server side) 
also might work.


Werner


Am 17.01.12 17:49, schrieb Leonardo Uribe:

Hi

Take a look at:

https://issues.apache.org/jira/browse/MYFACES-3389

It explains the limitations of c:forEach and its model. It is a known
weakness of that component and there is no other fix than just make a
proper component like tomahawk t:columns and use it.

regards,

Leonardo Uribe

2012/1/17 Daniel Reznickvedm...@gmail.com


Just for the record,

event when i remove the explicit generation of the id attribute, and let
the myfaces generate the ids , i get the exact error , but this time the
duplicated id that is being shown in the alert message (cause of the
development mode set in the web.xml) , the duplicated id is being created
by the myfaces and looks like j_id782346873642587. (something like
that) , so its not cause of the id that I'm assigning explicitly

On Tue, Jan 17, 2012 at 5:59 PM, Leonardo Uribelu4...@gmail.com  wrote:


Hi

I agree mixing build time and render time tags in that way could cause
problems like the one described.

I can confirm there was a change on the id generation, see:

https://issues.apache.org/jira/browse/MYFACES-3329
https://issues.apache.org/jira/browse/MYFACES-3330
https://issues.apache.org/jira/browse/MYFACES-3331

By multiple reasons described on those issues, the change is valid and
strongly necessary.

The snippet provided reveals in that part an EL expression is used to
calculate the id:

  p:column



id=expenses_table_device_column#{expensesPage.fixStatisticsDateDate(unitOfTime)}

sortBy=SomeValue

Facelets algorithm uses internally other id
(ComponentSupport.MARK_CREATED), It is probably the problem starts here.
Maybe the id is changed in some part and does not match the component
correctly like ComponentSupport.MARK_CREATED, causing the duplicate id
exception.

Anyway, there are other ways to do what you want, and use that snippet is
not advisable.

regards,

Leonardo Uribe










Re: How to troubleshoot ViewExpiredException ?

2012-01-04 Thread Werner Punz

Hi Paul then the issue will be harder to nail down.

The problem I was referring to is only client side based and can only 
occur in multiple forms.
I doubt your problem has anything to do with the problem I was referring 
to, at least not directly, there must be at least a second part to this 
issue.


I was referring to following problem:

In an ajax update cycle you will get the ViewState from following part 
of the protocol

update id=javax.faces.ViewState![CDATA[VieState]]

Now the viewstate is applied to the originating form and all forms which 
are listed in the render targets. Per default.
Now in a multiform scenario if you dont define the render targets 
properly you can get old viewstates because there can be forms which do 
not get the updated value. Once you have a critical number of viewstate 
updates reached in the main form, the old viewstate referred in the 
second form is dropped from the state history and then you run into this 
issue.


This is a spec issue because the spec clearly states the paragraph above 
with the original form and the render targets. What I did was to add 
some extensions to the core spec behavior to ease the problem a little 
bit. But nevertheless the spec here has a leak, and this leak will be 
fixed as it seems in jsf 2.2 by one way or the other.


But the main issue I see in your problem here is that I dont think that 
this has anything to do with the problem that you guys lose the 
ViewState in a db rollback scenario at least not directly. But the 
problem could play in. Give the workarounds a try if it fixes your 
problem if not then we have to dig deeper.
Sidequestion, does the problem also occur in a single form case or only 
in the multi form case.


Nevertheless maybe Leonardo Uribe (our core maintainer) has an idea what 
could happen here. A viewstate lost usually is a case of trying to reach 
a component tree id which has been dropped of the state history.

(which in the non portlet case is 15-20 or so, dunno about the portlet case)
I will ping Leo so that he will jump into this thread.


Werner



Am 04.01.12 22:01, schrieb Paul Nicolucci:

No problem at all!  Another quick query about this issue.We only seem
to see this after our DB  rolls back due to a deadlock, we don't see this
under normal use.

Is that an expected behavior to only see this after some sort of error
occurs?  Just trying to broaden my understanding of what's going on!

Thanks again for all the information and help!

Regards,

Paul Nicolucci




  Werner Punz
  werner.punz@gmai
  l.com  To
users@myfaces.apache.org
  01/04/2012 03:11   cc
  PM
Subject
Re: How to troubleshoot
  Please respond to ViewExpiredException ?
  MyFaces
 Discussion
  us...@myfaces.ap
  ache.org






Hi Paul, glad I could help,
sorry that I mixed up your first name before.

Werner


Am 04.01.12 20:30, schrieb Paul Nicolucci:

Thanks for your response Werner, I'll share the information with my
co-workers.

Regards,

Paul





   Werner Punz
   werner.punz@gmai
   l.com

To

 users@myfaces.apache.org
   01/04/2012 01:56

cc

   PM


Subject

 Re: How to troubleshoot
   Please respond to ViewExpiredException ?
   MyFaces
  Discussion
   us...@myfaces.ap
   ache.org






Hi Nick, the no_portlet_env is strictly a fix for non portlet cases.
Where you simply can update all forms given with a new viewstate.
The idea is that in a non portlet environment you simply can update all
forms at once. In a portlet environment things are more difficult
because you can have multiple viewroots.

This cannot and will not work in a portlet environment. Because it will
fix all forms from document.

The root cause of the issue is a spec issue which will be addressed
to my knowledge in JSF 2.2.
In your case you can work around the issue by other ways.

a) Use the affected forms as render targets, every form as render target
will get the updated viewstate. This works in both Mojarra and MyFaces.

b) For myfaces only there is a second workaround, use simply a render
target in every form you have (a hidden div) then all forms having those
render targets will be updated properly.

A third way would be to fix the protocol itself, this might break third
party component libs however. You theoretically could add the viewroot
information in theextension   tag of the response via a custom partial
response writer.
Then on the client side parse

Re: How to troubleshoot ViewExpiredException ?

2012-01-04 Thread Werner Punz
Before going further, does this problem also occur in a non ajax case or 
is it entirely ajax related.


Werner



Am 05.01.12 08:24, schrieb Werner Punz:

Hi Paul then the issue will be harder to nail down.

The problem I was referring to is only client side based and can only
occur in multiple forms.
I doubt your problem has anything to do with the problem I was referring
to, at least not directly, there must be at least a second part to this
issue.

I was referring to following problem:

In an ajax update cycle you will get the ViewState from following part
of the protocol
update id=javax.faces.ViewState![CDATA[VieState]]

Now the viewstate is applied to the originating form and all forms which
are listed in the render targets. Per default.
Now in a multiform scenario if you dont define the render targets
properly you can get old viewstates because there can be forms which do
not get the updated value. Once you have a critical number of viewstate
updates reached in the main form, the old viewstate referred in the
second form is dropped from the state history and then you run into this
issue.

This is a spec issue because the spec clearly states the paragraph above
with the original form and the render targets. What I did was to add
some extensions to the core spec behavior to ease the problem a little
bit. But nevertheless the spec here has a leak, and this leak will be
fixed as it seems in jsf 2.2 by one way or the other.

But the main issue I see in your problem here is that I dont think that
this has anything to do with the problem that you guys lose the
ViewState in a db rollback scenario at least not directly. But the
problem could play in. Give the workarounds a try if it fixes your
problem if not then we have to dig deeper.
Sidequestion, does the problem also occur in a single form case or only
in the multi form case.

Nevertheless maybe Leonardo Uribe (our core maintainer) has an idea what
could happen here. A viewstate lost usually is a case of trying to reach
a component tree id which has been dropped of the state history.
(which in the non portlet case is 15-20 or so, dunno about the portlet
case)
I will ping Leo so that he will jump into this thread.


Werner



Am 04.01.12 22:01, schrieb Paul Nicolucci:

No problem at all! Another quick query about this issue.We only seem
to see this after our DB rolls back due to a deadlock, we don't see this
under normal use.

Is that an expected behavior to only see this after some sort of error
occurs? Just trying to broaden my understanding of what's going on!

Thanks again for all the information and help!

Regards,

Paul Nicolucci




Werner Punz
werner.punz@gmai
l.com To
users@myfaces.apache.org
01/04/2012 03:11 cc
PM
Subject
Re: How to troubleshoot
Please respond to ViewExpiredException ?
MyFaces
Discussion
us...@myfaces.ap
ache.org






Hi Paul, glad I could help,
sorry that I mixed up your first name before.

Werner


Am 04.01.12 20:30, schrieb Paul Nicolucci:

Thanks for your response Werner, I'll share the information with my
co-workers.

Regards,

Paul





Werner Punz
werner.punz@gmai
l.com

To

users@myfaces.apache.org
01/04/2012 01:56

cc

PM


Subject

Re: How to troubleshoot
Please respond to ViewExpiredException ?
MyFaces
Discussion
us...@myfaces.ap
ache.org






Hi Nick, the no_portlet_env is strictly a fix for non portlet cases.
Where you simply can update all forms given with a new viewstate.
The idea is that in a non portlet environment you simply can update all
forms at once. In a portlet environment things are more difficult
because you can have multiple viewroots.

This cannot and will not work in a portlet environment. Because it will
fix all forms from document.

The root cause of the issue is a spec issue which will be addressed
to my knowledge in JSF 2.2.
In your case you can work around the issue by other ways.

a) Use the affected forms as render targets, every form as render target
will get the updated viewstate. This works in both Mojarra and MyFaces.

b) For myfaces only there is a second workaround, use simply a render
target in every form you have (a hidden div) then all forms having those
render targets will be updated properly.

A third way would be to fix the protocol itself, this might break third
party component libs however. You theoretically could add the viewroot
information in theextension tag of the response via a custom partial
response writer.
Then on the client side parse this info to determine the viewroot of
your portlet and then update all forms within the portlet with the given
viewstate.

Another way would be to allow a custom parameter with the viewroot
parameter being passed down so that after the update the viewroot can be
determined by the client and all forms within its realm can be updated.
If you want this mechanism I can code it in this week for you guys. It
is merely an extension to the mechanims we already have so I see it as
non critical to add it.

It would look like

Re: How to troubleshoot ViewExpiredException ?

2011-12-29 Thread Werner Punz

Not really, the ViewExpired exception just means that
the current ViewState cannot be found anymore in the view history.
If you navigate
to a new page, you basically get a Tabula Rasa aka a new
ViewState.

Either way if it is the JSF Ajax problem, the javascript workaround
definitely will fix your issue.


Werner


Am 29.12.11 22:31, schrieb Rohit Kelapure:


Once this ViewExpiredException occurs does it affect other pages that do
NOT have multiple forms ?

--Thanks,
Rohit

On Wed, Dec 28, 2011 at 4:55 PM, Werner Punzwerner.p...@gmail.com  wrote:


Do you use multiple forms in conjunction with JSF ajax?

Werner


Am 28.12.11 18:30, schrieb Rohit Kelapure:


Dear all,

We have run into an issue with our application in production wherein once
a
database rollback occurs, our application state somehow gets messed and we
repeatedly keep seeing ViewExpiredExceptions like so ...

[12/24/11 3:51:52:301 EST] 03b3 SystemErr R
javax.faces.application.**ViewExpiredException: /showItem.xhtml No saved
view
state could be found for the view identifier: /showItem.xhtmlnull
[12/24/11 3:51:52:302 EST] 03b3 SystemErr R   at
org.apache.myfaces.lifecycle.**RestoreViewExecutor.execute(**
RestoreViewExecutor.java:128)**null
[12/24/11 3:51:52:302 EST] 03b3 SystemErr R   at
org.apache.myfaces.lifecycle.**LifecycleImpl.executePhase(**
LifecycleImpl.java:171)null
[12/24/11 3:51:52:302 EST] 03b3 SystemErr R   at
org.apache.myfaces.lifecycle.**LifecycleImpl.execute(**
LifecycleImpl.java:118)null

Caused by: javax.faces.application.**ViewExpiredException:
/showShoppingCart.xhtml No saved view state could be found for the view
identifier: /showShoppingCart.xhtml
at
org.apache.myfaces.lifecycle.**RestoreViewExecutor.execute(**
RestoreViewExecutor.java:128)
at
org.apache.myfaces.lifecycle.**LifecycleImpl.executePhase(**
LifecycleImpl.java:171)
at
org.apache.myfaces.lifecycle.**LifecycleImpl.execute(**
LifecycleImpl.java:118)
at com.ibm.faces20.portlet.**FacesPortlet.processAction(**
FacesPortlet.java:238)

This happens for ALL the JSF  facelets *.xhtml files in our application.
This is a JSF 2 application.

What is the next step in debugging these ViewExpiredExceptions ?
For starters I have enabled the trace *
  *=info:org.apache.myfaces.**lifecycle*=all*
*

*
All your tips are appreciated.

--Thanks,
Rohit Kelapure












Re: How to troubleshoot ViewExpiredException ?

2011-12-28 Thread Werner Punz

Do you use multiple forms in conjunction with JSF ajax?

Werner


Am 28.12.11 18:30, schrieb Rohit Kelapure:

Dear all,

We have run into an issue with our application in production wherein once a
database rollback occurs, our application state somehow gets messed and we
repeatedly keep seeing ViewExpiredExceptions like so ...

[12/24/11 3:51:52:301 EST] 03b3 SystemErr R
javax.faces.application.ViewExpiredException: /showItem.xhtml No saved view
state could be found for the view identifier: /showItem.xhtmlnull
[12/24/11 3:51:52:302 EST] 03b3 SystemErr R   at
org.apache.myfaces.lifecycle.RestoreViewExecutor.execute(RestoreViewExecutor.java:128)null
[12/24/11 3:51:52:302 EST] 03b3 SystemErr R   at
org.apache.myfaces.lifecycle.LifecycleImpl.executePhase(LifecycleImpl.java:171)null
[12/24/11 3:51:52:302 EST] 03b3 SystemErr R   at
org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)null

Caused by: javax.faces.application.ViewExpiredException:
/showShoppingCart.xhtml No saved view state could be found for the view
identifier: /showShoppingCart.xhtml
at
org.apache.myfaces.lifecycle.RestoreViewExecutor.execute(RestoreViewExecutor.java:128)
at
org.apache.myfaces.lifecycle.LifecycleImpl.executePhase(LifecycleImpl.java:171)
at
org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
at com.ibm.faces20.portlet.FacesPortlet.processAction(FacesPortlet.java:238)

This happens for ALL the JSF  facelets *.xhtml files in our application.
This is a JSF 2 application.

What is the next step in debugging these ViewExpiredExceptions ?
For starters I have enabled the trace *
  *=info:org.apache.myfaces.lifecycle*=all*
*
*
All your tips are appreciated.

--Thanks,
Rohit Kelapure






Re: JSF 2: t:saveState

2011-11-08 Thread Werner Punz

Am 11/8/11 3:09 PM, schrieb Rudy De Busscher:

Rafael,

The CODI scope is ViewAccessScope.  Bean is kept in 'memory' as long as it
is referenced in the view.

Regards
The Codi ViewAccessScope scope is superior to what jsf2 delivers, the 
Flash scope in JSF2 is more or less just a map which you can use 
programmatically.
I personally can only second the recommendation for the ViewAccessScope, 
it is probably the best you can get in this area for jsf2 currently.


Werner




Re: My Faces Tunning

2011-10-18 Thread Werner Punz
Still (I know it is not an option) but if you need to reduce session 
space JSF 2 is the way to go, the delta state saving can free a load of ram.


Werner


Am 10/17/11 10:58 PM, schrieb Scott O'Bryan:

Wow.. Looks like you've done a lot, but I personally think 5K is
unrealistic. Your right. Essentially JSF stores your component tree in
memory.

You MAY be able to enable client-side state saving which should free you
up some memory at the expense of storing the entire view tree on the
client. Additionally, a framework like orchestra or something home grown
may allow you to get rid of managed beans quicker.

One other thing. I don't know how Websphere works, but I know in the
case of WLS, it only serializes object when they are added to the
session. While this means they may need to be added again if they are
updated, it's not subject to this limitation your describing. I'm
wondering if WebSphere has some settings on the replication which might
get you some better results.

Scott

On 10/17/2011 02:16 PM, Boyd, David (Corporate) wrote:

All,



I am doing some investigation into how to shrink the amount of session
memory our JSF application is consuming on a per user basis.



We are using MyFaces 1.1.7 and Tomahawk 1.1.5 running on IBM Websphere
7.0 patch 19. (Not able to upgrade either of these items at this time)



IBM's guideline is that the session size should be less then 5k -
average around 2.5k in order not to impact performance of the server and
session replication. We are currently using Memory to Memory but
looking at moving to database as suggested by IBM.



Our site was running at about 35M per user. We changed the number of
view states from 100 to 10 and that dropped it down to around 4M.



We have several backing beans which are currently session scope and are
looking at changing them to request scope.



I also found the following:
http://www.econsulting.nl/images/pdf/Tuning%20JSF%20Applications-%20J-Sp
ring%202008.pdf which seems to have a lot of information concerning how
JSF handles certain content on the pages. This is still under
investigation to make sure what is stated make sense.



I have also read somewhere that regardless if the managed backing bean
is session or request scope is that the view state will still have the
bean and its content. So the view state size will not change. Looking
for clarification on this one.



The questions is are others facing the same issue in which JSF
applications tend to consume a lot of memory for a given users session?




What are some of the best practices to reduce this size if any or is
this just the way when using JSF?



Issues with session replication on IBM WebSphere when running a JSF
application?



What we see as a result of this is that in the event a user hops to
another server, the session data is not present due to how large the
data is and how long it takes to replicate. User experience issues.



We had seen an issue in which it appeared that changes to the object in
the session was not being updated correctly and have done some session
management tuning in which we customize the settings so that all session
attributes are written out. Looking at the .jar file it does appear
that myFaces is making the call correctly when the contents of the
object in the session changes. So WebSphere session listener should be
picking up that change.










[ANNOUNCE] Release of Apache MyFaces Ext-Scripting 1.0.1

2011-07-08 Thread Werner Punz
The Apache MyFaces team is pleased to announce the release of MyFaces 
Extension Scripting 1.0.1


This release is a minor bugfix release which reenables compatibility
for Apache MyFaces 2.0.5+.

Apache MyFaces Extension Scripting 1.0 is an extension project to Apache 
MyFaces which enables Groovy support and dynamic Java artifact reloading 
under JSF.


Temporary download site and documentation site location:

Extension-Scripting 1.0.1 can be downloaded under:
http://people.apache.org/~werpu/ext-script-site/download.html

And the documentation is currently hosted under:
http://people.apache.org/~werpu/ext-script-site/index.html


The artifacts also can be integrated via maven, please consult the 
documentation for further info.



Note: The download and documentation site is in a temporary location and 
will be moved to our main site in the upcoming weeks.









Re: [Tomahawk] t:inputCalendar do not work on IE9

2011-05-21 Thread Werner Punz

Am 13.05.11 08:17, schrieb Admirolas:

Hello,

I have tried my JSF application, that uses MyFaces Tomahawk 1.1.10 with
Internet Explorer 9. After click on calendar button I get JavaScript
error: DOM Exception: INVALID_CHARACTER_ERR (5). IE9 JavaScript debugger
shows, that exception is thrown in calendar/popcalendar.js line 164.
There is call to: document.createElement and passes html tag as parameter.

Maybe there is some workaround? A patch? Should I migrate to 1.2.10?

Admirolas

Hi this is unfortunately a known issue with ie9 I will patch this out 
next week. Actually it is not an issue, but ie9 behaves more spec 
compliant in that area. For a quick fix you can force IE9 into quirks 
mode if that is an option.



Werner




Re: [TRINIDAD] non-PPR ajax update

2011-05-11 Thread Werner Punz

Am 11.05.11 14:40, schrieb Scott O'Bryan:

k there is a number of issues with what you are doing
here.  As you probably know, TRINIDAD's ajax is not 'solely' about
content delivery.  It runs the JSF lifecycyle and updates the view
state and a bunch of other things.  While I don't know exactly why
it's failing, I'm not surprised it is.

Actually from my personal guess it is a lost viewstate because the jsf 
lifecycle is bypassed. The reason for pure jquery ajax probably being a 
little bit more responsive is the lack of the lifecycle handling.


I assume the you are in a jsf2 environment, if you look at the response
a jsf2 ajax call gives back there is always a viewstate variable 
returned in the response protocol which is generated from the server and 
if you bypass jsf this value either is lost or you might have an old 
value when you try to push the next jsf operation after the ajax call.


If you are in a JSF 1.x environment Trinidad I guess has something 
similar to keep the client in sync with the server viewstate.



 I'm wondering if you couldn't do the same thing your trying to
 accomplish usig JQuery by using Trinidad's Ajax instead.

I second that use jquery only for pure client operations and jqueries 
ajax only for the parts wich never touch jsf, if you want to go against 
jsf always use the plain jsf 2 jsf or whatever meta layer the underlying 
component lib provides.


Jquerys ajax is just a thin wrapper over the standard ajax mechanisms 
and does not have server side webframeworks in mind which have to deal 
with additional bookkeeping.


Werner








Vote for your favorite JSF 2.2 Issues

2011-04-19 Thread Werner Punz

Hello

Ed Burns and the EG have opened a public voting where you can vote for 
your favorite JSF 2.2 issues/feature requests. This is a public voting

and 5 votes per person are allowed.
Additional info can be found under Ed Burns blog.

http://www.java.net/blogs/edburns/

So if you want to see a feature in 2.2 vote for it.


Werner



Re: Vote for your favorite JSF 2.2 Issues

2011-04-19 Thread Werner Punz
Also additional info, the voting window is very short, it will be closed 
by tomorrow, sorry for posting the info late (better late then never)

So if you want your favorite bug in, please vote asap.

Werner


Am 19.04.11 10:05, schrieb Jakob Korherr:

Hi,

Thanks for the info, Werner.

I also wrote two blog entries about this stuff. One showing my top 5
issues [1] and the other one containing a link to all open JSF spec
issues with at least one vote [2].

If anyone is interested, you can check them out!

Regards,
Jakob

[1] http://www.jakobk.com/2011/04/jsf-2-2-vote-for-your-top-5-issues/
[2] http://www.jakobk.com/2011/04/jsf-2-2-spec-issues-with-at-least-one-vote/

2011/4/19, Werner Punzwerner.p...@gmail.com:

Hello

Ed Burns and the EG have opened a public voting where you can vote for
your favorite JSF 2.2 issues/feature requests. This is a public voting
and 5 votes per person are allowed.
Additional info can be found under Ed Burns blog.

http://www.java.net/blogs/edburns/

So if you want to see a feature in 2.2 vote for it.


Werner










[ANNOUNCE] Apache MyFaces Extension Scripting 1.0

2011-04-13 Thread Werner Punz
The Apache MyFaces team is pleased to announce the release of MyFaces 
Extension Scripting 1.0.


Apache MyFaces Extension Scripting 1.0 is an extension project to Apache 
MyFaces which enables Groovy support and dynamic Java artifact reloading 
under JSF.


Temporary download site and documentation site location:

Extension-Scripting 1.0 can be downloaded under:
http://people.apache.org/~werpu/ext-script-site/download.html

And the documentation is currently hosted under:
http://people.apache.org/~werpu/ext-script-site/index.html


The artifacts also can be integrated via maven, please consult the 
documentation for further info.



Release Notes - MyFaces Core - Version 2.0.5

The download pages and documentation for 1.0 currently are hosted in a 
temporary location until it is moved to the final location.

Also the current version only runs under Apache MyFaces 2.0.0-2.0.2.
A bugfix version 1.0.1 which enables the reloading up to MyFaces 2.0.5 
will follow soon. Work on it has begun, and the release will follow asap.





Re: Tomahawk Input Calendar is showing in the wrong position

2011-03-17 Thread Werner Punz
Hi Leo I am not entirely sure but as far as I can remember the input 
calendar basically does some offset calculation to determine the 
position, as far as I recall this is due to the fact that it needs an 
outer form to submit its values.
Now given all the browser quirks in the past this offset calculation 
might fail in complex css scenarios on some browsers.


Unless things have changed this might be the issue here.

Werner



Am 17.03.11 19:40, schrieb Leonardo Uribe:

Hi

That is something new. I have never seen that before. Maybe some css
configuration affects the div or the calendar, so maybe you need to
create a custom theme for the calendar so you can override the default
values where the popup appear.

The properties to do that are styleLocation, javascriptLocation and
imageLocation (in tomahawk for jsf 2.0 there is also styleLibrary,
javascriptLibrary and imageLibrary).

regards,

Leonardo

2011/3/17 emersonechofloripa.y...@gmail.com:

We changed the template of the page, and afterwards the calendar popup
started to appear away from the button.

The component configuration is:

t:inputCalendar value=#{ConsultaDiarioForm.dataInicio}
renderPopupButtonAsImage=true renderAsPopup=true
popupWeekString=Semana size=10popupTodayString=Hoje é
id=dataInicio popupDateFormat=dd/MM/ alt=Digite a data
inicial para pesquisar title=Digite a data inicial para pesquisar
/t:inputCalendar

The imagens of the before/After

Before:
https://picasaweb.google.com/lh/photo/H9ML-JtAIzj-5mXeunEM7SyftixIMAaR_uGG46TnU-0?feat=directlink

After:
https://picasaweb.google.com/lh/photo/-S1izZxddwHVR0EVg362TiyftixIMAaR_uGG46TnU-0?feat=directlink

I would like to highlight that when using firebug, it shows in the div
tag that wraps the calendar a fixed posiition by top and left style
attributes. We dont know however where this is set.

Any ideas?








Re: [Trinidad] Best Javascript package to use in a new render kit

2011-03-16 Thread Werner Punz
Hi Scott, MyFaces in its core _Runtime.js also uses some inheritance 
framework, you basically currently get single inheritance, namespacing

singletons and delegation.
What I have not provided yet due to the lack of need is mixins.

Also I have code to lazy load scripts etc...

I coded it because I felt it made sense to stay on the oo side of things 
even if it was just for jsf.js which has a limited scope and

so others who do not want to rely on a big framework like yui can get
basic OO into their own code without having to roll their own solution
(mostly Tomahawk was my main concern here which has a load of scripts 
which would benefit tremendously from being ooed)


But I would not recommend our core as sole base for an entirely newly 
written renderer part of a component framework, because it is limited in 
its scope, of providing the core language mechanism and some dom 
routines to get a good maintainable structuring into jsf.js and make 
browser optimizations somewhat easier.


Just wanted to add that as info.

Werner



Am 12.03.11 23:11, schrieb Scott O'Bryan:

Yes, ADF Faces.  The two share a similar API but ADFFces is much more rich.
  It has animations, push technologies, and some other things.  The
client-side JavaScript has been  re-engineered as well and while it uses
Trinidad as the foundation, there is a lot more on the client side.

Suffice to say that ADFFaces javascipt uses an inheritance framework that is
a little more robust then standard JS inheritance patterns.  We would have
to rip that out and allow he MyFaces projects to replace it with their own
grammars.

Scott

On Mar 12, 2011, at 11:14 AM, Walter Mourãowalter.mou...@gmail.com  wrote:

Hi Scott,

I know Oracle, for instance, has a very large renderkit extension

which is based on Trinidad Internals.  Now it's mostly geared toward
support of web business applications, but it really shows what can be
done with the framework.



Do you mean ADF Rich Faces ?

Why do you say it's mostly geared toward support of web business
applications ? what are the differences with the application that are done
currently with Trinidad ? Do you know if the ADF Rich Faces client code uses
some external (non-Oracle) javascript package ?

Thanks in advance,

Walter Mourão
http://waltermourao.com.br
http://arcadian.com.br
http://oriens.com.br



On Thu, Mar 10, 2011 at 10:59 AM, Scott O'Bryandarkar...@gmail.com  wrote:


Walter,

Yeah, while creating a new renderkit isn't trivial, the Trinidad
internals and API really lend themselves to allowing extensions to the
framework.

I know Oracle, for instance, has a very large renderkit extension
which is based on Trinidad Internals.  Now it's mostly geared toward
support of web business applications, but it really shows what can be
done with the framework.

I really would like to see a project like this get some traction
personally.  ;)

Scott

On Mar 6, 2011, at 5:39 AM, Walter Mourãowalter.mou...@gmail.com  wrote:


Thank you Dominik.

Just to be clear: the aim is not simply compete...
I think Trinidad has:
- rock solid back-end;
- support to non-javascript browser (I have applications running in old

data

collectors - windows mobile)
...
and I would like to keep most of the java code untouched when migrating

my

applications to an up to date UI.

I am personally highly involved in another open source project and I

don't

have much experience with JSF/Trinidad internals. I am not sure I can

help

much in such a task (create the new render kit), but I'm experimenting to
see if I should go ahead with Trinidad or just migrate to another

library.


Best regards,

Walter Mourão
http://waltermourao.com.br
http://arcadian.com.br
http://oriens.com.br



2011/3/6 Dominik Dorndomi...@dominikdorn.com


If you're really want to compete with PrettyFaces, IceFaces, RichFaces
etc.,
I suggest to take a look at

http://demo.sproutcore.com/sample_controls/
http://www.sproutcore.com

and rebuilt those for JSF.
Sproutcore is currently quite hyped in twitter and gains a lot of
interest, especially
in the rails community.




2011/3/6 Walter Mourãowalter.mou...@gmail.com:

Hi folks,
following the thread Concerns about the future of Trinidad I would

like

to

know the opinions about the best' Javascript package to use as a base

to

a

new Trinidad render kit.

JQueryhttp://jquery.org/

Dojo Toolkithttp://dojotoolkit.org/

(another options ?)

What do you think ? what about the licensing ?

Thanks,

Walter Mourão
http://waltermourao.com.br
http://arcadian.com.br
http://oriens.com.br





--
Dominik Dorn
http://dominikdorn.com
http://twitter.com/domdorn

Tausche Deine Lernunterlagen auf http://wu.studyguru.eu !










Re: [Trinidad] Best Javascript package to use in a new render kit

2011-03-11 Thread Werner Punz
Hi, we are very interested, btw. we probably have to read our own parts 
for the inheritance stuff, because we use inheritance, delegation

and singletons as structural core patterns ourselves in the core.
So if the tool needs meta information in this regard we will have to 
readd our own implementation stuff here.


Oh well I guess this is the krux of using a dynamic lanugage which does
not have inheritance and namespaces baked into the core itself.

I guess for every framework used all this information on how to deal 
with it must be added and hence tools like jsdoc simply fail on more 
complicated cases or frameworks which do not belong to the more popular 
ones.



Werner


Am 11.03.11 18:43, schrieb Scott O'Bryan:

So I did do some checking on this and we have something we are using
in-house here at Oracle. It uses a more robust javascript parser to
generate the Javadocs and even allows the code to be annotated to
produce much cleaner documentation. The only bad thing about it is that
we have some parsing for inheritance that is probably specific to our
richclient.

I talked with the guy who wrote and and he'd be willing to donate it if
people are interested. He said ripping out the proprietary stuff for
inheritance should be pretty easy and then the MyFaces community could
enhance to to allow the docs to work on our own stuff. Are people
interested?

If so, I can open up a discussion on the dev list with the specifics.

Scott

On 03/10/2011 10:59 AM, Scott O'Bryan wrote:

Very good points Leonardo, and your right about Trinidad's parser. I
do know that I've seen some stuff in-house which generates
javascriptDoc and even does auditing. Let me check to see if it's
something we can donate or if it's too specific to our legacy code..

On Mar 10, 2011, at 10:35 AM, Leonardo Uribelu4...@gmail.com wrote:


Hi

I think one of the problems right now it is necessary to overcome is
create
a javascript documentation maven plugin for trinidad, myfaces core
2.0.x,
and probably tobago.

If you take a look at the sites of those projects, you'll see there is
generated javadoc, tlddoc, facelets-tlddoc and other documentation
reports
available on the site. But there is not anything for javascript.

The reason is there is not a maven plugin written in java that do the
job.
In theory it is possible to use jsdoc toolkit, but unfortunately
there is
some code on myfaces core that by its structure can't be documented
properly
with that tool (I already tried it, it just don't), and mozilla rhino
causes
some problems when the goal is executed, because it loads the javascript
file too.

This is a good idea for a Google Summer Of Code, because in practice
half of
the solution is done. Trinidad javascript plugin contains a code that is
capable of parse javascript files (look the obfuscator), so what we
need is
use this code and create some code that scan for doclets (annotations
on the
comments), get the information and build a model and finally generate
the
documentation using a template tool like velocity. Again we have already
some code on myfaces builder plugin that could be useful.

Trinidad code is very robust. With JSF 2.0, we have a common ajax
framework,
so in theory it is possible to create custom ajaxified components and
make
them work together with trinidad. But I think what users wants is to
know
the details behind it and how they can extend or override trinidad
stuff.

regards,

Leonardo Uribe

2011/3/10 Scott O'Bryandarkar...@gmail.com


Walter,

Yeah, while creating a new renderkit isn't trivial, the Trinidad
internals and API really lend themselves to allowing extensions to the
framework.

I know Oracle, for instance, has a very large renderkit extension
which is based on Trinidad Internals. Now it's mostly geared toward
support of web business applications, but it really shows what can be
done with the framework.

I really would like to see a project like this get some traction
personally. ;)

Scott

On Mar 6, 2011, at 5:39 AM, Walter Mourãowalter.mou...@gmail.com
wrote:


Thank you Dominik.

Just to be clear: the aim is not simply compete...
I think Trinidad has:
- rock solid back-end;
- support to non-javascript browser (I have applications running in
old

data

collectors - windows mobile)
...
and I would like to keep most of the java code untouched when
migrating

my

applications to an up to date UI.

I am personally highly involved in another open source project and I

don't

have much experience with JSF/Trinidad internals. I am not sure I can

help

much in such a task (create the new render kit), but I'm
experimenting to
see if I should go ahead with Trinidad or just migrate to another

library.

Best regards,

Walter Mourão
http://waltermourao.com.br
http://arcadian.com.br
http://oriens.com.br



2011/3/6 Dominik Dorndomi...@dominikdorn.com


If you're really want to compete with PrettyFaces, IceFaces,
RichFaces
etc.,
I suggest to take a look at

http://demo.sproutcore.com/sample_controls/

Re: [Trinidad] Best Javascript package to use in a new render kit

2011-03-06 Thread Werner Punz
Hi Jquery has a good query engine and a lousy widget API, but due to its 
popularity despite its deficiencies people have programmed a load of 
widgets. I am not sure but I think primefaces recycles a lot of the 
jquery infrastructure.
The personal problem i have with jquery simply is, it scales really well 
if you need to add some stuff to an existing webpage but rolling bigger 
javascript stuff will get you into a huge mess. It does not even support 
inheritance out of the box, just basic mixins. Everything else is tacked 
on top of it. Widgets also seem to be an afterthought api wise although 
there is a bazillion of them in variying quality.



Dojo is more like a huge classlib, also has a very good query engine and 
a set of widgets, but putting the dojo components to use in an existing 
jsf lib is a huge task. Some people already have done it

www.dojofaces.org for instance.

Also dojo has its fair share of own infrastructure and marrying some 
parts of that with jsf can be quite a task.

Also if you dont buy a book getting the hang of it can be quite a task
and the community is and always has been somewhat smaller. Additionally 
to that it carries around a load of legacy code due to its age, not 
really needed anymore in modern browsers.


Outside of that one serious contender definitely is YUI which irks me to 
have the best overall code quality of the three big ones. But I have not 
done anything with it.



And probably a few new ones I am not aware of.


Here is a short checklist of what you have to check out
a) Is a proper renamespacing possible, which means you have to roll your 
own namespace so that applications which also integrated the same libary 
and widget set into the program do not collide with your corelib.


b) Is it fast and can it scale from mobile space up to html5?

c) How big is the community behind it, the library can be mediocre but 
if it has a big enough following you still will get usable recycleable 
results


d) does it have a good set of widgets which are easy to use and try to 
constrain themselves to their domain


e) If you need it does it provided the needed language infrastructure 
like inheritance etc...
The functional approach some modern libs follow scales well for queries 
and results but becomes problematic once you go into the control domain. 
Ideally mixing both gives the best results.


f) How far does the libary scale down

g) How are the license compatibilities, for instance LGPL is a no go, 
BSDish licenses are ok


In the end there will be no ideal library but it also would not make 
sense for a component set to start from scratch given all the code there is.



Werner

Am 06.03.11 11:33, schrieb Walter Mourão:

Hi folks,
following the thread Concerns about the future of Trinidad I would like to
know the opinions about the best' Javascript package to use as a base to a
new Trinidad render kit.

JQueryhttp://jquery.org/

Dojo Toolkithttp://dojotoolkit.org/

(another options ?)

What do you think ? what about the licensing ?

Thanks,

Walter Mourão
http://waltermourao.com.br
http://arcadian.com.br
http://oriens.com.br






Re: t:saveState With Icefaces Using JSF 1.1

2011-02-14 Thread Werner Punz

Am 12.02.11 10:37, schrieb ponic:


Hello,

I would like to know whether  Tomahawk'st:savestate works with JSF 1.1.
I been trying to use t:savestate to preserve values when I navigate back to
my page(Request Scope)

Could someone provide some insight?

Thanks

It should work.

Werner



Re: Issues with MyFaces on Tomcat 7

2011-01-26 Thread Werner Punz
Btw. I just checked the docs, if you need client side validation ext-val 
+ beanvalidation might be worthwhile to check out.
ext-val definitely supports client side validation and jsf2 has hooks 
into the bean validation api.


Werner


Am 25.01.11 16:21, schrieb Werner Punz:

Hi Matt first of all nice to see you here.

My personal guess goes towards Tomcat here, the
ValidatorLifecycleListener which fails to be registered is a Servlet
listener hence the container itself is responsible for loading.
For whatever reason, Tomcat 7 fails to find the
org.apache.shale.validator.faces.ValidatorLifecycleListener in its
classpath and throws the error.
Not sure why this happens, but I assume a Tomcat bug here, there were
some changes probably in the classloader due to the automated annotation
loading.

I assume Shale uses a context listener in a tld to enable the
ValidatorLifecycleListener so this might be the problem here, it might
resolve itself if you move the listener out of the tld and explicitely
declare it in your web.xml or as annotation. But this is just a wild
guessing here on my side.


Werner


Am 24.01.11 19:06, schrieb mraible:


I don't know if this is a MyFaces issues, but I tried upgrading from
1.2.7 to
2.0.3 today and 1) everything worked, but 2) it fails to work on
Tomcat 7.
Using 1.2.7 fails to work on Tomcat 7 as well. I'm using Shale's Commons
Validator support to get client-side validation. From my
faces-config.xml:

validator

validator-idorg.apache.shale.validator.CommonsValidator/validator-id

validator-classorg.apache.shale.validator.CommonsValidator/validator-class

/validator

Error from Tomcat 7:


[WARNING] [talledLocalContainer] Jan 24, 2011 10:58:47 AM
org.apache.catalina.core.StandardContext addApplicationListener
[WARNING] [talledLocalContainer] INFO: The listener
org.apache.myfaces.webapp.StartupServletContextListener is already
configured for this context. The duplicate definition has been ignored.
[WARNING] [talledLocalContainer] Jan 24, 2011 10:58:48 AM
org.apache.catalina.core.StandardContext listenerStart
[WARNING] [talledLocalContainer] SEVERE: Error configuring application
listener of class
[WARNING] [talledLocalContainer]
org.apache.shale.validator.faces.ValidatorLifecycleListener
[WARNING] [talledLocalContainer]
[WARNING] [talledLocalContainer] java.lang.ClassNotFoundException:
[WARNING] [talledLocalContainer]
org.apache.shale.validator.faces.ValidatorLifecycleListener
[WARNING] [talledLocalContainer]
[WARNING] [talledLocalContainer] at
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1643)

[WARNING] [talledLocalContainer] at
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1488)

[WARNING] [talledLocalContainer] at
org.apache.catalina.core.DefaultInstanceManager.loadClass(DefaultInstanceManager.java:415)

[WARNING] [talledLocalContainer] at
org.apache.catalina.core.DefaultInstanceManager.loadClassMaybePrivileged(DefaultInstanceManager.java:397)

[WARNING] [talledLocalContainer] at
org.apache.catalina.core.DefaultInstanceManager.newInstance(DefaultInstanceManager.java:118)

[WARNING] [talledLocalContainer] at
org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4458)

[WARNING] [talledLocalContainer] at
org.apache.catalina.core.StandardContext$1.call(StandardContext.java:5004)

[WARNING] [talledLocalContainer] at
org.apache.catalina.core.StandardContext$1.call(StandardContext.java:4999)

[WARNING] [talledLocalContainer] at
java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
[WARNING] [talledLocalContainer] at
java.util.concurrent.FutureTask.run(FutureTask.java:138)
[WARNING] [talledLocalContainer] at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)

[WARNING] [talledLocalContainer] at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)

[WARNING] [talledLocalContainer] at
java.lang.Thread.run(Thread.java:680)
[WARNING] [talledLocalContainer] Jan 24, 2011 10:58:48 AM
org.apache.catalina.core.StandardContext listenerStart
[WARNING] [talledLocalContainer] SEVERE: Skipped installing application
listeners due to previous error(s)

Any ideas?

Thanks,

Matt









Re: Issues with MyFaces on Tomcat 7

2011-01-25 Thread Werner Punz

Hi Matt first of all nice to see you here.

My personal guess goes towards Tomcat here, the 
ValidatorLifecycleListener which fails to be registered is a Servlet 
listener hence the container itself is responsible for loading.
For whatever reason, Tomcat 7 fails to find the 
org.apache.shale.validator.faces.ValidatorLifecycleListener in its 
classpath and throws the error.

Not sure why this happens, but I assume a Tomcat bug here, there were
some changes probably in the classloader due to the automated annotation 
loading.


I assume Shale uses a context listener in a tld to enable the 
ValidatorLifecycleListener so this might be the problem here, it might 
resolve itself if you move the listener out of the tld and explicitely 
declare it in your web.xml or as annotation. But this is just a wild 
guessing here on my side.



Werner


Am 24.01.11 19:06, schrieb mraible:


I don't know if this is a MyFaces issues, but I tried upgrading from 1.2.7 to
2.0.3 today and 1) everything worked, but 2) it fails to work on Tomcat 7.
Using 1.2.7 fails to work on Tomcat 7 as well. I'm using Shale's Commons
Validator support to get client-side validation. From my faces-config.xml:

 validator

validator-idorg.apache.shale.validator.CommonsValidator/validator-id

validator-classorg.apache.shale.validator.CommonsValidator/validator-class
 /validator

Error from Tomcat 7:


[WARNING] [talledLocalContainer] Jan 24, 2011 10:58:47 AM
org.apache.catalina.core.StandardContext addApplicationListener
[WARNING] [talledLocalContainer] INFO: The listener
org.apache.myfaces.webapp.StartupServletContextListener is already
configured for this context. The duplicate definition has been ignored.
[WARNING] [talledLocalContainer] Jan 24, 2011 10:58:48 AM
org.apache.catalina.core.StandardContext listenerStart
[WARNING] [talledLocalContainer] SEVERE: Error configuring application
listener of class
[WARNING] [talledLocalContainer]
org.apache.shale.validator.faces.ValidatorLifecycleListener
[WARNING] [talledLocalContainer]
[WARNING] [talledLocalContainer] java.lang.ClassNotFoundException:
[WARNING] [talledLocalContainer]
org.apache.shale.validator.faces.ValidatorLifecycleListener
[WARNING] [talledLocalContainer]
[WARNING] [talledLocalContainer]at
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1643)
[WARNING] [talledLocalContainer]at
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1488)
[WARNING] [talledLocalContainer]at
org.apache.catalina.core.DefaultInstanceManager.loadClass(DefaultInstanceManager.java:415)
[WARNING] [talledLocalContainer]at
org.apache.catalina.core.DefaultInstanceManager.loadClassMaybePrivileged(DefaultInstanceManager.java:397)
[WARNING] [talledLocalContainer]at
org.apache.catalina.core.DefaultInstanceManager.newInstance(DefaultInstanceManager.java:118)
[WARNING] [talledLocalContainer]at
org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4458)
[WARNING] [talledLocalContainer]at
org.apache.catalina.core.StandardContext$1.call(StandardContext.java:5004)
[WARNING] [talledLocalContainer]at
org.apache.catalina.core.StandardContext$1.call(StandardContext.java:4999)
[WARNING] [talledLocalContainer]at
java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
[WARNING] [talledLocalContainer]at
java.util.concurrent.FutureTask.run(FutureTask.java:138)
[WARNING] [talledLocalContainer]at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
[WARNING] [talledLocalContainer]at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
[WARNING] [talledLocalContainer]at
java.lang.Thread.run(Thread.java:680)
[WARNING] [talledLocalContainer] Jan 24, 2011 10:58:48 AM
org.apache.catalina.core.StandardContext listenerStart
[WARNING] [talledLocalContainer] SEVERE: Skipped installing application
listeners due to previous error(s)

Any ideas?

Thanks,

Matt





Re: How to persist null values with JSF2?

2011-01-11 Thread Werner Punz
It still is buggy, a friend of mine ran into issues with the latest 
tomcat 7 afair, and as soon as he replaced it with juel after my advice 
the issues were gone.


Werner


Am 10.01.11 17:22, schrieb Mark Struberg:

nope, I found the tomcat 7 EL to be buggy back when I did need it (should 
re-evaluate it soon) and use juel now [1]

LieGrue,
strub

[1] https://github.com/struberg/juel

--- On Mon, 1/10/11, Marsmanmars@gmx.de  wrote:


From: Marsmanmars@gmx.de
Subject: Re: How to persist null values with JSF2?
To: users@myfaces.apache.org
Date: Monday, January 10, 2011, 2:59 PM

After googling another 2 hours I found the solution: Since
tomcat 6.0.16 we
have to add the org.apache.el.parser.COERCE_TO_ZERO=false
VM argument.
@Strub: Did you have set this VM argument too?

For more infos:
http://balusc.blogspot.com/2008/07/dao-tutorial-use-in-jsf.html#EmptyToNullConverter
EmptyToNullConverter



struberg wrote:


Hmm, works perfectly over here when adding the

following to web.xml:

  context-param



param-namejavax.faces.INTERPRET_EMPTY_STRING_SUBMITTED_VALUES_AS_NULL/param-name



param-valuetrue/param-value

  /context-param

as Jakob already suggested.

LieGrue,
strub

--- On Mon, 1/10/11, Marsmanmars@gmx.de

wrote:



From: Marsmanmars@gmx.de
Subject: Re: How to persist null values with

JSF2?

To: users@myfaces.apache.org
Date: Monday, January 10, 2011, 1:52 PM


The action on the commandButton calls a

save()-Method in my

backing bean. At
this point, I got the empty fields instead of

null. You can

see this in my
initial post. I'm using JPA with Hibernate.

Titus



struberg wrote:


Did you do your debugging in your backing

bean action

or do you only look

at the database? If JPA is involved, then the

jpa

provider may replace

null with empty strings (known issue on

oracle).


LieGrue,
strub

--- On Mon, 1/10/11, Marsmanmars@gmx.de

wrote:







--
View this message in context: 
http://old.nabble.com/How-to-persist-null-values-with-JSF2--tp30622750p30634470.html
Sent from the MyFaces - Users mailing list archive at
Nabble.com.












Re: Does flash.keep work in MyFaces?

2011-01-04 Thread Werner Punz

Hi, this might be a bug, it would be good to file a bugreport on this one.


Werner



Am 31.12.10 20:31, schrieb am am:

Hi,

I am starter in JSF2.0 and picked up MyFaces 2.0.3.
Also I am using Tomcat 7 and eclipse (Helios)- added JSF facet.
I have a trivial application trying to use flash via redirection but it seems it
does not work.

Please note that if I switch libraries and use Mojarra implementation instead it
works fine! Am I missing something in MyFaces configuration?

Example as follows:
1) A facelet called Entry.xhtml

h:form
table
   tr
 tdFirst Name:/td
 td
   h:inputText id=fname value=#{flash.firstName}required=true/
 /td
   /tr
   tr
 tdLast Name:/td
 td
   h:inputText id=lname value=#{flash.lastName}   required=true/
 /td
   /tr
/table
  ph:commandButton value=Submit action=confirmation?faces-redirect=true
//p
  /h:form

and the confirmation.xhtml:
table
   tr
 tdFirst Name:/td
 td
   h:outputText value=#{flash.keep.firstName} /
 /td
   /tr
   tr
 tdLast Name:/td
 td
   h:outputText value=#{flash.keep.lastName}/
 /td
/tr
/table
h:form
ph:commandButton value=Confirm action=finished?faces-redirect=true //p
/h:form


But when the confirmation page is loaded, the firstName and lastName I submitted
is missing. Why? I am using flash.keep. According to what I read it should
keep the values more than a PRG cycle.
It works if I use Mojarra.

Thank you!








Re: GAE problem

2010-12-16 Thread Werner Punz
Hk Nikolay: I gave your code a testrun in my GAE project and could not 
reproduce the error. But have in mind I did not add all your settings 
just the page and the needed settings for primefaces.


You can use my project as base for your next steps or can have a look 
where the error causing difference might be (Have in mind I am using 
facelets not jsp)

http://dl.dropbox.com/u/9533199/TestGAE.tar.bz2

also: here is the running page:

http://10.latest.testinck4040.appspot.com/gaetest2.jsf

Also not I turned off encryption and switched to server mode due to
GAE seeming to have resolved the issues it had with the session.
This speeds things up a little bit.



Werner


Am 14.12.10 17:43, schrieb Nikolay Rychkov:

That is good to be desired.
Thank you very much.

2010/12/14 Werner Punzwerner.p...@gmail.com


Hi Nikolay, I hope you dont mind that I have to postpone the testing and
debugging of your stuff til thurstday, I have been bound by job issues today
and tomorrow I am bound privately. Your stuff is next on my list.

Werner


Am 13.12.10 22:40, schrieb Nikolay Rychkov:

  I have this error during local run. I didn't try to deploy it. All my

beans
are menaged beans

package ru.agost.jsf.graphml;

import javax.faces.bean.ManagedBean;
import javax.faces.bean.RequestScoped;
import java.io.Serializable;

/**
  * Date: 06.08.2010
  * Time: 2:55:36
  *p/
  *
  * @author Николай Рычков
  */
@ManagedBean
@RequestScoped
public class GraphmlInputBean implements Serializable{
 private static final long serialVersionUID = 5817856927436316046L;

 String key;

 String fileName;

 String body;



 public GraphmlInputBean() {
 }

 public String getKey() {
 return key;
 }

 public void setKey(String key) {
 this.key = key;
 }

 public String getFileName() {
 return fileName;
 }

 public void setFileName(String fileName) {
 this.fileName = fileName;
 }

 public String getBody() {
 return body;
 }

 public void setBody(String body) {
 this.body = body;
 }
}

2010/12/14 Werner Punzwerner.p...@gmail.com

  Ok thanks a lot I will look into it tomorrow, just one last question, do

you get the error only if you deploy or do you get it in the local
testing
scenario as well, and are your beans you reference normal managed beans?

Werner


Am 13.12.10 22:03, schrieb Nikolay Rychkov:

  ?xml version=1.0 encoding=UTF-8?


project xmlns=http://maven.apache.org/POM/4.0.0; xmlns:xsi=
http://www.w3.org/2001/XMLSchema-instance;
  xsi:schemaLocation=http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd;
 modelVersion4.0.0/modelVersion

 !-- The Basics --
 groupIdru.agost/groupId
 artifactIdagost/artifactId
 version1.0/version
 packagingwar/packaging

 nameAgost/name
 descriptionAgost description/description

 repositories
 repository
 idjava.net/id
 nameGlassFish Maven Repository/name
 urlhttp://download.java.net/maven/glassfish/url
 /repository
 repository
 idobjectify-appengine/id
 urlhttp://objectify-appengine.googlecode.com/svn/maven
/url
 /repository
 repository
 idrepo1.maven.org/id
 nameJava.net Repository for Maven/name
 urlhttp://repo1.maven.org/maven2//url

 /repository
 repository
 idgoogle-maven-repo/id
 nameGoogle Maven Repository/name
 url
http://google-maven-repository.googlecode.com/svn/repository//url
 /repository
 repository
 idmaven-gae-plugin-repo1/id
 nameMaven Google App Engine Repository/name
 urlhttp://maven-gae-plugin.googlecode.com/svn/repository/
/url
 /repository

 repository
 idobjectweb/id
 nameObjectweb repository/name
 urlhttp://maven.objectweb.org/maven2/url
 /repository
 repository
 idjboss/id
 nameJBoss Maven2 repository/name
 urlhttp://repository.jboss.com/maven2//url
 snapshots
 enabledfalse/enabled
 /snapshots
 releases
 enabledtrue/enabled
 /releases
 /repository
 repository
 idglassfish/id
 nameGlassfish repository/name
 urlhttp://download.java.net/maven/1/url
 layoutlegacy/layout
 releases
 enabledtrue/enabled
 /releases
 snapshots
 enabledfalse/enabled
 /snapshots
 /repository
 repository
 idapache.snapshots/id
 nameApache Snapshot Repository/name
 url
 http://people.apache.org/repo/m2-snapshot-repository
 /url
 releases
 enabledfalse/enabled
 

Re: GAE problem

2010-12-14 Thread Werner Punz
Hi Nikolay, I hope you dont mind that I have to postpone the testing and 
debugging of your stuff til thurstday, I have been bound by job issues 
today and tomorrow I am bound privately. Your stuff is next on my list.


Werner


Am 13.12.10 22:40, schrieb Nikolay Rychkov:

I have this error during local run. I didn't try to deploy it. All my beans
are menaged beans

package ru.agost.jsf.graphml;

import javax.faces.bean.ManagedBean;
import javax.faces.bean.RequestScoped;
import java.io.Serializable;

/**
  * Date: 06.08.2010
  * Time: 2:55:36
  *p/
  *
  * @author Николай Рычков
  */
@ManagedBean
@RequestScoped
public class GraphmlInputBean implements Serializable{
 private static final long serialVersionUID = 5817856927436316046L;

 String key;

 String fileName;

 String body;



 public GraphmlInputBean() {
 }

 public String getKey() {
 return key;
 }

 public void setKey(String key) {
 this.key = key;
 }

 public String getFileName() {
 return fileName;
 }

 public void setFileName(String fileName) {
 this.fileName = fileName;
 }

 public String getBody() {
 return body;
 }

 public void setBody(String body) {
 this.body = body;
 }
}

2010/12/14 Werner Punzwerner.p...@gmail.com


Ok thanks a lot I will look into it tomorrow, just one last question, do
you get the error only if you deploy or do you get it in the local testing
scenario as well, and are your beans you reference normal managed beans?

Werner


Am 13.12.10 22:03, schrieb Nikolay Rychkov:

  ?xml version=1.0 encoding=UTF-8?

project xmlns=http://maven.apache.org/POM/4.0.0; xmlns:xsi=
http://www.w3.org/2001/XMLSchema-instance;
  xsi:schemaLocation=http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd;
 modelVersion4.0.0/modelVersion

 !-- The Basics --
 groupIdru.agost/groupId
 artifactIdagost/artifactId
 version1.0/version
 packagingwar/packaging

 nameAgost/name
 descriptionAgost description/description

 repositories
 repository
 idjava.net/id
 nameGlassFish Maven Repository/name
 urlhttp://download.java.net/maven/glassfish/url
 /repository
 repository
 idobjectify-appengine/id
 urlhttp://objectify-appengine.googlecode.com/svn/maven
/url
 /repository
 repository
 idrepo1.maven.org/id
 nameJava.net Repository for Maven/name
 urlhttp://repo1.maven.org/maven2//url

 /repository
 repository
 idgoogle-maven-repo/id
 nameGoogle Maven Repository/name
 url
http://google-maven-repository.googlecode.com/svn/repository//url
 /repository
 repository
 idmaven-gae-plugin-repo1/id
 nameMaven Google App Engine Repository/name
 urlhttp://maven-gae-plugin.googlecode.com/svn/repository/
/url
 /repository

 repository
 idobjectweb/id
 nameObjectweb repository/name
 urlhttp://maven.objectweb.org/maven2/url
 /repository
 repository
 idjboss/id
 nameJBoss Maven2 repository/name
 urlhttp://repository.jboss.com/maven2//url
 snapshots
 enabledfalse/enabled
 /snapshots
 releases
 enabledtrue/enabled
 /releases
 /repository
 repository
 idglassfish/id
 nameGlassfish repository/name
 urlhttp://download.java.net/maven/1/url
 layoutlegacy/layout
 releases
 enabledtrue/enabled
 /releases
 snapshots
 enabledfalse/enabled
 /snapshots
 /repository
 repository
 idapache.snapshots/id
 nameApache Snapshot Repository/name
 url
 http://people.apache.org/repo/m2-snapshot-repository
 /url
 releases
 enabledfalse/enabled
 /releases
 snapshots
 enabledtrue/enabled
 /snapshots
 /repository
 repository
 idops4j.repository/id
 nameOPS4J Repository/name
 urlhttp://repository.ops4j.org/maven2/url
 releases
 enabledtrue/enabled
 /releases
 snapshots
 enabledfalse/enabled
 /snapshots
 /repository
 repository
 idCodehaus Snapshots/id
 urlhttp://snapshots.repository.codehaus.org//url
 snapshots
 enabledtrue/enabled
 /snapshots
 releases
 enabledfalse/enabled
 /releases
 /repository

 repository
 idprime-repo/id
 

Re: java.io.InvalidObjectException: enum constant attributes does not exist in class javax.faces.component.UIComponent$PropertyKeys

2010-12-13 Thread Werner Punz

Am 12.12.10 16:31, schrieb Werner Punz:

Ok we have a local problem maybe as well, I filed a bug under
https://issues.apache.org/jira/browse/MYFACES-3000

Not sure if it is just a settings issue or whatever, either way
I cannot blame the behavior on GAE anymore.

Werner
Ok after rerunning everything with encryption turned off and encryption 
on default, the error seems to be gone both locally and in gae in server 
side state saving.

So I assume that it was my encryption settings. I removed the bug entry.
But we have a bug in our GAE page which has defaults which cause the 
ViewExpired exception error.


Werner




Re: GAE problem

2010-12-13 Thread Werner Punz

Hi can you show me your web.xml,
I have done some extensive jsf testing on the weekend with gae and did 
not have this error.



Werner

Am 13.12.10 18:45, schrieb Nikolay Rychkov:

I have this error in every page on GAE:
What is it?



java.lang.IllegalStateException: STREAM
at org.mortbay.jetty.Response.getWriter(Response.java:616)
at
javax.servlet.ServletResponseWrapper.getWriter(ServletResponseWrapper.java:115)
at
org.apache.myfaces.context.servlet.ServletExternalContextImpl.getResponseOutputWriter(ServletExternalContextImpl.java:184)
at
org.apache.myfaces.shared_impl.view.JspViewDeclarationLanguageBase.renderView(JspViewDeclarationLanguageBase.java:154)
at
org.apache.myfaces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:263)
at
org.apache.myfaces.lifecycle.RenderResponseExecutor.execute(RenderResponseExecutor.java:85)
at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:239)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:191)
at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:390)
at
org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)
at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:418)
at
com.google.apphosting.utils.jetty.DevAppEngineWebAppContext.handle(DevAppEngineWebAppContext.java:70)
at org.mortbay.jetty.servlet.Dispatcher.forward(Dispatcher.java:327)
at org.mortbay.jetty.servlet.Dispatcher.forward(Dispatcher.java:126)
at
com.google.appengine.tools.development.StaticFileUtils.serveWelcomeFileAsForward(StaticFileUtils.java:80)
at
com.google.appengine.tools.development.LocalResourceFileServlet.maybeServeWelcomeFile(LocalResourceFileServlet.java:247)
at
com.google.appengine.tools.development.LocalResourceFileServlet.doGet(LocalResourceFileServlet.java:120)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:693)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:806)
at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
at
org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1166)
at
com.google.appengine.api.blobstore.dev.ServeBlobFilter.doFilter(ServeBlobFilter.java:58)
at
org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)
at
com.google.apphosting.utils.servlet.TransactionCleanupFilter.doFilter(TransactionCleanupFilter.java:43)
at
org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)
at
com.google.appengine.tools.development.StaticFileFilter.doFilter(StaticFileFilter.java:122)
at
org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)
at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:388)
at
org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)
at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:418)
at
com.google.apphosting.utils.jetty.DevAppEngineWebAppContext.handle(DevAppEngineWebAppContext.java:70)
at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
at
com.google.appengine.tools.development.JettyContainerService$ApiProxyHandler.handle(JettyContainerService.java:349)
at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
at org.mortbay.jetty.Server.handle(Server.java:326)
at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
at
org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:923)
at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:547)
at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
at
org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:409)
at
org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)






Re: GAE problem

2010-12-13 Thread Werner Punz

Ok outside of the crypto stuff I do not see any problem.
Try to remove the encryption alltogether for a quick testing and see if 
it resolves your problem (also turn it off).

The problem also could be primefaces related.
With the exact crypto config i also had problems (I think the 
documentation is not entirely correct on our page there, I noticed that 
after a while I got viewexpiredexceptions with that one)


What myfaces version do you use. I did my testing on 2.0.2 but my 
testcase was rather basic:


http://2.testinck4040.appspot.com/welcome.jsf


Werner



Am 13.12.10 20:28, schrieb Nikolay Rychkov:

?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;
 display-name
 Sight www.agost.ru
 /display-name
 description
 I really need www.agost.ru
 /description

 context-param

  
param-nameorg.apache.myfaces.config.annotation.LifecycleProvider/param-name

  
param-valueorg.apache.myfaces.config.annotation.NoInjectionAnnotationLifecycleProvider/param-value
 /context-param
!--
 Need to set a secret to avoid javax.crypto.BadPaddingException.
 param-value must be Base64 encoded.
 More details:
http://wiki.apache.org/myfaces/Secure_Your_Application
  --
 context-param
 param-nameorg.apache.myfaces.SECRET/param-name
 param-valuex/param-value
 /context-param

 !-- * GAE 1.3.0 appears to handle server-side state saving. *
  --
 !--context-param--
 !--param-namejavax.faces.STATE_SAVING_METHOD/param-name--
 !--param-valueserver/param-value--
 !--/context-param--
 context-param
 param-namejavax.faces.DEFAULT_SUFFIX/param-name
 param-value.xhtml/param-value
 /context-param

 servlet-mapping
 servlet-nameFaces Servlet/servlet-name
 url-pattern*.do/url-pattern
 /servlet-mapping
 !-- Faces Servlet --
 servlet
 servlet-nameFaces Servlet/servlet-name
 servlet-classjavax.faces.webapp.FacesServlet/servlet-class
 /servlet
 session-config
 session-timeout10/session-timeout
 /session-config
 welcome-file-list
 welcome-fileindex.do/welcome-file
 !--welcome-fileindex.jsp/welcome-file--
 !--welcome-fileindex.xhtml/welcome-file--
 !--welcome-fileindex.html/welcome-file--
 /welcome-file-list
 context-param
 param-namejavax.faces.PROJECT_STAGE/param-name
 param-valueProduction/param-value
 /context-param
 context-param
 param-nameprimefaces.skin/param-name
 param-valuenone/param-value
 /context-param
 error-page

  exception-typejavax.faces.application.ViewExpiredException/exception-type
 location/sessionerror.xhtml/location
 /error-page

 !--context-param--
 !--param-namejavax.faces.FACELETS_SKIP_COMMENTS/param-name--
 !--param-valuetrue/param-value--
 !--/context-param--
 !--context-param--
 !--param-namecom.sun.faces.allowTextChildren/param-name--
 !--param-valuetrue/param-value--
 !--/context-param--
 !--servlet--
 !--servlet-nameResource Servlet/servlet-name--

  !--servlet-classorg.primefaces.resource.ResourceServlet/servlet-class--
 !--/servlet--
 !--servlet-mapping--
 !--servlet-nameResource Servlet/servlet-name--
 !--url-pattern/primefaces_resource/*/url-pattern--
 !--/servlet-mapping--
/web-app

2010/12/13 Werner Punzwerner.p...@gmail.com


Hi can you show me your web.xml,
I have done some extensive jsf testing on the weekend with gae and did not
have this error.


Werner

Am 13.12.10 18:45, schrieb Nikolay Rychkov:

  I have this error in every page on GAE:

What is it?



java.lang.IllegalStateException: STREAM
at org.mortbay.jetty.Response.getWriter(Response.java:616)
at

javax.servlet.ServletResponseWrapper.getWriter(ServletResponseWrapper.java:115)
at

org.apache.myfaces.context.servlet.ServletExternalContextImpl.getResponseOutputWriter(ServletExternalContextImpl.java:184)
at

org.apache.myfaces.shared_impl.view.JspViewDeclarationLanguageBase.renderView(JspViewDeclarationLanguageBase.java:154)
at

org.apache.myfaces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:263)
at

org.apache.myfaces.lifecycle.RenderResponseExecutor.execute(RenderResponseExecutor.java:85)
at
org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:239)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:191)
at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
at
org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:390)
at

org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
at

Re: IllegalStateException: No Factories configured for this Application on Weblogic 10

2010-12-13 Thread Werner Punz
Just a wild guessing here, maybe weblogic delivers its own jsf 
implementation from bottom up and it overrides myfaces in the 
classloader hierarchy.


Werner


Am 13.12.10 13:05, schrieb Marcio Carvalho:

Hi all,

I have a myfaces 1.2 web application which I'm trying to deploy on Weblogic
10.3.

Every time I try I got the error:

[HTTP:101216]Servlet: Faces Servlet failed to preload on startup in Web
application: mevi.war. java.lang.IllegalStateException: No Factories
configured for this Application. This happens if the faces-initialization
does not work at all - make sure that you properly include all configuration
settings necessary for a basic faces application and that all the necessary
libs are included. Also check the logging output of your web application and
your container for any exceptions! If you did that and find nothing, the
mistake might be due to the fact that you use some special web-containers
which do not support registering context-listeners via TLD files and a
context listener is not setup in your web.xml. A typical config looks like
this;listener
listener-classorg.apache.myfaces.webapp.StartupServletContextListener/listener-class
/listener  at javax.faces.FactoryFinder.getFactory(FactoryFinder.java:106)
at javax.faces.webapp.FacesServlet.init(FacesServlet.java:137) at
org.apache.myfaces.webapp.MyFacesServlet.init(MyFacesServlet.java:94) at
br.com.petrobras.fwjw.web.FrameworkFacesServlet.init(FrameworkFacesServlet.java:38)
at
weblogic.servlet.internal.StubSecurityHelper$ServletInitAction.run(StubSecurityHelper.java:283)
at
weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(Unknown Source) at
weblogic.servlet.internal.StubSecurityHelper.createServlet(StubSecurityHelper.java:64)
at
weblogic.servlet.internal.StubLifecycleHelper.createOneInstance(StubLifecycleHelper.java:58)
at
weblogic.servlet.internal.StubLifecycleHelper.init(StubLifecycleHelper.java:48)
at
weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:521)
at
weblogic.servlet.internal.WebAppServletContext.preloadServlet(WebAppServletContext.java:1893)
at
weblogic.servlet.internal.WebAppServletContext.loadServletsOnStartup(WebAppServletContext.java:1870)
at
weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:1790)
at
weblogic.servlet.internal.WebAppServletContext.start(WebAppServletContext.java:2999)
at
weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:1371)
at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:468) at
weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:204)
at
weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:37)
at
weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:60)
at
weblogic.application.internal.flow.ScopedModuleDriver.start(ScopedModuleDriver.java:200)
at
weblogic.application.internal.flow.ModuleListenerInvoker.start(ModuleListenerInvoker.java:117)
at
weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:204)
at
weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:37)
at
weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:60)
at
weblogic.application.internal.flow.StartModulesFlow.activate(StartModulesFlow.java:27)
at
weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:635)
at
weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:37)
at
weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:212)
at
weblogic.application.internal.SingleModuleDeployment.activate(SingleModuleDeployment.java:16)
at
weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:162)
at
weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:79)
at
weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:569)
at
weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:140)
at
weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:106)
at
weblogic.deploy.internal.targetserver.operations.StartOperation.doCommit(StartOperation.java:143)
at
weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:323)
at
weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:820)
at
weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1227)
at
weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:436)
at
weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:163)
at

Re: GAE problem

2010-12-13 Thread Werner Punz

Am 13.12.10 21:28, schrieb ken keller:

primefaces  richfaces teams seem to dismiss myfaces. Maybe the myfaces team
should get closer to these teams. Latest icefaces might not work w/ myfaces:
http://jira.icefaces.org/browse/ICE-5858



Actually the error on  the Icefaces side indicates they use some 
implementation specific classes from Mojarra.
Not sure why they are programming against the implementation at all, I 
assume it has to do with their delta ajaxing.
To my knowledge icefaces has done that in the past as well, and they 
were going to stop to program directly against the implementation.
Guess not yet. I contacted them also a while ago to contact me if they 
need something regarding myfaces and that I am eager to help out.

But I have yet to hear more from them.


Primefaces does not dismiss myfaces, I contacted Cagatay a while ago to 
ask whether he had problems and what he needs to have fixed, and he is 
testing against us. Have in mind Cagatay still is committer on MyFaces 
and member of the ASF so he is hardly dismissing us :-)


As for Richfaces I dont kow what they are up to, I got a couple of bugs 
a while ago from them which I fixed, since then I have not heard too 
much from them. I contacted once one of those guys regarding more 
feedback and he told me basically that they filed the bugs they found. 
Must have been the ones I fixed.





Werner



http://jira.icefaces.org/browse/ICE-5858Being a Java programmer isn't easy
:)

On Mon, Dec 13, 2010 at 12:23 PM, Werner Punzwerner.p...@gmail.com  wrote:


Ok outside of the crypto stuff I do not see any problem.
Try to remove the encryption alltogether for a quick testing and see if it
resolves your problem (also turn it off).
The problem also could be primefaces related.
With the exact crypto config i also had problems (I think the documentation
is not entirely correct on our page there, I noticed that after a while I
got viewexpiredexceptions with that one)

What myfaces version do you use. I did my testing on 2.0.2 but my testcase
was rather basic:

http://2.testinck4040.appspot.com/welcome.jsf


Werner



Am 13.12.10 20:28, schrieb Nikolay Rychkov:


?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;
 display-name
 Sight www.agost.ru
 /display-name
 description
 I really need www.agost.ru
 /description

 context-param


  
param-nameorg.apache.myfaces.config.annotation.LifecycleProvider/param-name


  
param-valueorg.apache.myfaces.config.annotation.NoInjectionAnnotationLifecycleProvider/param-value
 /context-param
!--
 Need to set a secret to avoid
javax.crypto.BadPaddingException.
 param-value must be Base64 encoded.
 More details:
http://wiki.apache.org/myfaces/Secure_Your_Application
  --
 context-param
 param-nameorg.apache.myfaces.SECRET/param-name
 param-valuex/param-value
 /context-param

 !-- * GAE 1.3.0 appears to handle server-side state saving. *
  --
 !--context-param--
 !--param-namejavax.faces.STATE_SAVING_METHOD/param-name--
 !--param-valueserver/param-value--
 !--/context-param--
 context-param
 param-namejavax.faces.DEFAULT_SUFFIX/param-name
 param-value.xhtml/param-value
 /context-param

 servlet-mapping
 servlet-nameFaces Servlet/servlet-name
 url-pattern*.do/url-pattern
 /servlet-mapping
 !-- Faces Servlet --
 servlet
 servlet-nameFaces Servlet/servlet-name
 servlet-classjavax.faces.webapp.FacesServlet/servlet-class
 /servlet
 session-config
 session-timeout10/session-timeout
 /session-config
 welcome-file-list
 welcome-fileindex.do/welcome-file
 !--welcome-fileindex.jsp/welcome-file--
 !--welcome-fileindex.xhtml/welcome-file--
 !--welcome-fileindex.html/welcome-file--
 /welcome-file-list
 context-param
 param-namejavax.faces.PROJECT_STAGE/param-name
 param-valueProduction/param-value
 /context-param
 context-param
 param-nameprimefaces.skin/param-name
 param-valuenone/param-value
 /context-param
 error-page


  exception-typejavax.faces.application.ViewExpiredException/exception-type
 location/sessionerror.xhtml/location
 /error-page

 !--context-param--
 !--param-namejavax.faces.FACELETS_SKIP_COMMENTS/param-name--
 !--param-valuetrue/param-value--
 !--/context-param--
 !--context-param--
 !--param-namecom.sun.faces.allowTextChildren/param-name--
 !--param-valuetrue/param-value--
 !--/context-param--
 !--servlet--
 !--servlet-nameResource Servlet/servlet-name--


  

Re: GAE problem

2010-12-13 Thread Werner Punz
Mhh can you make a small snapshot of the program, just one page and the 
configuration you use, so that I can look more deeply into the problem 
tomorrow?



Werner


Am 13.12.10 21:57, schrieb Nikolay Rychkov:

I removed
context-param
 param-nameorg.apache.myfaces.SECRET/param-name
 param-valuexxx/param-value
 /context-param

but problem still exists

I use MyFaces 2.0.2


2010/12/13 Werner Punzwerner.p...@gmail.com


Ok outside of the crypto stuff I do not see any problem.
Try to remove the encryption alltogether for a quick testing and see if it
resolves your problem (also turn it off).
The problem also could be primefaces related.
With the exact crypto config i also had problems (I think the documentation
is not entirely correct on our page there, I noticed that after a while I
got viewexpiredexceptions with that one)

What myfaces version do you use. I did my testing on 2.0.2 but my testcase
was rather basic:

http://2.testinck4040.appspot.com/welcome.jsf


Werner



Am 13.12.10 20:28, schrieb Nikolay Rychkov:

  ?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;
 display-name
 Sight www.agost.ru
 /display-name
 description
 I really need www.agost.ru
 /description

 context-param


  
param-nameorg.apache.myfaces.config.annotation.LifecycleProvider/param-name


  
param-valueorg.apache.myfaces.config.annotation.NoInjectionAnnotationLifecycleProvider/param-value
 /context-param
!--
 Need to set a secret to avoid
javax.crypto.BadPaddingException.
 param-value must be Base64 encoded.
 More details:
http://wiki.apache.org/myfaces/Secure_Your_Application
  --
 context-param
 param-nameorg.apache.myfaces.SECRET/param-name
 param-valuex/param-value
 /context-param

 !-- * GAE 1.3.0 appears to handle server-side state saving. *
  --
 !--context-param--
 !--param-namejavax.faces.STATE_SAVING_METHOD/param-name--
 !--param-valueserver/param-value--
 !--/context-param--
 context-param
 param-namejavax.faces.DEFAULT_SUFFIX/param-name
 param-value.xhtml/param-value
 /context-param

 servlet-mapping
 servlet-nameFaces Servlet/servlet-name
 url-pattern*.do/url-pattern
 /servlet-mapping
 !-- Faces Servlet --
 servlet
 servlet-nameFaces Servlet/servlet-name
 servlet-classjavax.faces.webapp.FacesServlet/servlet-class
 /servlet
 session-config
 session-timeout10/session-timeout
 /session-config
 welcome-file-list
 welcome-fileindex.do/welcome-file
 !--welcome-fileindex.jsp/welcome-file--
 !--welcome-fileindex.xhtml/welcome-file--
 !--welcome-fileindex.html/welcome-file--
 /welcome-file-list
 context-param
 param-namejavax.faces.PROJECT_STAGE/param-name
 param-valueProduction/param-value
 /context-param
 context-param
 param-nameprimefaces.skin/param-name
 param-valuenone/param-value
 /context-param
 error-page


  exception-typejavax.faces.application.ViewExpiredException/exception-type
 location/sessionerror.xhtml/location
 /error-page

 !--context-param--
 !--param-namejavax.faces.FACELETS_SKIP_COMMENTS/param-name--
 !--param-valuetrue/param-value--
 !--/context-param--
 !--context-param--
 !--param-namecom.sun.faces.allowTextChildren/param-name--
 !--param-valuetrue/param-value--
 !--/context-param--
 !--servlet--
 !--servlet-nameResource Servlet/servlet-name--


  !--servlet-classorg.primefaces.resource.ResourceServlet/servlet-class--
 !--/servlet--
 !--servlet-mapping--
 !--servlet-nameResource Servlet/servlet-name--
 !--url-pattern/primefaces_resource/*/url-pattern--
 !--/servlet-mapping--
/web-app

2010/12/13 Werner Punzwerner.p...@gmail.com

  Hi can you show me your web.xml,

I have done some extensive jsf testing on the weekend with gae and did
not
have this error.


Werner

Am 13.12.10 18:45, schrieb Nikolay Rychkov:

  I have this error in every page on GAE:


What is it?



java.lang.IllegalStateException: STREAM
at org.mortbay.jetty.Response.getWriter(Response.java:616)
at


javax.servlet.ServletResponseWrapper.getWriter(ServletResponseWrapper.java:115)
at


org.apache.myfaces.context.servlet.ServletExternalContextImpl.getResponseOutputWriter(ServletExternalContextImpl.java:184)
at


org.apache.myfaces.shared_impl.view.JspViewDeclarationLanguageBase.renderView(JspViewDeclarationLanguageBase.java:154)
at


org.apache.myfaces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:263)
at



Re: GAE problem

2010-12-13 Thread Werner Punz
Ok thanks a lot I will look into it tomorrow, just one last question, do 
you get the error only if you deploy or do you get it in the local 
testing scenario as well, and are your beans you reference normal 
managed beans?


Werner


Am 13.12.10 22:03, schrieb Nikolay Rychkov:

?xml version=1.0 encoding=UTF-8?
project xmlns=http://maven.apache.org/POM/4.0.0; xmlns:xsi=
http://www.w3.org/2001/XMLSchema-instance;
  xsi:schemaLocation=http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd;
 modelVersion4.0.0/modelVersion

 !-- The Basics --
 groupIdru.agost/groupId
 artifactIdagost/artifactId
 version1.0/version
 packagingwar/packaging

 nameAgost/name
 descriptionAgost description/description

 repositories
 repository
 idjava.net/id
 nameGlassFish Maven Repository/name
 urlhttp://download.java.net/maven/glassfish/url
 /repository
 repository
 idobjectify-appengine/id
 urlhttp://objectify-appengine.googlecode.com/svn/maven/url
 /repository
 repository
 idrepo1.maven.org/id
 nameJava.net Repository for Maven/name
 urlhttp://repo1.maven.org/maven2//url

 /repository
 repository
 idgoogle-maven-repo/id
 nameGoogle Maven Repository/name
 url
http://google-maven-repository.googlecode.com/svn/repository//url
 /repository
 repository
 idmaven-gae-plugin-repo1/id
 nameMaven Google App Engine Repository/name
 urlhttp://maven-gae-plugin.googlecode.com/svn/repository/
/url
 /repository

 repository
 idobjectweb/id
 nameObjectweb repository/name
 urlhttp://maven.objectweb.org/maven2/url
 /repository
 repository
 idjboss/id
 nameJBoss Maven2 repository/name
 urlhttp://repository.jboss.com/maven2//url
 snapshots
 enabledfalse/enabled
 /snapshots
 releases
 enabledtrue/enabled
 /releases
 /repository
 repository
 idglassfish/id
 nameGlassfish repository/name
 urlhttp://download.java.net/maven/1/url
 layoutlegacy/layout
 releases
 enabledtrue/enabled
 /releases
 snapshots
 enabledfalse/enabled
 /snapshots
 /repository
 repository
 idapache.snapshots/id
 nameApache Snapshot Repository/name
 url
 http://people.apache.org/repo/m2-snapshot-repository
 /url
 releases
 enabledfalse/enabled
 /releases
 snapshots
 enabledtrue/enabled
 /snapshots
 /repository
 repository
 idops4j.repository/id
 nameOPS4J Repository/name
 urlhttp://repository.ops4j.org/maven2/url
 releases
 enabledtrue/enabled
 /releases
 snapshots
 enabledfalse/enabled
 /snapshots
 /repository
 repository
 idCodehaus Snapshots/id
 urlhttp://snapshots.repository.codehaus.org//url
 snapshots
 enabledtrue/enabled
 /snapshots
 releases
 enabledfalse/enabled
 /releases
 /repository

 repository
 idprime-repo/id
 namePrime Technology Maven Repository/name
 urlhttp://repository.prime.com.tr/url
 layoutdefault/layout
 /repository
 repository
 idgoogle-maven-repo/id
 nameGoogle Maven Repository/name
 url
http://google-maven-repository.googlecode.com/svn/repository//url
 /repository
 !--repository--
 !--idmojarra-repo/id--
 !--nameMojarra Repository/name--
 !--urlhttp://download.java.net/maven/2//url--
 !--/repository--


 repository
 idfest/id
 urlhttp://repository.codehaus.org/org/easytesting//url
 /repository

 /repositories

 pluginRepositories
 pluginRepository
 idmaven-gae-plugin-repo/id
 nameMaven Google App Engine Repository/name
 urlhttp://maven-gae-plugin.googlecode.com/svn/repository/
/url
 /pluginRepository
 /pluginRepositories

 dependencies
 dependency
 groupIdjavax.persistence/groupId
 artifactIdpersistence-api/artifactId
 version1.0/version
 /dependency
 dependency
 groupIdcom.google.appengine/groupId
 artifactIdappengine-api-1.0-sdk/artifactId
 

Re: java.io.InvalidObjectException: enum constant attributes does not exist in class javax.faces.component.UIComponent$PropertyKeys

2010-12-12 Thread Werner Punz
Hi Ken die purpose of the encryption is a security problem, if you do 
not encrypt the viewstate on the client side then it is reverse 
engineerable from a third party.

We had to introduce that to fix that hole.
For server side state saving the encryption is not really needed unless 
you do not trust the third party you host the state with.



Werner


Am 11.12.10 00:31, schrieb ken keller:

I disabled encryption (see below), redeployed,  everything works--seemingly
it is much more responsive too.

What's the purpose of the encryption? When I View Source, ViewState field
looks like a long, hex string. Even if it can be reverse-engineered, the
values are likely to be the same ones sent in the http request. These are
vulnerable to MITM attack unless one uses https. Is JSF smart enough to
exclude a password field's value from ViewState?

context-param
 param-nameorg.apache.myfaces.USE_ENCRYPTION/param-name
 param-valuefalse/param-value
  /context-param

   context-param
 param-namejavax.faces.STATE_SAVING_METHOD/param-name
 param-valueclient/param-value
   /context-param

On Fri, Dec 10, 2010 at 2:40 PM, Leonardo Uribelu4...@gmail.com  wrote:


Hi

One last note, to make client side state saving work try configure this two
params:


org.apache.myfaces.SECRET

org.apache.myfaces.MAC_SECRET


It is probably that the ViewExpiredException is thrown because you are not
configured the mac secret.

See http://wiki.apache.org/myfaces/Secure_Your_Application  for details.

regards,

Leonardo Uribe

2010/12/10 Leonardo Uribelu4...@gmail.com


Hi

Is there any way to see the app log? In theory, when a

ViewExpiredException

is thrown, the reason is logged there, but there is not on the browser.


I readed your previous emails related to this one and one possibility

that

comes to my mind is we are storing something on session without implement
Serializable interface. If that so, as soon as GAE serialize the session

to

disk, that code causes an Exception and when MyFaces try to restore the
state it just has dissapeared (servlet session is invalid, so a new one

is

created and our value in javax.faces.ViewState request parameter is not
found, so a ViewExpiredException is thrown).

The solution if that is the case is check all lines that do something

with

session map and check if it is possible to serialize to disk.

regards,

Leonardo










Re: java.io.InvalidObjectException: enum constant attributes does not exist in class javax.faces.component.UIComponent$PropertyKeys

2010-12-12 Thread Werner Punz
Hi Leo I noticed I just set the org.apache.myfaces.SECRET not the 
MAC_SECRET, there seems to be an error in the GAE docs on our site, 
because it does not tell you have to set the MAC_SECRET.


I will give my testing case another try with MAC_SECRET set as well.

Werner


Am 10.12.10 23:40, schrieb Leonardo Uribe:

Hi

One last note, to make client side state saving work try configure this two
params:


org.apache.myfaces.SECRET

org.apache.myfaces.MAC_SECRET


It is probably that the ViewExpiredException is thrown because you are not
configured the mac secret.

See http://wiki.apache.org/myfaces/Secure_Your_Application  for details.

regards,

Leonardo Uribe

2010/12/10 Leonardo Uribelu4...@gmail.com


Hi

Is there any way to see the app log? In theory, when a ViewExpiredException
is thrown, the reason is logged there, but there is not on the browser.


I readed your previous emails related to this one and one possibility that
comes to my mind is we are storing something on session without implement
Serializable interface. If that so, as soon as GAE serialize the session to
disk, that code causes an Exception and when MyFaces try to restore the
state it just has dissapeared (servlet session is invalid, so a new one is
created and our value in javax.faces.ViewState request parameter is not
found, so a ViewExpiredException is thrown).

The solution if that is the case is check all lines that do something with
session map and check if it is possible to serialize to disk.

regards,

Leonardo








Re: java.io.InvalidObjectException: enum constant attributes does not exist in class javax.faces.component.UIComponent$PropertyKeys

2010-12-12 Thread Werner Punz
Btw. generally server side state saving is way faster than client side, 
although the difference has been somewhat reduced thanks to delta state 
saving. The reason simply is you transmit way less data over the line 
with the server side state saving on.


Werner


Am 12.12.10 11:38, schrieb Werner Punz:

Hi Ken die purpose of the encryption is a security problem, if you do
not encrypt the viewstate on the client side then it is reverse
engineerable from a third party.
We had to introduce that to fix that hole.
For server side state saving the encryption is not really needed unless
you do not trust the third party you host the state with.


Werner


Am 11.12.10 00:31, schrieb ken keller:

I disabled encryption (see below), redeployed, everything
works--seemingly
it is much more responsive too.

What's the purpose of the encryption? When I View Source, ViewState field
looks like a long, hex string. Even if it can be reverse-engineered, the
values are likely to be the same ones sent in the http request. These are
vulnerable to MITM attack unless one uses https. Is JSF smart enough to
exclude a password field's value from ViewState?

context-param
param-nameorg.apache.myfaces.USE_ENCRYPTION/param-name
param-valuefalse/param-value
/context-param

context-param
param-namejavax.faces.STATE_SAVING_METHOD/param-name
param-valueclient/param-value
/context-param

On Fri, Dec 10, 2010 at 2:40 PM, Leonardo Uribelu4...@gmail.com wrote:


Hi

One last note, to make client side state saving work try configure
this two
params:


org.apache.myfaces.SECRET

org.apache.myfaces.MAC_SECRET


It is probably that the ViewExpiredException is thrown because you
are not
configured the mac secret.

See http://wiki.apache.org/myfaces/Secure_Your_Application for details.

regards,

Leonardo Uribe

2010/12/10 Leonardo Uribelu4...@gmail.com


Hi

Is there any way to see the app log? In theory, when a

ViewExpiredException

is thrown, the reason is logged there, but there is not on the browser.


I readed your previous emails related to this one and one possibility

that

comes to my mind is we are storing something on session without
implement
Serializable interface. If that so, as soon as GAE serialize the
session

to

disk, that code causes an Exception and when MyFaces try to restore the
state it just has dissapeared (servlet session is invalid, so a new one

is

created and our value in javax.faces.ViewState request parameter is not
found, so a ViewExpiredException is thrown).

The solution if that is the case is check all lines that do something

with

session map and check if it is possible to serialize to disk.

regards,

Leonardo














Re: java.io.InvalidObjectException: enum constant attributes does not exist in class javax.faces.component.UIComponent$PropertyKeys

2010-12-12 Thread Werner Punz
Ok I now removed the encryption entirely, server side state saving also 
works like a charm now. I guess if you dont run into the limits of 
server side state saving, and googles session limit, which you should 
not if you keep the number of things in the session low and also the 
depth of the state history then this might be a viable option.
So google was not at fault here, it was my local settings, which just 
set the secret not the MAC_SECRET.

But why encryption for server side state saving at all?


Werner


Am 12.12.10 11:40, schrieb Werner Punz:

Hi Leo I noticed I just set the org.apache.myfaces.SECRET not the
MAC_SECRET, there seems to be an error in the GAE docs on our site,
because it does not tell you have to set the MAC_SECRET.

I will give my testing case another try with MAC_SECRET set as well.

Werner


Am 10.12.10 23:40, schrieb Leonardo Uribe:

Hi

One last note, to make client side state saving work try configure
this two
params:


org.apache.myfaces.SECRET

org.apache.myfaces.MAC_SECRET


It is probably that the ViewExpiredException is thrown because you are
not
configured the mac secret.

See http://wiki.apache.org/myfaces/Secure_Your_Application for details.

regards,

Leonardo Uribe

2010/12/10 Leonardo Uribelu4...@gmail.com


Hi

Is there any way to see the app log? In theory, when a
ViewExpiredException
is thrown, the reason is logged there, but there is not on the browser.


I readed your previous emails related to this one and one possibility
that
comes to my mind is we are storing something on session without
implement
Serializable interface. If that so, as soon as GAE serialize the
session to
disk, that code causes an Exception and when MyFaces try to restore the
state it just has dissapeared (servlet session is invalid, so a new
one is
created and our value in javax.faces.ViewState request parameter is not
found, so a ViewExpiredException is thrown).

The solution if that is the case is check all lines that do something
with
session map and check if it is possible to serialize to disk.

regards,

Leonardo












  1   2   3   4   5   6   7   8   9   10   >