12 Replies Latest reply on Feb 26, 2013 6:53 AM by prashant_mishra8

    Problem while deployed ear/war in jboss 7

    prashant_mishra8

      I am trying to deploy my web-service project in jboss as7 it deployed successfully but when I try to run it it gives error. I am using the the ApacheCXF for web service. below is the error

       

      View[/PmtPpvEventMaintenancePromptAndValidateRecordEntryPanel.xhtml]: javax.el.ELException: /PmtPpvEventMaintenancePromptAndValidateRecordEntryPanel.xhtml: java.lang.IllegalStateException: No EJB receiver available for handling [appName:,modulename:pocappareaws,distinctname:] combination for invocation context org.jboss.ejb.client.EJBClientInvocationContext@25aeb81

          at com.sun.faces.facelets.compiler.TextInstruction.write(TextInstruction.java:88) [jsf-impl-2.1.7-jbossorg-2.jar:]

          at com.sun.faces.facelets.compiler.UIInstructions.encodeBegin(UIInstructions.java:82) [jsf-impl-2.1.7-jbossorg-2.jar:]

          at com.sun.faces.facelets.compiler.UILeaf.encodeAll(UILeaf.java:183) [jsf-impl-2.1.7-jbossorg-2.jar:]

          at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1782) [jboss-jsf-api_2.1_spec-2.0.1.Final.jar:2.0.1.Final]

          at com.sun.faces.application.view.FaceletViewHandlingStrategy.renderView(FaceletViewHandlingStrategy.java:402) [jsf-impl-2.1.7-jbossorg-2.jar:]

          at com.sun.faces.application.view.MultiViewHandler.renderView(MultiViewHandler.java:128) [jsf-impl-2.1.7-jbossorg-2.jar:]

          at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:121) [jsf-impl-2.1.7-jbossorg-2.jar:]

          at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101) [jsf-impl-2.1.7-jbossorg-2.jar:]

          at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139) [jsf-impl-2.1.7-jbossorg-2.jar:]

          at javax.faces.webapp.FacesServlet.service(FacesServlet.java:594) [jboss-jsf-api_2.1_spec-2.0.1.Final.jar:2.0.1.Final]

          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:329) [jbossweb-7.0.13.Final.jar:]

          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:248) [jbossweb-7.0.13.Final.jar:]

          at com.databorough.utils.SessionTimeoutFilter.doFilter(SessionTimeoutFilter.java:77) [classes:]

          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:280) [jbossweb-7.0.13.Final.jar:]

          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:248) [jbossweb-7.0.13.Final.jar:]

          at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:275) [jbossweb-7.0.13.Final.jar:]

          at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:163) [jbossweb-7.0.13.Final.jar:]

          at org.jboss.as.jpa.interceptor.WebNonTxEmCloserValve.invoke(WebNonTxEmCloserValve.java:50) [jboss-as-jpa-7.1.1.Final.jar:7.1.1.Final]

          at org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:154) [jboss-as-web-7.1.1.Final.jar:7.1.1.Final]

          at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:155) [jbossweb-7.0.13.Final.jar:]

          at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) [jbossweb-7.0.13.Final.jar:]

          at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:111) [jbossweb-7.0.13.Final.jar:]

          at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:368) [jbossweb-7.0.13.Final.jar:]

          at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:877) [jbossweb-7.0.13.Final.jar:]

          at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:671) [jbossweb-7.0.13.Final.jar:]

          at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:930) [jbossweb-7.0.13.Final.jar:]

          at java.lang.Thread.run(Thread.java:662) [rt.jar:1.6.0_24]

        • 1. Re: Problem while deployed ear/war in jboss 7
          nickarls

          Are there remote EJB:s involved?

          1 of 1 people found this helpful
          • 2. Re: Problem while deployed ear/war in jboss 7
            prashant_mishra8

            yes

            • 3. Re: Problem while deployed ear/war in jboss 7
              nickarls

              Then you'll have to give more details on how you do the lookup/injection

              • 4. Re: Problem while deployed ear/war in jboss 7
                prashant_mishra8

                I have use the annotation to deploy the files as a web service. Below is the used annotations are :

                @Stateless(name = "IDspAllHospitalsDisplayFile", mappedName = "IDspAllHospitalsDisplayFile")

                @Remote(IDspAllHospitalsDisplayFile.class)

                @WebService(name = "IDspAllHospitalsDisplayFile", portName = "IDspAllHospitalsDisplayFilePort", serviceName = "IDspAllHospitalsDisplayFileService", targetNamespace = "urn:IDspAllHospitalsDisplayFile")

                @SOAPBinding(style = Style.DOCUMENT, use = Use.LITERAL, parameterStyle = ParameterStyle.WRAPPED)

                 

                I used spring in this project so i make a ejb3-spring.xml which have the entry below

                <jee:remote-slsb id="IDspAllHospitalsDisplayFile"

                        jndi-name="ejb:/Ab2edemoDemows/IDspAllHospitalsDisplayFile!ab2edemoDemows.logic.api.IDspAllHospitalsDisplayFile"

                        business-interface="ab2edemoDemows.logic.api.IDspAllHospitalsDisplayFile"/>

                 

                I did nothing more.

                I want to clear one thing that If I deploy this project as a .war then its work fine but when I deployed it as a .ear then it gives the error

                • 5. Re: Problem while deployed ear/war in jboss 7
                  jaikiran

                  If you are changing the packaging to .ear then the JNDI lookup string should also contain the app-name part which is missing in the config you posted. Furthermore, just use the java:global/ JNDI name syntax (which gets logged on the console when your application is being deployed) since that's portable.

                  • 6. Re: Problem while deployed ear/war in jboss 7
                    prashant_mishra8

                    to @jaikiran

                    in defined jndi-name="ejb:/Ab2edemoDemows/IDspAllHospitalsDisplayFile!ab2edemoDemows.logic.api.IDspAllHospitalsDisplayFile"

                    Ab2edemoDemows is my deployed application name

                    should I need to change any thing more?

                    • 7. Re: Problem while deployed ear/war in jboss 7
                      jaikiran

                      What does the log show for the JNDI names being bound, when your application gets deployed? Post that part here.

                      • 8. Re: Problem while deployed ear/war in jboss 7
                        prashant_mishra8

                        Below when the  .war is deployed

                         

                        15:06:38,316 INFO  [org.jboss.web] (MSC service thread 1-2) JBAS018210: Registering web context: /Ab2edemoDemows

                        15:06:38,331 INFO  [org.jboss.as] (MSC service thread 1-2) JBAS015954: Admin console is not enabled

                        15:06:38,331 ERROR [org.jboss.as] (MSC service thread 1-2) JBAS015875: JBoss AS 7.1.1.Final "Brontes" started (with errors) in 352966ms - Started 579 of 664 services (8 services failed or missing dependencies, 75 services are passive or on-demand)

                        15:06:38,409 INFO  [org.jboss.as.server] (DeploymentScanner-threads - 2) JBAS018559: Deployed "Ab2edemoDemows.war"

                        15:11:42,316 INFO  [com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource] (http--127.0.0.1-8080-1) Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 1, acquireRetryAttempts -> 5, acquireRetryDelay -> 1000, autoCommitOnClose -> true, automaticTestTable -> null, breakAfterAcquireFailure -> true, checkoutTimeout -> 0, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, dataSourceName -> 1hgeyk48t625svsg4x3y|16f2723, debugUnreturnedConnectionStackTraces -> true, description -> null, driverClass -> com.ibm.as400.access.AS400JDBCDriver, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, identityToken -> 1hgeyk48t625svsg4x3y|16f2723, idleConnectionTestPeriod -> 30000, initialPoolSize -> 0, jdbcUrl -> jdbc:as400://66.209.50.140;naming=system;libraries=AB2EDEMO X2EMDL X2EGEN QGPL QTEMP XAOBJ;transaction isolation=none;translate binary=true;prompt=false, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 300, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 5, maxStatements -> 50, maxStatementsPerConnection -> 15, minPoolSize -> 0, numHelperThreads -> 3, numThreadsAwaitingCheckoutDefaultUser -> 0, preferredTestQuery -> null, properties -> {user=******, password=******}, propertyCycle -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> false, unreturnedConnectionTimeout -> 300, usesTraditionalReflectiveProxies -> false ]

                         

                         

                        and when .ear is deployed then

                         

                        15:47:15,507 INFO  [org.jboss.as.ejb3.deployment.processors.EjbJndiBindingsDeploymentUnitProcessor] (MSC service thread 1-1) JNDI bindings for session bean named IDspfilDisplayFile in deployment unit subdeployment "Ab2edemoDemows.war" of deployment "Ab2edemoDemows.ear" are as follows:

                         

                            java:global/Ab2edemoDemows/Ab2edemoDemows/IDspfilDisplayFile!ab2edemoDemows.logic.api.IDspfilDisplayFile

                            java:app/Ab2edemoDemows/IDspfilDisplayFile!ab2edemoDemows.logic.api.IDspfilDisplayFile

                            java:module/IDspfilDisplayFile!ab2edemoDemows.logic.api.IDspfilDisplayFile

                            java:jboss/exported/Ab2edemoDemows/Ab2edemoDemows/IDspfilDisplayFile!ab2edemoDemows.logic.api.IDspfilDisplayFile

                         

                        15:47:15,507 INFO  [org.jboss.as.ejb3.deployment.processors.EjbJndiBindingsDeploymentUnitProcessor] (MSC service thread 1-1) JNDI bindings for session bean named IDspDoctorDetailDisplayRecord1Screen in deployment unit subdeployment "Ab2edemoDemows.war" of deployment "Ab2edemoDemows.ear" are as follows:

                        • 9. Re: Problem while deployed ear/war in jboss 7
                          jaikiran

                          In your ejb3-spring.xml, use this java:global/Ab2edemoDemows/Ab2edemoDemows/IDspfilDisplayFile!ab2edemoDemows.logic.api.IDspfilDisplayFile instead of the jndi-name you have specified there.

                           

                          Having said that, I don't know how any of this is related to the original exception stacktrace which talks about a completely different module name:

                           

                          No EJB receiver available for handling [appName:,modulename:pocappareaws,distinctname:] combination for invocation context

                          Perhaps you changed the names while posting here?

                          • 10. Re: Problem while deployed ear/war in jboss 7
                            prashant_mishra8

                            Your answer works for me with the .ear

                             

                            But .war is not working

                             

                            If I change in the

                            ejb3-spring.xml and use this java:global/Ab2edemoDemows/IDspfilDisplayFile!ab2edemoDemows.logic.api.IDspfilDisplayFile

                             

                            then its work for .war

                             

                            Any solution which works for both?

                             

                            thanks

                            • 11. Re: Problem while deployed ear/war in jboss 7
                              jaikiran

                              Well, if the deployment packaging changes, so does the JNDI name. You have to decide which packaging you want to use and stick to that name.

                              • 12. Re: Problem while deployed ear/war in jboss 7
                                prashant_mishra8

                                Ok thanks for your help