IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)
Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

JSF Java Discussion :

Problème dans le démarrage de la page


Sujet :

JSF Java

  1. #1
    Membre très actif
    Homme Profil pro
    Inscrit en
    Février 2010
    Messages
    118
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations forums :
    Inscription : Février 2010
    Messages : 118
    Par défaut Problème dans le démarrage de la page
    j'ai un warning dans le facesconfig

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
     
    <application>
      <el-resolver>org.springframework.web.jsf.el.SpringBeanFacesELResolver</el-resolver>
     </application>
    warning
    Class org.springframework.web.jsf.el.SpringBeanFacesELResolver must extend the type javax.el.ELResolver
    je pense que ça me provace un probleme de lancement da la page

    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
     
    3 juin 2011 22:05:05 org.apache.catalina.core.AprLifecycleListener init
    INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: C:\Program Files\Java\jdk1.6.0_25\bin;.;C:\WINDOWS\Sun\Java\bin;C:\WINDOWS\system32;C:\WINDOWS;C:/Program Files/Java/jre6/bin/client;C:/Program Files/Java/jre6/bin;C:/Program Files/Java/jre6/lib/i386;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;$PATH:\C:\Program Files\developpement\tomcat\bin;;C:\PROGRA~1\FICHIE~1\MUVEET~1\030625
    3 juin 2011 22:05:05 org.apache.tomcat.util.digester.SetPropertiesRule begin
    ATTENTION: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:RservationVol' did not find a matching property.
    3 juin 2011 22:05:05 org.apache.coyote.AbstractProtocolHandler init
    INFO: Initializing ProtocolHandler ["http-bio-8080"]
    3 juin 2011 22:05:05 org.apache.coyote.AbstractProtocolHandler init
    INFO: Initializing ProtocolHandler ["ajp-bio-8009"]
    3 juin 2011 22:05:05 org.apache.catalina.startup.Catalina load
    INFO: Initialization processed in 1333 ms
    3 juin 2011 22:05:05 org.apache.catalina.core.StandardService startInternal
    INFO: Démarrage du service Catalina
    3 juin 2011 22:05:05 org.apache.catalina.core.StandardEngine startInternal
    INFO: Starting Servlet Engine: Apache Tomcat/7.0.14
    3 juin 2011 22:05:10 org.apache.catalina.startup.TaglibUriRule body
    INFO: TLD skipped. URI: 
            http://java.sun.com/jsf/html
         is already defined
    3 juin 2011 22:05:10 org.apache.catalina.startup.TaglibUriRule body
    INFO: TLD skipped. URI: http://java.sun.com/jsf/core is already defined
    3 juin 2011 22:05:11 org.apache.catalina.core.StandardContext addApplicationListener
    INFO: The listener "com.sun.faces.config.ConfigureListener" is already configured for this context. The duplicate definition has been ignored.
    3 juin 2011 22:05:11 com.sun.faces.config.ConfigureListener contextInitialized
    INFO: Initializing Sun's JavaServer Faces implementation (1.2_04-b16-p02) for context '/RservationVol'
    3 juin 2011 22:05:11 com.sun.faces.spi.InjectionProviderFactory createInstance
    INFO: JSF1048: PostConstruct/PreDestroy annotations present.  ManagedBeans methods marked with these annotations will have said annotations processed.
    3 juin 2011 22:05:12 org.apache.catalina.core.ApplicationContext log
    INFO: Initializing Spring root WebApplicationContext
    log4j:WARN No appenders could be found for logger (org.springframework.web.context.ContextLoader).
    log4j:WARN Please initialize the log4j system properly.
    3 juin 2011 22:05:13 org.apache.catalina.core.StandardContext listenerStart
    GRAVE: Exception lors de l'envoi de l'évènement contexte initialisé (context initialized) à l'instance de classe d'écoute (listener) org.springframework.web.context.ContextLoaderListener
    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'reservationVolSessionFactory' defined in class path resource [dz/airtravel/ressources/applicationContext.xml]: Invocation of init method failed; nested exception is java.io.FileNotFoundException: class path resource [dz/airtravel/ressources/hibernate.cfg.xml] cannot be resolved to URL because it does not exist
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1362)
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:540)
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory$1.run(AbstractAutowireCapableBeanFactory.java:485)
    	at java.security.AccessController.doPrivileged(Native Method)
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:455)
    	at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:251)
    	at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:169)
    	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:248)
    	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:170)
    	at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:407)
    	at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:735)
    	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:369)
    	at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:251)
    	at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:190)
    	at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:45)
    	at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4723)
    	at org.apache.catalina.core.StandardContext$1.call(StandardContext.java:5226)
    	at org.apache.catalina.core.StandardContext$1.call(StandardContext.java:5221)
    	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
    	at java.util.concurrent.FutureTask.run(FutureTask.java:138)
    	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
    	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
    	at java.lang.Thread.run(Thread.java:662)
    Caused by: java.io.FileNotFoundException: class path resource [dz/airtravel/ressources/hibernate.cfg.xml] cannot be resolved to URL because it does not exist
    	at org.springframework.core.io.ClassPathResource.getURL(ClassPathResource.java:162)
    	at org.springframework.orm.hibernate3.LocalSessionFactoryBean.buildSessionFactory(LocalSessionFactoryBean.java:572)
    	at org.springframework.orm.hibernate3.AbstractSessionFactoryBean.afterPropertiesSet(AbstractSessionFactoryBean.java:211)
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1390)
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1359)
    	... 22 more
    3 juin 2011 22:05:13 org.apache.catalina.core.StandardContext startInternal
    GRAVE: Error listenerStart
    3 juin 2011 22:05:13 org.apache.catalina.core.StandardContext startInternal
    GRAVE: Erreur de démarrage du contexte [/RservationVol] suite aux erreurs précédentes
    3 juin 2011 22:05:13 org.apache.catalina.core.ApplicationContext log
    INFO: Closing Spring root WebApplicationContext
    3 juin 2011 22:05:13 org.apache.coyote.AbstractProtocolHandler start
    INFO: Starting ProtocolHandler ["http-bio-8080"]
    3 juin 2011 22:05:13 org.apache.coyote.AbstractProtocolHandler start
    INFO: Starting ProtocolHandler ["ajp-bio-8009"]
    3 juin 2011 22:05:13 org.apache.catalina.startup.Catalina start
    INFO: Server startup in 7686 ms
    suite de ces erreurs la page ne s'affiche pas


    Etat HTTP 404 - /RservationVol/pages/acceuil.jsp

    --------------------------------------------------------------------------------

    type Rapport d''état

    message /RservationVol/pages/acceuil.jsp

    description La ressource demandée (/RservationVol/pages/acceuil.jsp) n'est pas disponible.

  2. #2
    Membre averti
    Inscrit en
    Octobre 2002
    Messages
    43
    Détails du profil
    Informations forums :
    Inscription : Octobre 2002
    Messages : 43
    Par défaut
    Dans la partie java, essaye de faire ceci
    Class org.springframework.web.jsf.el.SpringBeanFacesELResolver must extend the type javax.el.ELResolver

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    public class SpringBeanFacesELResolver extends ELResolver {
    histoire de voir ce que cela donne.

  3. #3
    Membre Expert
    Homme Profil pro
    Ingénieur développement logiciels
    Inscrit en
    Juin 2007
    Messages
    2 938
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations professionnelles :
    Activité : Ingénieur développement logiciels

    Informations forums :
    Inscription : Juin 2007
    Messages : 2 938
    Par défaut
    Citation Envoyé par magellan Voir le message
    Dans la partie java, essaye de faire ceci
    Class org.springframework.web.jsf.el.SpringBeanFacesELResolver must extend the type javax.el.ELResolver

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    public class SpringBeanFacesELResolver extends ELResolver {
    histoire de voir ce que cela donne.
    Tu sais de quoi tu parles dans ta réponse ? C'est une librairie embarquée dont on parle là. c'est un souci de conf, c'est une erreur classique. En général essayez de googeliser l'erreur avant de poster, c'est pas un reproche mais ca peut vous faire gagner en temps. Suis la conf de ce tuto

  4. #4
    Rédacteur
    Avatar de romaintaz
    Homme Profil pro
    Java craftsman
    Inscrit en
    Juillet 2005
    Messages
    3 790
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Âge : 46
    Localisation : France, Yvelines (Île de France)

    Informations professionnelles :
    Activité : Java craftsman
    Secteur : Finance

    Informations forums :
    Inscription : Juillet 2005
    Messages : 3 790
    Par défaut
    C'est étrange. A quel endroit se situe ce warning ?

    La classe SpringBeanFacesELResolver étend pourtant bien ELResolver...

    Dans tes logs, il indique qu'il n'arrive pas à créer un bean (reservationVolSessionFactory) parce qu'il cherche un fichier (dz/airtravel/ressources/hibernate.cfg.xml) dans le classpath.

    Est-ce que ce fichier est bien dans le classpath ?
    Nous sommes tous semblables, alors acceptons nos différences !
    --------------------------------------------------------------
    Liens : Blog | Page DVP | Twitter
    Articles : Hudson | Sonar | Outils de builds Java Maven 3 | Play! 1 | TeamCity| CitConf 2009
    Critiques : Apache Maven

  5. #5
    Membre très actif
    Homme Profil pro
    Inscrit en
    Février 2010
    Messages
    118
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France

    Informations forums :
    Inscription : Février 2010
    Messages : 118
    Par défaut
    Citation Envoyé par romaintaz Voir le message
    C'est étrange. A quel endroit se situe ce warning ?

    La classe SpringBeanFacesELResolver étend pourtant bien ELResolver...

    Dans tes logs, il indique qu'il n'arrive pas à créer un bean (reservationVolSessionFactory) parce qu'il cherche un fichier (dz/airtravel/ressources/hibernate.cfg.xml) dans le classpath.

    Est-ce que ce fichier est bien dans le classpath ?
    dans le applicationContext.xml je fais ça
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
     
    <bean id="ReservationVolSessionFactory" class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
    		<property name="configLocation" value="classpath:/dz/airtravel/ressources/hibernate.cfg.xml"></property>
    	    <property name="configurationClass">
    	    <value>org.hibernate.cfg.AnnotationConfiguration</value> </property>
    	</bean>
    et mon fichier hibernate.cfg.xml se trouve dans le package dz/airtravel/ressources/ dans src

  6. #6
    Membre confirmé
    Inscrit en
    Décembre 2009
    Messages
    68
    Détails du profil
    Informations forums :
    Inscription : Décembre 2009
    Messages : 68
    Par défaut
    Citation Envoyé par intelo Voir le message
    dans le applicationContext.xml je fais ça
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
     
    <bean id="ReservationVolSessionFactory" class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
    		<property name="configLocation" value="classpath:/dz/airtravel/ressources/hibernate.cfg.xml"></property>
    	    <property name="configurationClass">
    	    <value>org.hibernate.cfg.AnnotationConfiguration</value> </property>
    	</bean>
    et mon fichier hibernate.cfg.xml se trouve dans le package dz/airtravel/ressources/ dans src
    Essaye de mettre la config hibernate directement dans applicationContext.xml et supprime ton fichier hibernate

Discussions similaires

  1. Problème dans le démarrage de Tomcat
    Par Eric_beauvais dans le forum Tomcat et TomEE
    Réponses: 4
    Dernier message: 16/10/2013, 08h40
  2. problème dans l'affichage de la page JSP
    Par dearraed dans le forum Tomcat et TomEE
    Réponses: 1
    Dernier message: 27/01/2010, 14h44
  3. Réponses: 2
    Dernier message: 11/09/2007, 11h22
  4. Réponses: 8
    Dernier message: 04/07/2007, 12h51
  5. [HVMenu] problème dans les pages ASPX (urgent svp)
    Par hatembr dans le forum Général JavaScript
    Réponses: 4
    Dernier message: 13/01/2005, 09h37

Partager

Partager
  • Envoyer la discussion sur Viadeo
  • Envoyer la discussion sur Twitter
  • Envoyer la discussion sur Google
  • Envoyer la discussion sur Facebook
  • Envoyer la discussion sur Digg
  • Envoyer la discussion sur Delicious
  • Envoyer la discussion sur MySpace
  • Envoyer la discussion sur Yahoo