13 Replies Latest reply on Oct 12, 2009 8:42 AM by rasa

    Jboss 4.2.3 GA upgrade

    rasa

      Hi,

      I have a java application which uses 1.5 jdk and i am trying to configure jboss 4.2.3 GA in a windows xp machine. I am not using embeded tomcat which is avaialble with jboss. While starting jboss by clicking the bat file ( through commnad prompt run.bat it is not executing ). i am getting one error

      at java.lang.Thread.run(Thread.java:595)
      11:29:39,406 ERROR [MainDeployer] Could not create deployment: file:/E:/jboss-4
      2.3.GA/jboss-4.2.3.GA/server/default/deploy/application.jar
      org.jboss.deployment.DeploymentException: Verification of Enterprise Beans fail
      d, see above for error messages.
       at org.jboss.ejb.EJBDeployer.create(EJBDeployer.java:610)
       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
       at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl
      java:39)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcce
      sorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:592)
       at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatc
      er.java:155)
       at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
       at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractIntercep
      or.java:133)


        • 1. Re: Jboss 4.2.3 GA upgrade
          peterj

          Looks like you posted the second stack trace (the end of the prior stack trace is the first line youy posted). Please post the first stack trace. You might have to increase the command prompt buffer size to prevent the stack trace from overflowing the buffer (I set mine to 9000 lines). Also, I recommend opening a command prompt, cding to the jboss_home/bin directory and running run.bat from there.

          Anyway, there is something wrong with your application.jar file, but the first exception stack trace should point it out.

          • 2. Re: Jboss 4.2.3 GA upgrade
            rasa

            I have started now it is from cmd using run.bat. One jar file was missing and that i have added in lib of default directory. See the error

            
            12:33:47,984 ERROR [MainDeployer] Could not create deployment: file:/E:/jboss-4.
            2.3.GA/jboss-4.2.3.GA/server/default/deploy/application.jar
            org.jboss.deployment.DeploymentException: Verification of Enterprise Beans faile
            d, see above for error messages.
             at org.jboss.ejb.EJBDeployer.create(EJBDeployer.java:610)
             at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
             at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
            java:39)
             at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
            sorImpl.java:25)
             at java.lang.reflect.Method.invoke(Method.java:592)
             at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatch
            er.java:155)
             at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
             at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractIntercept
            or.java:133)
             at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
             at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelM
            BeanOperationInterceptor.java:142)
             at org.jboss.mx.interceptor.DynamicInterceptor.invoke(DynamicInterceptor
            .java:97)
             at org.jboss.system.InterceptorServiceMBeanSupport.invokeNext(Intercepto
            rServiceMBeanSupport.java:238)
             at org.jboss.wsf.container.jboss42.DeployerInterceptor.create(DeployerIn
            terceptor.java:76)
             at org.jboss.deployment.SubDeployerInterceptorSupport$XMBeanInterceptor.
            create(SubDeployerInterceptorSupport.java:180)
             at org.jboss.deployment.SubDeployerInterceptor.invoke(SubDeployerInterce
            ptor.java:91)
             at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
             at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.
            java:264)
             at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
             at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
             at $Proxy32.create(Unknown Source)
             at org.jboss.deployment.MainDeployer.create(MainDeployer.java:969)
             at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:818)
             at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:782)
             at sun.reflect.GeneratedMethodAccessor20.invoke(Unknown Source)
             at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
            sorImpl.java:25)


            In my application i amusing ejb2.0 and java 1.5. Is it because of this.

            Please give a suggestion.

            Regards
            Rasa.

            • 3. Re: Jboss 4.2.3 GA upgrade
              peterj

              Are you sure this is the first error message? The text of this error states that there were prior errors.

              • 4. Re: Jboss 4.2.3 GA upgrade
                rasa

                 

                "PeterJ" wrote:
                Are you sure this is the first error message? The text of this error states that there were prior errors.


                Yes this are the first errors. But before that i am getting some warnings.

                Bean : AppsCache
                Method : public abstract String getMenuPath(String) throws Exception
                Section: 7.10.5
                Warning: The methods in the remote interface must include java.rmi.RemoteException in their throws clause.
                
                12:48:18,171 WARN [verifier] EJB spec violation:
                Bean : ManualUpdateFacade
                Section: 22.2
                Warning: The Bean Provider must specify the fully-qualified name of the Java class that implements the enterprise bean's business methods in the <ejb-class> element.
                Info : Class not found on 'com.apps.ejb.manager.EmployeeFacadeEJB': No ClassLoaders found for: com.apps.ejb.manager.EmployeeFacadeEJB
                
                12:48:18,171 WARN [verifier] EJB spec violation:
                Bean : ApplicationFacade
                Method : public abstract ApplicationFacadeLocal create() throws CreateException
                Section: 7.10.8
                Warning: All the exceptions defined in the throws clause of the matching ejbCreate(...) method of the enterprise bean class must be included in the throws clause of a matching create(...) method.
                
                


                But the same code is working in jboss 3.2.5

                • 5. Re: Jboss 4.2.3 GA upgrade
                  peterj

                  JBoss AS 5 tends to be more picky about apps following that specs that what earlier releases were. The above warning tell you what the issues are - you'll have to fix them.

                  • 6. Re: Jboss 4.2.3 GA upgrade
                    rasa

                     

                    "PeterJ" wrote:
                    JBoss AS 5 tends to be more picky about apps following that specs that what earlier releases were. The above warning tell you what the issues are - you'll have to fix them.


                    JBoss AS 5 means what?? i am using 4.2.3 GA.

                    Regards
                    Rasa

                    • 7. Re: Jboss 4.2.3 GA upgrade
                      jaikiran

                       

                      "rasa" wrote:
                      JBoss AS 5 means what?? i am using 4.2.3 GA.


                      Apart from the AS 5 part, the rest of the things Peter said, still apply:

                      "PeterJ" wrote:
                      The above warning tell you what the issues are - you'll have to fix them.


                      The WARN message that you posted, are clear enough and they tell you what the exact problems are with those beans.

                      • 8. Re: Jboss 4.2.3 GA upgrade
                        rasa

                        But the same warning is there in 3.2.5 version of jboss. And in that it is working fine

                        • 9. Re: Jboss 4.2.3 GA upgrade
                          rasa

                          Hi,

                          Now i have changed my jar to application.ear

                          ERROR [MainDeployer] Could not create deployment: file:/E:/jboss-4.2.3.GA/jboss-4.2.3.GA/server/default/tmp/deploy/tmp1936660721363467076application.ear-contents/application.jar


                          Any idea ???


                          Rasa.

                          • 10. Re: Jboss 4.2.3 GA upgrade
                            jaikiran

                             

                            "rasa" wrote:

                            Now i have changed my jar to application.ear


                            Why? :)

                            "rasa" wrote:

                            Any idea ???




                            We have been telling you that the real problem is in the code of the application that is deployed. The code is not following the spec. The WARN message tell you the exact issues with the app. The code needs to be fixed.

                            But the same warning is there in 3.2.5 version of jboss


                            Again, we have told you that earlier versions of JBoss were lenient if the application violated the spec. In AS-4.x you can workaround this by setting the "StrictVerifier" to false in JBOSS_HOME/server/< servername>/deploy/ejb-deployer.xml:

                            <!-- Setting this to 'true' will cause all deployments
                             to fail when the Verifier detected a problem with the contained
                             Beans. If false, warnings/errors will be logged but the deployment
                             will not fail.
                             -->
                             <attribute name="StrictVerifier">false</attribute>
                            


                            But again this is just a workaround and you never know if this will be supported in later versions. The best way is to fix the application.


                            • 11. Re: Jboss 4.2.3 GA upgrade
                              rasa

                              in 3.2.5 verson standardjboss.xml version i have seen one entry like this
                              <enforce-ejb-restrictions>false</enforce-ejb-restrictions>. But in the new version it is not there.

                              • 12. Re: Jboss 4.2.3 GA upgrade
                                jaikiran

                                 

                                "rasa" wrote:
                                in 3.2.5 verson standardjboss.xml version i have seen one entry like this
                                <enforce-ejb-restrictions>false</enforce-ejb-restrictions>. But in the new version it is not there.


                                Did you read my previous reply?

                                • 13. Re: Jboss 4.2.3 GA upgrade
                                  rasa

                                   

                                  JBoss AS 5 tends to be more picky about apps following that specs that what earlier releases were. The above warning tell you what the issues are - you'll have to fix them.


                                  Yes this is right. As perter said the issue is with application only. But for that no need to fix anything in application.
                                  do the following
                                  in deploye/jjb-deploy.xml change the value of attribute Strictverifier to false.

                                  Thanks and Regards
                                  Rasa.