-
15. Re: richfaces-3.2 - fileUpload
ilya_shaikovsky Apr 2, 2008 3:39 AM (in response to kaobiore)will examined by Andrei and answered soon.
-
16. Re: richfaces-3.2 - fileUpload
akakunin Apr 2, 2008 6:28 AM (in response to kaobiore)Try upload small files. Seems by default fileUpload do not allowed to upload more then 100k files - in my cases upload event also was not fired.
-
17. Re: richfaces-3.2 - fileUpload
kaobiore Apr 2, 2008 6:48 AM (in response to kaobiore)> Try upload small files. Seems by default fileUpload do not allowed to upload
> more then 100k files
No, it makes no difference uploading small-sized files ... listener-method is not fired!
And ... If I'm not completely wrong the max. upload-file-size can be configured in the web.xml by adding "init-params" to the Ajax4jsfFilter.
Example:<filter> <display-name>Ajax4jsfFilter</display-name> <filter-name>ajax4jsf</filter-name> <filter-class>org.ajax4jsf.Filter</filter-class> <init-param> <param-name>createTempFiles</param-name> <param-value>true</param-value> </init-param> <init-param> <param-name>maxRequestSize</param-name> <param-value>20000000</param-value> </init-param> </filter> <filter-mapping> <filter-name>ajax4jsf</filter-name> <servlet-name>FacesServlet</servlet-name> <dispatcher>REQUEST</dispatcher> <dispatcher>FORWARD</dispatcher> <dispatcher>INCLUDE</dispatcher> </filter-mapping>
-
18. Re: richfaces-3.2 - fileUpload
andrei_exadel Apr 2, 2008 7:39 AM (in response to kaobiore)"kaobiore" wrote:
Hi!
I've sent an email (to andrei and ilya) including a http-link to download a war-file for reproducing this mentioned behavior.
Hope this helps.
Cheers
-=k=-
Hi, I looked into your code. Really, listener does not fire.
This happens in case of myfaces usage with RF. Currently fileupload component can not work with myfaces properlly.
I created the issue: http://jira.jboss.com/jira/browse/RF-2935.
For quick fix I can suggest to switch off ExtensionFilter in your web.xml. I should help to fire listeners.
Thanks you for posting your code to us. -
19. Re: richfaces-3.2 - fileUpload
kaobiore Apr 2, 2008 10:17 AM (in response to kaobiore)Hi!
Thank you for your quick response!
You are absolutely right - removing tomahawk from web.xml helps.
I hope this bug will be fixed quite soon (next release?) otherwise I have to rewrite big parts of my project (removing/replacing all tomahawk-tags).
Thank you again.
Cheers
Harald -
20. Re: richfaces-3.2 - fileUpload
andrei_exadel Apr 2, 2008 10:31 AM (in response to kaobiore)I've already fixed this one.
Additionally: you may not to delete tomahawk tags. You can just adjust mapping for Extension filter to avoid invoking it for pages containg RF file upload component.
To avoid generation of errors from myfaces in case of invalid filter configuration you can set up the following context param in web.xml:
<context-param>
Check if the extensions-filter has been properly configured.
<param-name>
org.apache.myfaces.CHECK_EXTENSIONS_FILTER
</param-name>
<param-value>true</param-value>
</context-param> -
21. Re: richfaces-3.2 - fileUpload
andrei_exadel Apr 2, 2008 10:33 AM (in response to kaobiore)Remark:
<context-param>
Check if the extensions-filter has been properly configured.
<param-name>
org.apache.myfaces.CHECK_EXTENSIONS_FILTER
</param-name>
<param-value>false</param-value>
</context-param>
: ) -
22. Re: richfaces-3.2 - fileUpload
rulinsun Apr 2, 2008 4:23 PM (in response to kaobiore)My application doesn't have anything related to myfaces. It's pure RichFaces + Facelets. But the fileUpload listener does not fire.
-
23. Re: richfaces-3.2 - fileUpload
ilya_shaikovsky Apr 3, 2008 3:50 AM (in response to kaobiore)rulinsun, you sure you update RF from CR to GA?
-
24. Re: richfaces-3.2 - fileUpload
rulinsun Apr 3, 2008 9:43 AM (in response to kaobiore)If you want, I can send you whole war file. I created a RichFaces test project to test simple things.
Those are jar files I have:
and Web.xml
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns="http://java.sun.com/xml/ns/j2ee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="2.4"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
<display-name>RichFaces_Test</display-name>
<context-param>
<param-name>javax.faces.CONFIG_FILES</param-name>
<param-value>/WEB-INF/faces-config.xml</param-value>
</context-param>
<context-param>
<param-name>javax.faces.STATE_SAVING_METHOD</param-name>
<param-value>server</param-value>
</context-param>
<context-param>
<param-name>javax.faces.DEFAULT_SUFFIX</param-name>
<param-value>.xhtml</param-value>
</context-param>
<context-param>
<param-name>facelets.REFRESH_PERIOD</param-name>
<param-value>2</param-value>
</context-param>
<context-param>
<param-name>facelets.DEVELOPMENT</param-name>
<param-value>true</param-value>
</context-param>
<context-param>
<param-name>org.ajax4jsf.VIEW_HANDLERS</param-name>
<param-value>com.sun.facelets.FaceletViewHandler</param-value>
</context-param>
<display-name>RichFaces Filter</display-name>
<filter-name>richfaces</filter-name>
<filter-class>org.ajax4jsf.Filter</filter-class>
<init-param>
<param-name>createTempFiles</param-name>
<param-value>true</param-value>
</init-param>
<init-param>
<param-name>maxRequestSize</param-name>
<param-value>20000000</param-value>
</init-param>
<filter-mapping>
<filter-name>richfaces</filter-name>
<servlet-name>Faces Servlet</servlet-name>
REQUEST
FORWARD
INCLUDE
ERROR
</filter-mapping>
<listener-class>com.sun.faces.config.ConfigureListener</listener-class>
<servlet-name>Faces Servlet</servlet-name>
<servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
<load-on-startup>1</load-on-startup>
<servlet-mapping>
<servlet-name>Faces Servlet</servlet-name>
<url-pattern>/faces/*</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>Faces Servlet</servlet-name>
<url-pattern>*.jsf</url-pattern>
</servlet-mapping>
<welcome-file-list>
<welcome-file>index.jsp</welcome-file>
</welcome-file-list>
</web-app>
Then the FileUploadBean.java and fileuploadtest.xml are exactly copied from early on this board. My tomcat is 5.5, I used myEclapse to run server in the debug model. The break point in the very first line in the listener method was't hit.
Thanks!
Rulin -
25. Re: richfaces-3.2 - fileUpload
rulinsun Apr 3, 2008 9:48 AM (in response to kaobiore)The jar files were missing in previous post:
WebRoot/WEB-INF/lib/jsf-facelets.jar
WebRoot/WEB-INF/lib/log4j-1.2.15.jar
WebRoot/WEB-INF/lib/jsf-api.jar
WebRoot/WEB-INF/lib/jsf-impl.jar
WebRoot/WEB-INF/lib/jstl-1.2.jar
WebRoot/WEB-INF/lib/el-api.jar
WebRoot/WEB-INF/lib/el-ri.jar
WebRoot/WEB-INF/lib/commons-collections-3.2.jar
WebRoot/WEB-INF/lib/commons-digester-1.8.jar
WebRoot/WEB-INF/lib/commons-beanutils-1.7.0.jar
WebRoot/WEB-INF/lib/richfaces-api-3.2.0.GA.jar
WebRoot/WEB-INF/lib/richfaces-impl-3.2.0.GA.jar
WebRoot/WEB-INF/lib/richfaces-ui-3.2.0.GA.jar
WebRoot/WEB-INF/lib/commons-logging-1.1.jar -
26. Re: richfaces-3.2 - fileUpload
andrei_exadel Apr 3, 2008 9:56 AM (in response to kaobiore)Yes. Please send to us your war file. It will help to find the problem.
Thanks. -
27. Re: richfaces-3.2 - fileUpload
ilya_shaikovsky Apr 3, 2008 10:00 AM (in response to kaobiore)please create a issue in our jira and attach your war file.
-
28. Re: richfaces-3.2 - fileUpload
rulinsun Apr 3, 2008 10:28 AM (in response to kaobiore)Done: RF-2958
Thanks!
Rulin -
29. Re: richfaces-3.2 - fileUpload
andrei_exadel Apr 3, 2008 10:38 AM (in response to kaobiore)Thank you. But it will be carefull to get your application with source code.