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

Wildfly/JBoss Java Discussion :

JNDI relation entre EJB et WAR


Sujet :

Wildfly/JBoss Java

  1. #1
    Membre confirmé
    Avatar de geforce
    Homme Profil pro
    Ingénieur développement logiciels
    Inscrit en
    Janvier 2010
    Messages
    1 055
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : Canada

    Informations professionnelles :
    Activité : Ingénieur développement logiciels
    Secteur : High Tech - Éditeur de logiciels

    Informations forums :
    Inscription : Janvier 2010
    Messages : 1 055
    Points : 559
    Points
    559
    Par défaut JNDI relation entre EJB et WAR
    Bonjour,

    j'ai un message d'erreur qui m'arrive souvent, qui est :
    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
    11:02:37,377 INFO  [org.jboss.as.ejb3.deployment.processors.EjbJndiBindingsDeploymentUnitProcessor] (MSC service thread 1-4) JNDI bindings for session bean named ParamBean in deployment unit subdeployment "MIDA.jar" of deployment "MIDA-EAR.ear" are as follows:
    
    	java:global/MIDA-EAR/MIDA/ParamBean!ireq.beans.ParamBean
    	java:app/MIDA/ParamBean!ireq.beans.ParamBean
    	java:module/ParamBean!ireq.beans.ParamBean
    	java:global/MIDA-EAR/MIDA/ParamBean!ireq.beans.ParamBeanLocal
    	java:app/MIDA/ParamBean!ireq.beans.ParamBeanLocal
    	java:module/ParamBean!ireq.beans.ParamBeanLocal
    
    11:02:37,408 INFO  [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-2) JBAS010403: Deploying JDBC-compliant driver class oracle.jdbc.OracleDriver (version 11.2)
    11:02:37,689 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/MidatService2]] (MSC service thread 1-8) Exception sending context initialized event to listener instance of class org.jboss.resteasy.plugins.server.servlet.ResteasyBootstrap: java.lang.RuntimeException: javax.naming.NameNotFoundException: MIDA-EAR/MIDA/TransfoBean!ireq.beans.TransfoBean -- service jboss.naming.context.java.global.MIDA-EAR.MIDA."TransfoBean!ireq.beans.TransfoBean"
    	at org.jboss.resteasy.plugins.server.resourcefactory.JndiResourceFactory.getScannableClass(JndiResourceFactory.java:62) [resteasy-jaxrs-2.3.2.Final.jar:]
    	at org.jboss.resteasy.core.ResourceMethodRegistry.addResourceFactory(ResourceMethodRegistry.java:96) [resteasy-jaxrs-2.3.2.Final.jar:]
    	at org.jboss.resteasy.core.ResourceMethodRegistry.addResourceFactory(ResourceMethodRegistry.java:84) [resteasy-jaxrs-2.3.2.Final.jar:]
    	at org.jboss.resteasy.core.ResourceMethodRegistry.addJndiResource(ResourceMethodRegistry.java:58) [resteasy-jaxrs-2.3.2.Final.jar:]
    	at org.jboss.resteasy.spi.ResteasyDeployment.registration(ResteasyDeployment.java:350) [resteasy-jaxrs-2.3.2.Final.jar:]
    	at org.jboss.resteasy.spi.ResteasyDeployment.start(ResteasyDeployment.java:225) [resteasy-jaxrs-2.3.2.Final.jar:]
    	at org.jboss.resteasy.plugins.server.servlet.ResteasyBootstrap.contextInitialized(ResteasyBootstrap.java:28) [resteasy-jaxrs-2.3.2.Final.jar:]
    	at org.apache.catalina.core.StandardContext.contextListenerStart(StandardContext.java:3392) [jbossweb-7.0.13.Final.jar:]
    	at org.apache.catalina.core.StandardContext.start(StandardContext.java:3850) [jbossweb-7.0.13.Final.jar:]
    	at org.jboss.as.web.deployment.WebDeploymentService.start(WebDeploymentService.java:90) [jboss-as-web-7.1.1.Final.jar:7.1.1.Final]
    	at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811)
    	at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746)
    	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [rt.jar:1.6.0_27]
    	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [rt.jar:1.6.0_27]
    	at java.lang.Thread.run(Thread.java:662) [rt.jar:1.6.0_27]
    Caused by: javax.naming.NameNotFoundException: MIDA-EAR/MIDA/TransfoBean!ireq.beans.TransfoBean -- service jboss.naming.context.java.global.MIDA-EAR.MIDA."TransfoBean!ireq.beans.TransfoBean"
    	at org.jboss.as.naming.ServiceBasedNamingStore.lookup(ServiceBasedNamingStore.java:97)
    	at org.jboss.as.naming.NamingContext.lookup(NamingContext.java:178)
    	at org.jboss.as.naming.InitialContext.lookup(InitialContext.java:123)
    	at org.jboss.as.naming.NamingContext.lookup(NamingContext.java:214)
    	at javax.naming.InitialContext.lookup(InitialContext.java:392) [rt.jar:1.6.0_27]
    	at org.jboss.resteasy.plugins.server.resourcefactory.JndiResourceFactory.getScannableClass(JndiResourceFactory.java:57) [resteasy-jaxrs-2.3.2.Final.jar:]
    	... 14 more
    
    11:02:37,736 ERROR [org.apache.catalina.core.StandardContext] (MSC service thread 1-8) Error listenerStart
    11:02:37,736 ERROR [org.apache.catalina.core.StandardContext] (MSC service thread 1-8) Context [/MidatService2] startup failed due to previous errors
    11:02:37,752 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-8) MSC00001: Failed to start service jboss.web.deployment.default-host./MidatService2: org.jboss.msc.service.StartException in service jboss.web.deployment.default-host./MidatService2: JBAS018040: Failed to start context
    	at org.jboss.as.web.deployment.WebDeploymentService.start(WebDeploymentService.java:95)
    	at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]
    	at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]
    	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [rt.jar:1.6.0_27]
    	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [rt.jar:1.6.0_27]
    	at java.lang.Thread.run(Thread.java:662) [rt.jar:1.6.0_27]
    J’ai trouvé dans un des forums que ma solution devrais être : ajouté le descripteur de déploiement dans le EAR et ajouté <initialize-in-order>true</initialize-in-order> pour m'assuré que je ejb.jar est déployer avec le war.
    https://developer.jboss.org/thread/172042?tstart=0 (voir a la fin)

    Mais ca pas marché pour moi !! Et je ne voix pas quoi faire de plus pour corrigé ce bug !!!

    Mon web.xml:
    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
    <?xml version="1.0" encoding="UTF-8"?>
    <web-app id="WebApp_ID" 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">
     <display-name>MidatService2</display-name>
     
     
     <context-param>
      <param-name>resteasy.jndi.resources</param-name>
      <param-value>java:global/MIDA-EAR/MIDA/TransfoBean!ireq.beans.TransfoBean,java:global/MIDA-EAR/MIDA/TransfoBean!ireq.beans.TransfoBeanLocal,java:global/MIDA-EAR/MIDA/JaxtestBean!ireq.beans.Jaxtest,java:global/MIDA-EAR/MIDA/JaxtestBean,java:global/MIDA-EAR/MIDA/UserBean!ireq.beans.UserBean,java:global/MIDA-EAR/MIDA/UserBean!ireq.beans.UserBeanLocal,java:global/MIDA-EAR/MIDA/InterventionBean!ireq.beans.InterventionBean,java:global/MIDA-EAR/MIDA/InterventionBean!ireq.beans.InterventionBeanLocal,java:global/MIDA-EAR/MIDA/PosteBean!ireq.beans.PosteBeanLocal,java:global/MIDA-EAR/MIDA/PosteBean!ireq.beans.PosteBeanl,java:global/MIDA-EAR/MIDA/MesureBean!ireq.beans.MesureBeanLoca,java:global/MIDA-EAR/MIDA/MesureBean!ireq.beans.MesureBean,java:global/MIDA-EAR/MIDA/ModeleBean2!ireq.beans.ModeleBean2,java:global/MIDA-EAR/MIDA/ModeleBean2,java:global/MIDA-EAR/MIDA/ModeleBean!ireq.beans.ModeleBeanLocal,java:global/MIDA-EAR/MIDA/ModeleBean!ireq.beans.ModeleBean,java:global/MIDA-EAR/MIDA/ParamBean!ireq.beans.ParamBeanLocal,java:global/MIA-EAR/MIDA/ParamBean!ireq.beans.ParamBean</param-value>
     </context-param>
     
     
     <context-param>
      <param-name>resteasy.role.based.security</param-name>
      <param-value>true</param-value>
     </context-param>
     <context-param>
      <param-name>resteasy.servlet.mapping.prefix</param-name>
      <param-value>/Service</param-value>
     </context-param>
     <listener>
      <listener-class>org.jboss.resteasy.plugins.server.servlet.ResteasyBootstrap</listener-class>
     </listener>
     <servlet>
      <servlet-name>Resteasy</servlet-name>
      <servlet-class>org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher</servlet-class>
     </servlet>
     <servlet-mapping>
      <servlet-name>Resteasy</servlet-name>
      <url-pattern>/Service/*</url-pattern>
     </servlet-mapping>
     <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>
     <security-constraint>
      <web-resource-collection>
       <web-resource-name>All resources</web-resource-name>
       <description>Protects all resources</description>
       <url-pattern>/*</url-pattern>
       <http-method>GET</http-method>
       <http-method>POST</http-method>
       <http-method>DELETE</http-method>
       <http-method>PUT</http-method>
      </web-resource-collection>
      <auth-constraint>
       <role-name>Admin</role-name>
       <role-name>Intervenant</role-name>
       <role-name>Superviseur</role-name>
      </auth-constraint>
     </security-constraint>
     <login-config>
      <auth-method>BASIC</auth-method>
      <realm-name>Test Realm</realm-name>
     </login-config>
     <security-role>
      <role-name>Admin</role-name>
     </security-role>
     <security-role>
      <role-name>Intervenant</role-name>
     </security-role>
     <security-role>
      <role-name>Superviseur</role-name>
     </security-role>
    </web-app>
    mon application.xml :
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    <?xml version="1.0" encoding="UTF-8"?>
    <application xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:application="http://java.sun.com/xml/ns/javaee/application_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_6.xsd" id="Application_ID" version="6">
      <display-name>MIDAEAR</display-name>
      <initialize-in-order>true</initialize-in-order>
      <module>
        <web>
          <web-uri>MidatService2.war</web-uri>
          <context-root>MidatService2</context-root>
        </web>
      </module>
      <module>
        <ejb>MIDA.jar</ejb>
      </module>
    </application>
    Y a t'il une solution !?

    Grand merci d'avance

  2. #2
    Membre averti
    Homme Profil pro
    Inscrit en
    Octobre 2011
    Messages
    250
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : Belgique

    Informations forums :
    Inscription : Octobre 2011
    Messages : 250
    Points : 403
    Points
    403
    Par défaut
    initialize-in-order dit au conteneur d'initialiser les modules dans l'ordre dans lequel il les trouve dans le fichier application.xml, or dans ton application.xml le war est déployé avant le module ejb.
    Est-ce que le module ejb est bien présent avant le war dans ton application.xml ?

  3. #3
    Membre confirmé
    Avatar de geforce
    Homme Profil pro
    Ingénieur développement logiciels
    Inscrit en
    Janvier 2010
    Messages
    1 055
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : Canada

    Informations professionnelles :
    Activité : Ingénieur développement logiciels
    Secteur : High Tech - Éditeur de logiciels

    Informations forums :
    Inscription : Janvier 2010
    Messages : 1 055
    Points : 559
    Points
    559
    Par défaut
    Citation Envoyé par NoClassDefFound Voir le message
    initialize-in-order dit au conteneur d'initialiser les modules dans l'ordre dans lequel il les trouve dans le fichier application.xml, or dans ton application.xml le war est déployé avant le module ejb.
    Est-ce que le module ejb est bien présent avant le war dans ton application.xml ?
    OK, merci pour la précision j'ai pu corriger, mais malheureusement j'ai toujours le même message d'erreur sans déploiement ! (ce qui me laisse sans voix ou sans solution)
    Y t'il d'autre solution possible ?

    Merci

    All Message :
    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
    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
     
    14:44:34,311 INFO  [org.jboss.as.server.deployment] (MSC service thread 1-2) JBAS015876: Starting deployment of "MIDA-EAR.ear"
    14:44:35,412 INFO  [org.jboss.as.server.deployment] (MSC service thread 1-7) JBAS015876: Starting deployment of "MIDA.jar"
    14:44:35,412 INFO  [org.jboss.as.server.deployment] (MSC service thread 1-6) JBAS015876: Starting deployment of "MidatService2.war"
    14:44:35,473 INFO  [org.jboss.as.ejb3.deployment.processors.EjbJndiBindingsDeploymentUnitProcessor] (MSC service thread 1-7) JNDI bindings for session bean named TransfoBean in deployment unit subdeployment "MIDA.jar" of deployment "MIDA-EAR.ear" are as follows:
     
    	java:global/MIDA-EAR/MIDA/TransfoBean!ireq.beans.TransfoBean
    	java:app/MIDA/TransfoBean!ireq.beans.TransfoBean
    	java:module/TransfoBean!ireq.beans.TransfoBean
    	java:global/MIDA-EAR/MIDA/TransfoBean!ireq.beans.TransfoBeanLocal
    	java:app/MIDA/TransfoBean!ireq.beans.TransfoBeanLocal
    	java:module/TransfoBean!ireq.beans.TransfoBeanLocal
     
    14:44:35,476 INFO  [org.jboss.as.ejb3.deployment.processors.EjbJndiBindingsDeploymentUnitProcessor] (MSC service thread 1-7) JNDI bindings for session bean named JaxtestBean in deployment unit subdeployment "MIDA.jar" of deployment "MIDA-EAR.ear" are as follows:
     
    	java:global/MIDA-EAR/MIDA/JaxtestBean!ireq.beans.Jaxtest
    	java:app/MIDA/JaxtestBean!ireq.beans.Jaxtest
    	java:module/JaxtestBean!ireq.beans.Jaxtest
    	java:global/MIDA-EAR/MIDA/JaxtestBean
    	java:app/MIDA/JaxtestBean
    	java:module/JaxtestBean
     
    14:44:35,477 INFO  [org.jboss.as.ejb3.deployment.processors.EjbJndiBindingsDeploymentUnitProcessor] (MSC service thread 1-7) JNDI bindings for session bean named UserBean in deployment unit subdeployment "MIDA.jar" of deployment "MIDA-EAR.ear" are as follows:
     
    	java:global/MIDA-EAR/MIDA/UserBean!ireq.beans.UserBeanLocal
    	java:app/MIDA/UserBean!ireq.beans.UserBeanLocal
    	java:module/UserBean!ireq.beans.UserBeanLocal
    	java:global/MIDA-EAR/MIDA/UserBean!ireq.beans.UserBean
    	java:app/MIDA/UserBean!ireq.beans.UserBean
    	java:module/UserBean!ireq.beans.UserBean
     
    14:44:35,479 INFO  [org.jboss.as.ejb3.deployment.processors.EjbJndiBindingsDeploymentUnitProcessor] (MSC service thread 1-7) JNDI bindings for session bean named InterventionBean in deployment unit subdeployment "MIDA.jar" of deployment "MIDA-EAR.ear" are as follows:
     
    	java:global/MIDA-EAR/MIDA/InterventionBean!ireq.beans.InterventionBeanLocal
    	java:app/MIDA/InterventionBean!ireq.beans.InterventionBeanLocal
    	java:module/InterventionBean!ireq.beans.InterventionBeanLocal
    	java:global/MIDA-EAR/MIDA/InterventionBean!ireq.beans.InterventionBean
    	java:app/MIDA/InterventionBean!ireq.beans.InterventionBean
    	java:module/InterventionBean!ireq.beans.InterventionBean
     
    14:44:35,481 INFO  [org.jboss.as.ejb3.deployment.processors.EjbJndiBindingsDeploymentUnitProcessor] (MSC service thread 1-7) JNDI bindings for session bean named PosteBean in deployment unit subdeployment "MIDA.jar" of deployment "MIDA-EAR.ear" are as follows:
     
    	java:global/MIDA-EAR/MIDA/PosteBean!ireq.beans.PosteBean
    	java:app/MIDA/PosteBean!ireq.beans.PosteBean
    	java:module/PosteBean!ireq.beans.PosteBean
    	java:global/MIDA-EAR/MIDA/PosteBean!ireq.beans.PosteBeanLocal
    	java:app/MIDA/PosteBean!ireq.beans.PosteBeanLocal
    	java:module/PosteBean!ireq.beans.PosteBeanLocal
     
    14:44:35,483 INFO  [org.jboss.as.ejb3.deployment.processors.EjbJndiBindingsDeploymentUnitProcessor] (MSC service thread 1-7) JNDI bindings for session bean named MesureBean in deployment unit subdeployment "MIDA.jar" of deployment "MIDA-EAR.ear" are as follows:
     
    	java:global/MIDA-EAR/MIDA/MesureBean!ireq.beans.MesureBeanLocal
    	java:app/MIDA/MesureBean!ireq.beans.MesureBeanLocal
    	java:module/MesureBean!ireq.beans.MesureBeanLocal
    	java:global/MIDA-EAR/MIDA/MesureBean!ireq.beans.MesureBean
    	java:app/MIDA/MesureBean!ireq.beans.MesureBean
    	java:module/MesureBean!ireq.beans.MesureBean
     
    14:44:35,485 INFO  [org.jboss.as.ejb3.deployment.processors.EjbJndiBindingsDeploymentUnitProcessor] (MSC service thread 1-7) JNDI bindings for session bean named ModeleBean2 in deployment unit subdeployment "MIDA.jar" of deployment "MIDA-EAR.ear" are as follows:
     
    	java:global/MIDA-EAR/MIDA/ModeleBean2!ireq.beans.ModeleBean2
    	java:app/MIDA/ModeleBean2!ireq.beans.ModeleBean2
    	java:module/ModeleBean2!ireq.beans.ModeleBean2
    	java:global/MIDA-EAR/MIDA/ModeleBean2
    	java:app/MIDA/ModeleBean2
    	java:module/ModeleBean2
     
    14:44:35,488 INFO  [org.jboss.as.ejb3.deployment.processors.EjbJndiBindingsDeploymentUnitProcessor] (MSC service thread 1-7) JNDI bindings for session bean named ModeleBean in deployment unit subdeployment "MIDA.jar" of deployment "MIDA-EAR.ear" are as follows:
     
    	java:global/MIDA-EAR/MIDA/ModeleBean!ireq.beans.ModeleBean
    	java:app/MIDA/ModeleBean!ireq.beans.ModeleBean
    	java:module/ModeleBean!ireq.beans.ModeleBean
    	java:global/MIDA-EAR/MIDA/ModeleBean!ireq.beans.ModeleBeanLocal
    	java:app/MIDA/ModeleBean!ireq.beans.ModeleBeanLocal
    	java:module/ModeleBean!ireq.beans.ModeleBeanLocal
     
    14:44:35,490 INFO  [org.jboss.as.ejb3.deployment.processors.EjbJndiBindingsDeploymentUnitProcessor] (MSC service thread 1-7) JNDI bindings for session bean named ParamBean in deployment unit subdeployment "MIDA.jar" of deployment "MIDA-EAR.ear" are as follows:
     
    	java:global/MIDA-EAR/MIDA/ParamBean!ireq.beans.ParamBeanLocal
    	java:app/MIDA/ParamBean!ireq.beans.ParamBeanLocal
    	java:module/ParamBean!ireq.beans.ParamBeanLocal
    	java:global/MIDA-EAR/MIDA/ParamBean!ireq.beans.ParamBean
    	java:app/MIDA/ParamBean!ireq.beans.ParamBean
    	java:module/ParamBean!ireq.beans.ParamBean
     
    14:44:35,513 INFO  [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-7) JBAS010403: Deploying JDBC-compliant driver class oracle.jdbc.OracleDriver (version 11.2)
    14:44:35,831 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/MidatService2]] (MSC service thread 1-1) Exception sending context initialized event to listener instance of class org.jboss.resteasy.plugins.server.servlet.ResteasyBootstrap: java.lang.RuntimeException: javax.naming.NameNotFoundException: MIDA-EAR/MIDA/PosteBean!ireq.beans.PosteBeanl -- service jboss.naming.context.java.global.MIDA-EAR.MIDA."PosteBean!ireq.beans.PosteBeanl"
    	at org.jboss.resteasy.plugins.server.resourcefactory.JndiResourceFactory.getScannableClass(JndiResourceFactory.java:62) [resteasy-jaxrs-2.3.2.Final.jar:]
    	at org.jboss.resteasy.core.ResourceMethodRegistry.addResourceFactory(ResourceMethodRegistry.java:96) [resteasy-jaxrs-2.3.2.Final.jar:]
    	at org.jboss.resteasy.core.ResourceMethodRegistry.addResourceFactory(ResourceMethodRegistry.java:84) [resteasy-jaxrs-2.3.2.Final.jar:]
    	at org.jboss.resteasy.core.ResourceMethodRegistry.addJndiResource(ResourceMethodRegistry.java:58) [resteasy-jaxrs-2.3.2.Final.jar:]
    	at org.jboss.resteasy.spi.ResteasyDeployment.registration(ResteasyDeployment.java:350) [resteasy-jaxrs-2.3.2.Final.jar:]
    	at org.jboss.resteasy.spi.ResteasyDeployment.start(ResteasyDeployment.java:225) [resteasy-jaxrs-2.3.2.Final.jar:]
    	at org.jboss.resteasy.plugins.server.servlet.ResteasyBootstrap.contextInitialized(ResteasyBootstrap.java:28) [resteasy-jaxrs-2.3.2.Final.jar:]
    	at org.apache.catalina.core.StandardContext.contextListenerStart(StandardContext.java:3392) [jbossweb-7.0.13.Final.jar:]
    	at org.apache.catalina.core.StandardContext.start(StandardContext.java:3850) [jbossweb-7.0.13.Final.jar:]
    	at org.jboss.as.web.deployment.WebDeploymentService.start(WebDeploymentService.java:90) [jboss-as-web-7.1.1.Final.jar:7.1.1.Final]
    	at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811)
    	at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746)
    	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [rt.jar:1.6.0_27]
    	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [rt.jar:1.6.0_27]
    	at java.lang.Thread.run(Thread.java:662) [rt.jar:1.6.0_27]
    Caused by: javax.naming.NameNotFoundException: MIDA-EAR/MIDA/PosteBean!ireq.beans.PosteBeanl -- service jboss.naming.context.java.global.MIDA-EAR.MIDA."PosteBean!ireq.beans.PosteBeanl"
    	at org.jboss.as.naming.ServiceBasedNamingStore.lookup(ServiceBasedNamingStore.java:97)
    	at org.jboss.as.naming.NamingContext.lookup(NamingContext.java:178)
    	at org.jboss.as.naming.InitialContext.lookup(InitialContext.java:123)
    	at org.jboss.as.naming.NamingContext.lookup(NamingContext.java:214)
    	at javax.naming.InitialContext.lookup(InitialContext.java:392) [rt.jar:1.6.0_27]
    	at org.jboss.resteasy.plugins.server.resourcefactory.JndiResourceFactory.getScannableClass(JndiResourceFactory.java:57) [resteasy-jaxrs-2.3.2.Final.jar:]
    	... 14 more
     
    14:44:35,856 ERROR [org.apache.catalina.core.StandardContext] (MSC service thread 1-1) Error listenerStart
    14:44:35,856 ERROR [org.apache.catalina.core.StandardContext] (MSC service thread 1-1) Context [/MidatService2] startup failed due to previous errors
    14:44:35,858 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-1) MSC00001: Failed to start service jboss.web.deployment.default-host./MidatService2: org.jboss.msc.service.StartException in service jboss.web.deployment.default-host./MidatService2: JBAS018040: Failed to start context
    	at org.jboss.as.web.deployment.WebDeploymentService.start(WebDeploymentService.java:95)
    	at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]
    	at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]
    	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [rt.jar:1.6.0_27]
    	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [rt.jar:1.6.0_27]
    	at java.lang.Thread.run(Thread.java:662) [rt.jar:1.6.0_27]
     
    14:44:36,066 INFO  [org.jboss.as.server] (DeploymentScanner-threads - 1) JBAS015870: Deploy of deployment "MIDA-EAR.ear" was rolled back with failure message {"JBAS014671: Failed services" => {"jboss.web.deployment.default-host./MidatService2" => "org.jboss.msc.service.StartException in service jboss.web.deployment.default-host./MidatService2: JBAS018040: Failed to start context"}}
    14:44:36,083 INFO  [org.jboss.as.server.deployment] (MSC service thread 1-4) JBAS015877: Stopped deployment MIDA.jar in 18ms
    14:44:36,084 INFO  [org.jboss.as.server.deployment] (MSC service thread 1-6) JBAS015877: Stopped deployment MidatService2.war in 18ms
    14:44:36,134 INFO  [org.jboss.as.server.deployment] (MSC service thread 1-6) JBAS015877: Stopped deployment MIDA-EAR.ear in 69ms
    14:44:36,136 INFO  [org.jboss.as.controller] (DeploymentScanner-threads - 1) JBAS014774: Service status report
    JBAS014777:   Services which failed to start:      service jboss.web.deployment.default-host./MidatService2: org.jboss.msc.service.StartException in service jboss.web.deployment.default-host./MidatService2: JBAS018040: Failed to start context
     
    14:44:36,139 ERROR [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 2) {"JBAS014653: Composite operation failed and was rolled back. Steps that failed:" => {"Operation step-2" => {"JBAS014671: Failed services" => {"jboss.web.deployment.default-host./MidatService2" => "org.jboss.msc.service.StartException in service jboss.web.deployment.default-host./MidatService2: JBAS018040: Failed to start context"}}}}
    application.xml:
    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
    <?xml version="1.0" encoding="UTF-8"?>
    <application xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:application="http://java.sun.com/xml/ns/javaee/application_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_6.xsd" id="Application_ID" version="6">
      <display-name>MIDAEAR</display-name>
      <initialize-in-order>true</initialize-in-order>
     
      <module>
        <ejb>MIDA.jar</ejb>
      </module>
      <module>
        <web>
          <web-uri>MidatService2.war</web-uri>
          <context-root>MidatService2</context-root>
        </web>
      </module>
    </application>

  4. #4
    Membre averti
    Homme Profil pro
    Inscrit en
    Octobre 2011
    Messages
    250
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : Belgique

    Informations forums :
    Inscription : Octobre 2011
    Messages : 250
    Points : 403
    Points
    403
    Par défaut
    Quelle version de jboss utilises tu ?
    Si c'est du jboss 7 (eap 6.x), tu peux créer un fichier jboss-all.xml dans le répertoire META-INF de l'ear

Discussions similaires

  1. [EJB3 Entity] [debutant] Relation entre tables et EJB entity
    Par Celira dans le forum Java EE
    Réponses: 3
    Dernier message: 11/02/2008, 11h10
  2. Relation entre EJB, couche métiers, JSP et servlet
    Par infinity21 dans le forum Servlets/JSP
    Réponses: 13
    Dernier message: 06/03/2007, 00h50
  3. [EJB2.1 Entity] Probleme - Relation entre EJB - Composition d'EJB ??
    Par skrosoft dans le forum Java EE
    Réponses: 7
    Dernier message: 09/02/2007, 18h11
  4. Relations entre les Paquetages
    Par bran_noz dans le forum UML
    Réponses: 4
    Dernier message: 25/06/2004, 15h05
  5. [Relations] afficher les relations entre 2 tables
    Par dzincou dans le forum PostgreSQL
    Réponses: 5
    Dernier message: 14/01/2004, 18h07

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