Well, obviously I did send that to the list, so, here's a follow up...

I thought there was a bug, but, there's not... just a misunderstanding on my
part.  This is a bit long, but, hopefully it will resolve some of the
questions about client libraries and those dreaded ClassNotFound exceptions.

Using the example from http://www.jboss.org/documentation/HTML/ch10s71.html,
an EAR file is structured as:

   META-INF/
   META-INF/MANIFEST.MF
   META-INF/application.xml
   ejb-app.jar
   web-app.war
   lib/
   lib/ejb-client.jar

and a MANIFEST.MF looks like:

   Manifest-Version: 1.0
   Class-Path: ./lib/ejb-client.jar

At first glance, it would seem that the manifest files that contains the
./lib/ejb-client.jar line is the one for the EAR.  However, the docs state
in the footnote that it is not... it's one for a ejb or war archive.

If you were like me, you were putting your jars in lib/, creating a manifest
like the one above, and specifying it when you create your ear.  But, that's
not at all correct. For example, this ant task for creating my ear is wrong:

    <jar jarfile="${dist.home}/${dist.ear}"
         manifest="etc/app.mf"
         basedir="${deploy.home}"
         includes="${dist.war},ejb-client.jar,META-INF/application.xml"
    />

The EAR is created just fine and deploys just fine, but JBoss doesn't parse
the manifest for the EAR so it doesn't add the jars in ./lib/ as you would
have expected.  JBoss does, however, parse the manifest for any included
jars/wars in your EAR.  So, the thing to do (as the footnote says) is to
specify your jars in the manifest for one of those.  To me, it's a bit
counter-intuitive... but, there you go.

I hope this helps... if not, keep asking, we'll eventually get it.

Best Regards,

Dewayne

----- Original Message -----
From: "Dewayne McNair" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, April 20, 2001 9:09 PM
Subject: Re: [JBoss-user] Tomcat-JBoss ClassNotFoundException (again)


> [I didn't copy this to the list on purpose...]
>
> I think there is a bug in the deployer... I'm looking through the source
> code now, I'll let you know if I find anything.
>
> Just for reference, can you send me a description of your EAR?
>
> Thanks,
>
> Dewayne
>
> ----- Original Message -----
> From: "Bill Pfeiffer" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Friday, April 20, 2001 8:14 PM
> Subject: Re: [JBoss-user] Tomcat-JBoss ClassNotFoundException (again)
>
>
> > I should have been more explicit when discussing what I've tried.  I've
> > reviewed the j2ee deployment steps as well as the Tomcat how-to.  After
> > walking through the explicit steps of both documents and experiencing
> > failure, I looked for subtleties that I may have missed, tried
variations.
> > More failure.
> >
> > Then there is the tomcat-test.ear, which I watch work every time.  I
> modeled
> > my deployment exactly after this in at least one of my varied attempts
and
> > failed.  Note that this tomcat-test.ear actually includes the ejb
> interface
> > classes in the WAR file (I've tried this), as well as providing a client
> jar
> > containing those files in the ear file(also tried that).  This inclusion
> of
> > classes directly into the WAR's "classes" dir is not indicated in the
j2ee
> > deployment guide nor in the j2ee spec that I've seen.
> >
> > Do you actually have a non-trivial (something other than the
> > tomcat-test.ear) j2ee application deployed and working?  It would
> certainly
> > give me hope to keep plugging along.
> >
> >
> > Bill Pfeiffer
> >
> >
> > ----- Original Message -----
> > From: "Victor Lan" <[EMAIL PROTECTED]>
> > To: <[EMAIL PROTECTED]>
> > Sent: Friday, April 20, 2001 12:17 AM
> > Subject: Re: [JBoss-user] Tomcat-JBoss ClassNotFoundException (again)
> >
> >
> > > In addition to the tomcat+jboss howto, you should read the "Deployment
> > > on JBoss" section.
> > >
> > > Also, get the tomcat-test.ear app from the contrib suite to see how
it's
> > > done.
> > >
> > > It does work.
> > >
> > > Victor
> > >
> > > ----- Original Message -----
> > > From: "Bill Pfeiffer" <[EMAIL PROTECTED]>
> > > Date: Thursday, April 19, 2001 11:37 pm
> > > Subject: [JBoss-user] Tomcat-JBoss ClassNotFoundException (again)
> > >
> > > > Has anyone successfully deployed a non trivial .ear (ie something
> > > > other than
> > > > the example ear) under the integrated Tomcat-JBoss binary?
> > > >
> > > > I've read the docs.  I've reviewed the working sample.  I've tried
> > > > whatseems to be every concievable permutation of .jcml, .conf,
> > > > manifest settings
> > > > that I can come up with.  I cannot get the damn thing (my servlet)
> > > > to see my
> > > > home interface class file.  It throws a ClassNotFoundException
> > > > every time.
> > > >
> > > > Offer me a setting.  I'll try it (if I haven't already).  Tell me
> > > > where to
> > > > put my ejb interface files (in or out of a client.jar, doesn't
> > > > matter, I've
> > > > tried it).
> > > >
> > > > Any last words of advice before I give up?  I'd love to hear from
> > > > someonewho has this working and see the configuration.
> > > >
> > > > Thanks,
> > > >
> > > > Bill Pfeiffer
> > > >
> > > >
> > > > _______________________________________________
> > > > JBoss-user mailing list
> > > > [EMAIL PROTECTED]
> > > > http://lists.sourceforge.net/lists/listinfo/jboss-user
> > > >
> > >
> > >
> > > _______________________________________________
> > > JBoss-user mailing list
> > > [EMAIL PROTECTED]
> > > http://lists.sourceforge.net/lists/listinfo/jboss-user
> >
> >
> > _______________________________________________
> > JBoss-user mailing list
> > [EMAIL PROTECTED]
> > http://lists.sourceforge.net/lists/listinfo/jboss-user
> >
>






_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to