3 Replies Latest reply on Jul 19, 2005 8:51 AM by yxyang

    war, ear or sar?

      Hi

      Starting from helloworld.war example, i have some ejbs which will be used in the portlets, should i archive them as an ear or sar file? Or one jar and one war?

      Thanks

      Yang

        • 1. Re: war, ear or sar?
          • 2. Re: war, ear or sar?

            ear containing war and ejb jar will do it

            • 3. Re: war, ear or sar?

              I did a test and the result shows that ear containing war and jar doesn't work.
              I suspected that it is due to the context root confliction, because there is a jboss-app.xml and context.xml in the jbossportal core already.

              What i did was to deploy jar file directly. Portlets in war use jndi lookup by using local-ejb-ref tag in the jboss-web.xml. It works. But there is a strange problem related to the classloader:

              If the war file includes the interface classes of the ejbs in its lib directory, there will be a classloader exception. But if i remove the ejbs interfaces from its lib directory, it works.

              In my understanding, i expected that the ejb interfaces should be included in the lib directory. Is this true?

              Regards
              Yang