This is because the unit of work is the individual deployment.  The
URLDeploymentScanner finds your -service.xml file, passes it to the
MainDeployer, who passes it to the SARDeployer.  SARDeployer tells
ServiceController to instantiate and configure all mbeans declared in
the file.  Then it tells ServiceController to create them.  At that
point, the ServiceController resolves all dependencies it's aware of; if
there are no unsatisfied dependencies it creates the mbeans, and creates
any other mbeans *it is currently aware of* whose dependencies are now
satisfied.  Then the SARDeployer tells ServiceController to start all
mbeans declared in the file.  Same process of dependency resolution
occurs.

Any services in other files the URLDeploymentScanner hasn't processed
yet don't factor in the process.

Will this be different with the Profile Service?  I.e. will the "unit of
work" be the entire profile, such that all services in the profile can
count on:

ServiceA.createService();
ServiceB.createService();
ServiceA.startService();
ServiceB.startService();

[EMAIL PROTECTED] wrote:
> According to the wiki page at
> http://wiki.jboss.org/wiki/Wiki.jsp?page=ServiceLifecycle ,
> the service lifecycle for two Services A and B is as follows.
> 
> If Service B is dependent on Service A, the startup sequence
> is the following.
> ServiceA.createService();
> ServiceB.createService();
> ServiceA.startService();
> ServiceB.startService();
> 
> It appears that this is only true if Service A and Service B
> are defined in the same service file.  If the services are
> defined in different files, the startup sequence is the following.
> ServiceA.createService(); ServiceA.startService();
> ServiceB.createService();
> ServiceB.startService();
> 
> Obviously this difference is significant for any service that
> needs to be created before the primary service is started.
> Is this intentional (or am I overlooking something)?  I
> haven't found any reference to this behavior in JBoss doc.


-------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid0709&bid&3057&dat1642
_______________________________________________
JBoss-Development mailing list
JBoss-Development@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to