Bugs item #520676, was opened at 2002-02-20 14:04
You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=376685&aid=520676&group_id=22866

Category: JBossServer
Group: v3.0 Rabbit Hole
>Status: Closed
>Resolution: Fixed
Priority: 5
Submitted By: David Jencks (d_jencks)
Assigned to: David Jencks (d_jencks)
Summary: All classes need to be loaded first.

Initial Comment:
We are currently ignoring manifest class path entries
in jars in ears at our peril.

If an ear contains 2 jars, say a.jar and b.jar, and b's
manifest classpath refers to a.jar, b can expect the
classes from a to be available when it is deployed. 
This currently doesn't happen: a and b can be deployed
in a random order.

I think there may be similar problems with ejb-refs to
ejb's in not-yet-deployed jars, but I'm not sure.

To fix this, we could:

1. Pay more attention to the manifest classpath, and
find where the referred to jars actually are placed by
the deployment process.  I think we would have to go to
some effort to prevent deploying jars on a manifest
classpath twice.

or

2. Restructure the deployment process to have 3 stages:

a. unpack everything and add it to classloaders.

b. make a first pass, constructing everything and
calling "create" on it.  The intent is to configure
everything that a component offers to the outside
world, without itself referring to the outside world.

c. make a second pass, setting up relationships with
other deployed objects.  For instance, this is when an
ejb's local naming environment would be set up.

I think (2) would work just as well as (1) without
requiring setting up the manifest classpaths.  It would
I think also be more friendly to circular relationships
and generalizations to other deployment packaging.

I'd like some opinions before I set about fixing this.

Thanks
david jencks

(this problem was brought to my attention by Stephen
Davidson)

----------------------------------------------------------------------

>Comment By: David Jencks (d_jencks)
Date: 2002-02-21 20:32

Message:
Logged In: YES 
user_id=60525

I have fixed this by dividing deployment into 3 stages:

1. init: subpackages are determined and all classes are loaded.

2. create: subpackages set up aspects of their components
that are visible to the outside world.  They DO NOT refer to
anything outside themselves.

3. start: subpackages connect with other components' visible
interfaces, such as jndi bindings.

This closely mirrors the previous
SARDeployer/ServiceController deployment scheme: this is now
extended to all deployers.

I included a testcase (jmx/eardeployment) to demonstrate
that classes in every jar in an ear are visible to other
jars at the "create" step.

----------------------------------------------------------------------

You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=376685&aid=520676&group_id=22866

_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to