6 Replies Latest reply on Feb 20, 2009 11:28 AM by Adrian Brock

    The deployers project is a mess

    Adrian Brock Master

      A lot of the tests are failing when I use eclipse again.
      Including the EAR annotation tests which I think you've already fixed twice before?

      They work fine in Maven. This hints to me that you are doing things that are not portable
      or making invalid assumptions.

      I just did a fix for version 2.0.5.GA. 2.0.4.GA has already been released.
      But there wasn't even a JIRA version for 2.0.4.GA?

      I'm pretty sure there are other fixes in 2.0.5.GA that don't have JIRA issues
      since I've seen a lot of changes to the deployers flying past lately.

      But unless you're willing to query SVN you'd have no idea what changes are in the release(s).

        • 1. Re: The deployers project is a mess
          Ales Justin Master

          Yeah, I know. :-(
          About the mess, no clue about the failing EAR test.

          I'll do things properly at the start of next week.
          Properly == JIRA, merge branches, concrete versions, ...

          The VFS was even a bigger mess,
          hence I had no idea in advance what all must be fixed/changed.
          And this all dragged to Deployers, which are VFS biggest "customer".

          I'll ping you to re-check those tests once I'm done, OK?

          • 2. Re: The deployers project is a mess
            Adrian Brock Master

             


            Can you check now, with exact versions, if this EAR stuff still fails?

            adrian@jboss.org wrote:
            > A lot of the tests are failing when I use eclipse again.
            > Including the EAR annotation tests which I think you've already fixed twice before?


            Can't you just download a copy of eclipse and try it yourself?

            For example in deployers trunk if I run
            org.jboss.test.deployers.DeployersVFSTestSuite.java
            I get four failures, the EAR one gives the error
            junit.framework.AssertionFailedError: Expected [appc.jar, ejbs.jar, web.jar, services.jar] got [] expected:<4> but was:<0>
             at junit.framework.Assert.fail(Assert.java:47)
             at junit.framework.Assert.failNotEquals(Assert.java:277)
             at junit.framework.Assert.assertEquals(Assert.java:64)
             at junit.framework.Assert.assertEquals(Assert.java:195)
             at org.jboss.test.deployers.vfs.structure.AbstractStructureTest.assertChildContexts(AbstractStructureTest.java:80)
             at org.jboss.test.deployers.vfs.structure.ear.test.EARStructureUnitTestCase.testEARAnnotationScanning(EARStructureUnitTestCase.java:143)
            


            • 3. Re: The deployers project is a mess
              Adrian Brock Master

              Adding a bit more logging shows this output;

              365 TRACE [VFSStructuralDeployersImpl] Determining structure for ejbs.jar deployers=[org.jboss.deployers.vfs.plugins.structure.war.WARStruct
              ure@1ea0252, org.jboss.test.deployers.vfs.structure.ear.support.MockEarStructureDeployer@1c695a6, org.jboss.deployers.vfs.plugins.structure.
              jar.JARStructure@3e89c3, org.jboss.deployers.vfs.plugins.structure.file.FileStructure@1a52fdf]
              366 TRACE [WARStructure] ... no - doesn't look like a war and no WEB-INF subdirectory.
              366 TRACE [WARStructure] Not recognised: ejbs.jar
              366 TRACE [JARStructure] ... ok - its an archive or at least pretending to be
              375 TRACE [JARStructure] ... candidate annotations returned false
              375 TRACE [JARStructure] Not recognised: ejbs.jar
              375 TRACE [FileStructure] ... no - not a file.
              375 TRACE [FileStructure] Not recognised: ejbs.jar
              376 TRACE [VFSStructuralDeployersImpl] ejbs.jar not recognised
              


              So its not finding the annotations in JARStructure.

              • 4. Re: The deployers project is a mess
                Adrian Brock Master

                Well this appears to be eclipse thing.

                There's an "exclude" on copying *.java to test-classes which also stops .class files
                getting copied.

                This changed by Kabir, previously it just used the src/resources as a library folder
                directly.

                But if I change it back to be a library folder the AbstractSchemaResolver tests fail because there's now two folders with the same name and getResource() is choosing the
                wrong one.

                 String common = "/org/jboss/test/deployers/vfs/xb/test";
                 URL url = getClass().getResource(common);
                


                • 5. Re: The deployers project is a mess
                  Adrian Brock Master

                   

                  "adrian@jboss.org" wrote:
                  Well this appears to be eclipse thing.


                  It definitely needs more trace logging in this area.
                  I should be able to understand why the candidate structure failed from the TRACE logging.
                  I shouldn't have to modify code to understand why it is failing to find classes
                  (in this case looking a different place to where I expected).

                  • 6. Re: The deployers project is a mess
                    Adrian Brock Master

                     

                    "adrian@jboss.org" wrote:
                    Well this appears to be eclipse thing.

                    There's an "exclude" on copying *.java to test-classes which also stops .class files
                    getting copied.

                    This changed by Kabir, previously it just used the src/resources as a library folder
                    directly.

                    But if I change it back to be a library folder the AbstractSchemaResolver tests fail because there's now two folders with the same name and getResource() is choosing the
                    wrong one.

                     String common = "/org/jboss/test/deployers/vfs/xb/test";
                     URL url = getClass().getResource(common);
                    


                    I've reverted this back to a class folder for src/test/resources and moved
                    the jbossxb "deployments" into a seperate unique folder.
                    Now the tests run in both eclipse and maven.