Bonjour,
Comment intégrer RicheFaces dans un projet JSF.
Bonjour,
Comment intégrer RicheFaces dans un projet JSF.
Merci pour ta réponse, j'ai une application qui tourne sur un serveur Tomcat v6 et pas JBOSS, et apparemment c'est pas le même paramétrage pour les deux serveur d'application.
Si tu pars de zéro tu peux passer par leur archetype : http://docs.jboss.org/richfaces/late...ject_archetype
Si tu ne pars pas de zéro tu peux tout de même t'en inspirer pour configurer ton pom.xml (si tu utilises Maven).
Quant au serveur d'applications, nous utilisons Tomcat pour faire tourner des projets JSF + RichFaces sans soucis, avec la procédure de la documentation.
le problème c'est que ça fait 2 jours que j'ai utilisé la procédure d'intégration de RF dans JSF:
jars dans lib:
web.xml
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11 commons-beanutils-1.8.3.jar commons-codec-1.4.jar commons-collections-3.2.1.jar commons-digester-2.1.jar commons-discovery-0.4.jar commons-logging-1.1.1.jar richfaces-ui-3.2.0.GA.jar richfaces-impl-3.2.0.GA.jar richfaces-api-3.2.0.GA.jar jsf-facelets-1.1.13.jar myfaces-api-2.0.4.jar myfaces-impl-2.0.4.jar
et toujours l'erreur
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81 <?xml version="1.0" encoding="UTF-8"?> <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="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/web-app_2_5.xsd" id="WebApp_ID" version="2.5"> <display-name>JSFFaceletsTutorial</display-name> <welcome-file-list> <welcome-file>index.html</welcome-file> <welcome-file>index.htm</welcome-file> <welcome-file>index.jsp</welcome-file> <welcome-file>default.html</welcome-file> <welcome-file>default.htm</welcome-file> <welcome-file>default.jsp</welcome-file> </welcome-file-list> <servlet> <servlet-name>Faces Servlet</servlet-name> <servlet-class>javax.faces.webapp.FacesServlet</servlet-class> <load-on-startup>1</load-on-startup> </servlet> <servlet-mapping> <?xml version="1.0" encoding="UTF-8"?> <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="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/web-app_2_5.xsd" id="WebApp_ID" version="2.5"> <display-name>JSFFaceletsTutorial</display-name> <welcome-file-list> <welcome-file>index.html</welcome-file> <welcome-file>index.htm</welcome-file> <welcome-file>index.jsp</welcome-file> <welcome-file>default.html</welcome-file> <welcome-file>default.htm</welcome-file> <welcome-file>default.jsp</welcome-file> </welcome-file-list> <servlet> <servlet-name>Faces Servlet</servlet-name> <servlet-class>javax.faces.webapp.FacesServlet</servlet-class> <load-on-startup>1</load-on-startup> </servlet> <servlet-mapping> <servlet-name>Faces Servlet</servlet-name> <url-pattern>/faces/*</url-pattern> </servlet-mapping> <context-param> <description>State saving method: 'client' or 'server' (=default). See JSF Specification 2.5.2</description> <param-name>javax.faces.STATE_SAVING_METHOD</param-name> <param-value>client</param-value> </context-param> <context-param> <param-name>javax.servlet.jsp.jstl.fmt.localizationContext</param-name> <param-value>resources.application</param-value> </context-param> <!-- RICHEFACES --> <context-param> <param-name>org.richfaces.CONTROL_SKINNING</param-name> <param-value>enable</param-value> </context-param> <context-param> <param-name>org.ajax4jsf.VIEW_HANDLERS</param-name> <param-value>com.sun.facelets.FaceletViewHandler</param-value> </context-param> <context-param> <param-name>org.richfaces.CONTROL_SKINNING_CLASSES</param-name> <param-value>disable</param-value> </context-param> <!-- Defining and mapping the RichFaces filter --> <filter> <display-name>RichFaces Filter</display-name> <filter-name>richfaces</filter-name> <filter-class>org.ajax4jsf.Filter</filter-class> </filter> <filter-mapping> <filter-name>richfaces</filter-name> <servlet-name>Faces Servlet</servlet-name> <dispatcher>REQUEST</dispatcher> <dispatcher>FORWARD</dispatcher> <dispatcher>INCLUDE</dispatcher> </filter-mapping> <listener> <listener-class>com.sun.faces.config.ConfigureListener</listener-class> </listener> </web-app>je vois vraiment pas pourquoi ça marche pas
Code : Sélectionner tout - Visualiser dans une fenêtre à part Etat HTTP 404 -
Est ce que tu pars de zéro ? Si oui, je te conseille vraiment d'utiliser l'archetype maven proposé par richfaces (à moins que ce soit déjà ce que tu fasses ?). Ca te générera un projet bien configuré à adapter selon tes besoins.
Si non, est ce que tu peux nous montrer l'avant / après intégration de RF ? Pour ma part j'ai juste :
* jsf-api
* jsf-facelets
* jsf-impl
* richfaces-ui
* richfaces-impl
* richfaces-api
Sinon je t'invite à générer la configuration depuis l'archetype maven sur un projet vierge et à regarder la configuration générée pour faire le delta avec la tienne.
Partager