Publicité
+ Répondre à la discussion
Affichage des résultats 1 à 2 sur 2
  1. #1
    Invité de passage
    Homme Profil pro ssef youssef
    Développeur informatique
    Inscrit en
    mai 2012
    Messages
    1
    Détails du profil
    Informations personnelles :
    Nom : Homme ssef youssef
    Localisation : Maroc

    Informations professionnelles :
    Activité : Développeur informatique

    Informations forums :
    Inscription : mai 2012
    Messages : 1
    Points : 0
    Points
    0

    Par défaut Spring GWT Hibernate Validation Exception

    Bonjour Bonsoir ,
    j'essaye de creer une application en utilisant les technologies suivantes (Gwt2 + Spring3 + hibernate3 + jpa2) j'ai suivi ce tutoriel http://www.javacodegeeks.com/2010/05...ernate-35.html mais je croi que j'ai fait une betise quelque part

    la structure du projet :


    le fichier web.xml :
    Code :
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    <context-param>
    		<param-name>contextConfigLocation</param-name>
    		<param-value>WEB-INF/*Context.xml</param-value>
    	</context-param>
     
    	<listener>
    		<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
    	</listener>
     
    	<servlet>
    		<servlet-name>springGwtRemoteServiceServlet</servlet-name>
    		<servlet-class>org.spring4gwt.server.SpringGwtRemoteServiceServlet</servlet-class>
    	</servlet>
     
    	<servlet-mapping>
    		<servlet-name>springGwtRemoteServiceServlet</servlet-name>
    		<url-pattern>/gwtspringhiberjpa/springGwtServices/*</url-pattern>
    	</servlet-mapping>
     
    	<welcome-file-list>
    		<welcome-file>GwtSpringHiberJpa.html</welcome-file>
    	</welcome-file-list>
    le fichier applicationContext.xml :
    Code :
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    <context:component-scan base-package="you.ssef" />
    <tx:annotation-driven/>
     
    <bean class="org.springframework.orm.jpa.LocalEntityManagerFactoryBean" id="entityManagerFactory">
            <property name="persistenceUnitName" value="MyPersistenceUnit"/>
        </bean>
     
        <bean class="org.springframework.orm.jpa.JpaTransactionManager" id="transactionManager">
            <property name="entityManagerFactory" ref="entityManagerFactory"/>
        </bean>

    le fichier persistence.xml :
    Code :
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    <persistence-unit name="MyPersistenceUnit" transaction-type="RESOURCE_LOCAL">
        <provider>org.hibernate.ejb.HibernatePersistence</provider>
        <properties>
          <property name="hibernate.dialect" value="org.hibernate.dialect.MySQLInnoDBDialect"/>
          <property name="hibernate.connection.driver_class" value="com.mysql.jdbc.Driver"/>
          <property name="hibernate.show_sql" value="true"/>
          <property name="hibernate.connection.username" value="root"/>
          <property name="hibernate.connection.password" value="root"/>
          <property name="hibernate.connection.url" value="jdbc:mysql://localhost:3306/stagiaire"/>
        </properties>
      </persistence-unit>
    l' Exception :
    Code :
    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
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    98
    99
    100
    101
    102
    103
    104
    105
    106
    107
    108
    109
    110
    111
    112
    113
    114
    115
    116
    117
    118
    119
    120
    121
    122
    123
    124
    125
    126
    127
    128
    129
    130
    131
    132
    133
    log4j:WARN No appenders could be found for logger (org.springframework.web.context.ContextLoader).
    log4j:WARN Please initialize the log4j system properly.
    log4j:WARN See <a href="http://logging.apache.org/log4j/1.2/faq.html#noconfig" target="_blank">http://logging.apache.org/log4j/1.2/faq.html#noconfig</a> for more info.
    [WARN] Server class 'javax.validation.Validation' could not be found in the web app, but was found on the system classpath
       [WARN] Adding classpath entry 'file:/F:/Logiciel/eclipse-jee-indigo-win32-x86_64/eclipse/plugins/com.google.gwt.eclipse.sdkbundle_2.4.0.v201205091048-rel-r37/gwt-2.4.0/validation-api-1.0.0.GA.jar' to the web app classpath for this session
       For additional info see: file:/F:/Logiciel/eclipse-jee-indigo-win32-x86_64/eclipse/plugins/com.google.gwt.eclipse.sdkbundle_2.4.0.v201205091048-rel-r37/gwt-2.4.0/doc/helpInfo/webAppClassPath.html
    Starting Jetty on port 8888
       [WARN] Failed startup of context com.google.gwt.dev.shell.jetty.JettyLauncher$WebAppContextWithReload@398323{/,C:\Users\Ssefyou\workspace\GwtSpringHiberJpa\war}
    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Invocation of init method failed; nested exception is javax.persistence.PersistenceException: [PersistenceUnit: MyPersistenceUnit] Unable to configure EntityManagerFactory
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1455)
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)
    	at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:294)
    	at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:225)
    	at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:291)
    	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193)
    	at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:567)
    	at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:913)
    	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:464)
    	at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:385)
    	at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:284)
    	at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:111)
    	at org.mortbay.jetty.handler.ContextHandler.startContext(ContextHandler.java:543)
    	at org.mortbay.jetty.servlet.Context.startContext(Context.java:136)
    	at org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1220)
    	at org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:513)
    	at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:448)
    	at com.google.gwt.dev.shell.jetty.JettyLauncher$WebAppContextWithReload.doStart(JettyLauncher.java:468)
    	at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
    	at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130)
    	at org.mortbay.jetty.handler.RequestLogHandler.doStart(RequestLogHandler.java:115)
    	at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
    	at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130)
    	at org.mortbay.jetty.Server.doStart(Server.java:222)
    	at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
    	at com.google.gwt.dev.shell.jetty.JettyLauncher.start(JettyLauncher.java:672)
    	at com.google.gwt.dev.DevMode.doStartUpServer(DevMode.java:509)
    	at com.google.gwt.dev.DevModeBase.startUp(DevModeBase.java:1068)
    	at com.google.gwt.dev.DevModeBase.run(DevModeBase.java:811)
    	at com.google.gwt.dev.DevMode.main(DevMode.java:311)
    Caused by: javax.persistence.PersistenceException: [PersistenceUnit: MyPersistenceUnit] Unable to configure EntityManagerFactory
    	at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:375)
    	at org.hibernate.ejb.HibernatePersistence.createEntityManagerFactory(HibernatePersistence.java:55)
    	at javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:48)
    	at org.springframework.orm.jpa.LocalEntityManagerFactoryBean.createNativeEntityManagerFactory(LocalEntityManagerFactoryBean.java:92)
    	at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.afterPropertiesSet(AbstractEntityManagerFactoryBean.java:310)
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1514)
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1452)
    	... 30 more
    Caused by: org.hibernate.HibernateException: Unable to get the default Bean Validation factory
    	at org.hibernate.cfg.beanvalidation.BeanValidationActivator.applyDDL(BeanValidationActivator.java:104)
    	at org.hibernate.cfg.AnnotationConfiguration.applyBeanValidationConstraintsOnDDL(AnnotationConfiguration.java:477)
    	at org.hibernate.cfg.AnnotationConfiguration.applyConstraintsToDDL(AnnotationConfiguration.java:429)
    	at org.hibernate.cfg.AnnotationConfiguration.secondPassCompile(AnnotationConfiguration.java:403)
    	at org.hibernate.cfg.Configuration.buildMappings(Configuration.java:1206)
    	at org.hibernate.ejb.Ejb3Configuration.buildMappings(Ejb3Configuration.java:1453)
    	at org.hibernate.ejb.EventListenerConfigurator.configure(EventListenerConfigurator.java:193)
    	at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:1081)
    	at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:279)
    	at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:363)
    	... 36 more
    Caused by: java.lang.reflect.InvocationTargetException
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    	at java.lang.reflect.Method.invoke(Method.java:597)
    	at org.hibernate.cfg.beanvalidation.BeanValidationActivator.applyDDL(BeanValidationActivator.java:95)
    	... 45 more
    Caused by: org.hibernate.HibernateException: Unable to build the default ValidatorFactory
    	at org.hibernate.cfg.beanvalidation.TypeSafeActivator.getValidatorFactory(TypeSafeActivator.java:302)
    	at org.hibernate.cfg.beanvalidation.TypeSafeActivator.applyDDL(TypeSafeActivator.java:82)
    	... 50 more
    Caused by: javax.validation.ValidationException: Unable to find a default provider
    	at javax.validation.Validation$GenericBootstrapImpl.configure(Validation.java:264)
    	at javax.validation.Validation.buildDefaultValidatorFactory(Validation.java:111)
    	at org.hibernate.cfg.beanvalidation.TypeSafeActivator.getValidatorFactory(TypeSafeActivator.java:299)
    	... 51 more
       [WARN] Nested in org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Invocation of init method failed; nested exception is javax.persistence.PersistenceException: [PersistenceUnit: MyPersistenceUnit] Unable to configure EntityManagerFactory:
    javax.validation.ValidationException: Unable to find a default provider
    	at javax.validation.Validation$GenericBootstrapImpl.configure(Validation.java:264)
    	at javax.validation.Validation.buildDefaultValidatorFactory(Validation.java:111)
    	at org.hibernate.cfg.beanvalidation.TypeSafeActivator.getValidatorFactory(TypeSafeActivator.java:299)
    	at org.hibernate.cfg.beanvalidation.TypeSafeActivator.applyDDL(TypeSafeActivator.java:82)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    	at java.lang.reflect.Method.invoke(Method.java:597)
    	at org.hibernate.cfg.beanvalidation.BeanValidationActivator.applyDDL(BeanValidationActivator.java:95)
    	at org.hibernate.cfg.AnnotationConfiguration.applyBeanValidationConstraintsOnDDL(AnnotationConfiguration.java:477)
    	at org.hibernate.cfg.AnnotationConfiguration.applyConstraintsToDDL(AnnotationConfiguration.java:429)
    	at org.hibernate.cfg.AnnotationConfiguration.secondPassCompile(AnnotationConfiguration.java:403)
    	at org.hibernate.cfg.Configuration.buildMappings(Configuration.java:1206)
    	at org.hibernate.ejb.Ejb3Configuration.buildMappings(Ejb3Configuration.java:1453)
    	at org.hibernate.ejb.EventListenerConfigurator.configure(EventListenerConfigurator.java:193)
    	at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:1081)
    	at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:279)
    	at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:363)
    	at org.hibernate.ejb.HibernatePersistence.createEntityManagerFactory(HibernatePersistence.java:55)
    	at javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:48)
    	at org.springframework.orm.jpa.LocalEntityManagerFactoryBean.createNativeEntityManagerFactory(LocalEntityManagerFactoryBean.java:92)
    	at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.afterPropertiesSet(AbstractEntityManagerFactoryBean.java:310)
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1514)
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1452)
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)
    	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)
    	at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:294)
    	at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:225)
    	at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:291)
    	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193)
    	at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:567)
    	at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:913)
    	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:464)
    	at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:385)
    	at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:284)
    	at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:111)
    	at org.mortbay.jetty.handler.ContextHandler.startContext(ContextHandler.java:543)
    	at org.mortbay.jetty.servlet.Context.startContext(Context.java:136)
    	at org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1220)
    	at org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:513)
    	at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:448)
    	at com.google.gwt.dev.shell.jetty.JettyLauncher$WebAppContextWithReload.doStart(JettyLauncher.java:468)
    	at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
    	at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130)
    	at org.mortbay.jetty.handler.RequestLogHandler.doStart(RequestLogHandler.java:115)
    	at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
    	at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130)
    	at org.mortbay.jetty.Server.doStart(Server.java:222)
    	at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
    	at com.google.gwt.dev.shell.jetty.JettyLauncher.start(JettyLauncher.java:672)
    	at com.google.gwt.dev.DevMode.doStartUpServer(DevMode.java:509)
    	at com.google.gwt.dev.DevModeBase.startUp(DevModeBase.java:1068)
    	at com.google.gwt.dev.DevModeBase.run(DevModeBase.java:811)
    	at com.google.gwt.dev.DevMode.main(DevMode.java:311)
    j'ai essaye d'ajouter le jar de validation de hibernate (3 et aussi 4 ) mais rien n'a changé !!! ça fait 2 jours que je galere avec cette exception

    merci pour votre aide

  2. #2
    Invité régulier
    Inscrit en
    janvier 2007
    Messages
    20
    Détails du profil
    Informations forums :
    Inscription : janvier 2007
    Messages : 20
    Points : 8
    Points
    8

    Par défaut GWT + Spring = Problème d'initialisation de beans

    Salut Youssef,

    J'ai exactement le même problème que toi.

    Aurais-tu trouvé une solution stp ? Perso, je pense que Spring n'arrive pas à initialiser les beans car il ne trouve pas (lors du parsing) le bon fichier (à savoir dans mon cas le fichier : 'database.properties') mais je pense que pour toi ça doit être un problème similaire.

    Voici une partie de ma stack trace :

    Code :
    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
    Starting Jetty on port 8888
       [WARN] Failed startup of context com.google.gwt.dev.shell.jetty.JettyLauncher$WebAppContextWithReload@33ec9e{/,C:\workspace\Teleprocedure\war}
    org.springframework.beans.factory.BeanInitializationException: Could not load properties; nested exception is java.io.FileNotFoundException: Could not open ServletContext resource [/database.properties]
    	at org.springframework.beans.factory.config.PropertyResourceConfigurer.postProcessBeanFactory(PropertyResourceConfigurer.java:87)
    	at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:681)
    	at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:656)
    	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:446)
    	at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:385)
    	at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:284)
    	at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:111)
    	at org.mortbay.jetty.handler.ContextHandler.startContext(ContextHandler.java:543)
    	at org.mortbay.jetty.servlet.Context.startContext(Context.java:136)
    	at org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1220)
    	at org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:513)
    	at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:448)
    	at com.google.gwt.dev.shell.jetty.JettyLauncher$WebAppContextWithReload.doStart(JettyLauncher.java:468)
    	at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
    	at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130)
    	at org.mortbay.jetty.handler.RequestLogHandler.doStart(RequestLogHandler.java:115)
    	at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
    	at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130)
    	at org.mortbay.jetty.Server.doStart(Server.java:222)
    	at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
    	at com.google.gwt.dev.shell.jetty.JettyLauncher.start(JettyLauncher.java:672)
    	at com.google.gwt.dev.DevMode.doStartUpServer(DevMode.java:509)
    	at com.google.gwt.dev.DevModeBase.startUp(DevModeBase.java:1068)
    	at com.google.gwt.dev.DevModeBase.run(DevModeBase.java:811)
    	at com.google.gwt.dev.DevMode.main(DevMode.java:311)
    Caused by: java.io.FileNotFoundException: Could not open ServletContext resource [/database.properties]
    	at org.springframework.web.context.support.ServletContextResource.getInputStream(ServletContextResource.java:140)
    	at org.springframework.core.io.support.PropertiesLoaderSupport.loadProperties(PropertiesLoaderSupport.java:181)
    	at org.springframework.core.io.support.PropertiesLoaderSupport.mergeProperties(PropertiesLoaderSupport.java:161)
    	at org.springframework.beans.factory.config.PropertyResourceConfigurer.postProcessBeanFactory(PropertyResourceConfigurer.java:78)
    	... 24 more
       [WARN] Nested in org.springframework.beans.factory.BeanInitializationException: Could not load properties; nested exception is java.io.FileNotFoundException: Could not open ServletContext resource [/database.properties]:
    java.io.FileNotFoundException: Could not open ServletContext resource [/database.properties]
    	at org.springframework.web.context.support.ServletContextResource.getInputStream(ServletContextResource.java:140)
    	at org.springframework.core.io.support.PropertiesLoaderSupport.loadProperties(PropertiesLoaderSupport.java:181)
    	at org.springframework.core.io.support.PropertiesLoaderSupport.mergeProperties(PropertiesLoaderSupport.java:161)
    	at org.springframework.beans.factory.config.PropertyResourceConfigurer.postProcessBeanFactory(PropertyResourceConfigurer.java:78)
    	at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:681)
    	at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:656)
    	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:446)
    	at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:385)
    	at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:284)
    	at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:111)
    	at org.mortbay.jetty.handler.ContextHandler.startContext(ContextHandler.java:543)
    	at org.mortbay.jetty.servlet.Context.startContext(Context.java:136)
    	at org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1220)
    	at org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:513)
    	at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:448)
    	at com.google.gwt.dev.shell.jetty.JettyLauncher$WebAppContextWithReload.doStart(JettyLauncher.java:468)
    	at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
    	at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130)
    	at org.mortbay.jetty.handler.RequestLogHandler.doStart(RequestLogHandler.java:115)
    	at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
    	at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130)
    	at org.mortbay.jetty.Server.doStart(Server.java:222)
    	at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39)
    	at com.google.gwt.dev.shell.jetty.JettyLauncher.start(JettyLauncher.java:672)
    	at com.google.gwt.dev.DevMode.doStartUpServer(DevMode.java:509)
    	at com.google.gwt.dev.DevModeBase.startUp(DevModeBase.java:1068)
    	at com.google.gwt.dev.DevModeBase.run(DevModeBase.java:811)
    	at com.google.gwt.dev.DevMode.main(DevMode.java:311)
    Edit : Ton problème n'est pas tout à fait le même que le mien après revue de tes logs ! En fait, le problème c'est que Spring n'arrive pas à instancier ton EntityManager. C'est peut-être normal car tu t'es trompé dans la déclaration de ton bean EntityManager : Il faut mettre "ref" et non "value"

    Code :
    1
    2
    3
    <bean class="org.springframework.orm.jpa.LocalEntityManagerFactoryBean" id="entityManagerFactory">
            <property name="persistenceUnitName" ref="MyPersistenceUnit"/>
        </bean>
    Ma3a salam !

Liens sociaux

Règles de messages

  • Vous ne pouvez pas créer de nouvelles discussions
  • Vous ne pouvez pas envoyer des réponses
  • Vous ne pouvez pas envoyer des pièces jointes
  • Vous ne pouvez pas modifier vos messages
  •