The state machine was not immeadiately for the service layer, but will be used to enforce illegal transitions if we decide on a state diagram.
The suggested change makes sense, but the other problem is the fact
that the deployment layer is out of the loop in this. I would like
to couple dependency and life cycle to delay the creation of the
service as an mbean, but have not really looked at how big a change
this is.
xxxxxxxxxxxxxxxxxxxxxxxx
Scott Stark
Chief Technology Officer
JBoss Group, LLC
xxxxxxxxxxxxxxxxxxxxxxxx
> -----Original Message-----
> From: Adrian Brock
> Sent: Saturday, March 06, 2004 5:24 PM
> To: Scott M Stark
> Cc: [EMAIL PROTECTED]; The Core
> Subject: Service Lifecyle confusions - potential fix
>
> Hi Scott,
>
> Are you working on the Service lifecycle?
> I saw you replaced common's state machine implementation.
>
> I was thinking that there should be an extra indirection to
> avoid the confusion caused by people clicking stop() and
> other operations in the console where dependencies are not
> taken into account.
>
> My idea is that you implement an extra operation in
> ServiceMBeanSupport
>
> public void jbossServiceLifecylce(String operation) throws
> Exception { if (operation.equals("create")) { // the current
> create() method } etc.
> }
>
> This would be invoked from ServiceController.ServiceProxy
> when it is implemented by the MBean.
>
> This would allow us to change the current
> ServiceMBeanSupport.create() to be:
> serviceController.create(serviceName);
> etc.
>
> Now clicking stop() in the console goes via the service
> controller making sure dependencies are also stopped.
>
> This doesn't fix the problem for MBeans that do not extend
> ServiceMBeanSupport. These would still do the old behaviour.
> Similar changes would be required to
> ServiceDynamicMBeanSupport and the XMBean descriptor include.
>
> Regards,
> Adrian
>
> --
> xxxxxxxxxxxxxxxxxxxxxxxx
> Adrian Brock
> Director of Support
> Back Office
> JBoss Inc.
> xxxxxxxxxxxxxxxxxxxxxxxx
>
>
>
smime.p7s
Description: S/MIME cryptographic signature
