On Thu, Mar 08, 2001 at 07:14:19AM -0600, Dan Kearns wrote:
> > I think that the best way is to create a separate jar containing the
> classes
> > needed by a client and include that as a library in your EAR. Or, if the
> > resource adapter is meant to be available to all applications, include it
> in
> > lib/ext.
> >
> > Another option would be to have a JBoss-specific extension whereby you
> > nominate a jar in your RAR as the client jar and that gets made
> > available to the rest of the EAR.
> 
> cool, it's the  dr. seuss aproach "there's a jar in your rar, so we know
> where they are"
> 
> I think I like the latter way a little better since the rar then doesn't
> depend on a specific ear being deployed. Even if it is non-standard, It
> would seem logical to have something like a lib/shared.jar inside the rar,
> and maybe a corresponding classpath entry in the manifest.

I'm not sure what the spec is trying to say when it says:

  The deployer should ensure that all the JAR files (packaged within
  the resource adapter module) are loaded in the operational environment.

This might mean that all of the classes in your RAR should be accessible
by other modules in the application. I'll check on the connector list.

> Tying the shared files to a particular ear probably wouldn't be so useful -
> for example with the blackbox adapter, you wouldn't want to (and possibly
> couldn't) implement the jdbc datasource interface again as a session bean
> and force people to go through that when you already have the interface you
> want right in the adapter itself.

I'm not sure what you mean by "implement the jdbc datasource interface
again as a session bean". If the resource adpater is only meant to be
used by one application, then I think it makes good sense to only have
the classes available to that application.

> Would it make sense to have to declare the shared classes (or the adapter
> itself) as some kind of resource in jboss.xml for the ears? Would there be a
> way of sucking in the rar's classloader as the immediate parent for the
> ear's classloader?

If you want to have a RAR that's usaeable by all applications, then I
think the way to do that is to effectively deploy the RAR in a sort of
global appilcation and then introduce the concept of application inheritance,
at least for classloading. Every deployed application would have the
global application as a parent (or grandparent etc) and would be able
to load classes from it.

Toby.


--
--------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]

Reply via email to