"jhalliday" wrote : Fair enough. So I can't do much of my setup in the
service constructor, as I don't have the information yet at that time. I need to do
the work in the start method instead. That's actually less effort for me, as it's
how things currently work.
|
btw: what's stopping you from using MC beans instead of mbeans, if you're already
migrating
"jhalliday" wrote :
| The problem with that is: many other services depend on the transaction manager. As
far as I can tell, under the old pre-MC semantics, depends meant 'ensure the other
service has started'. As a result, work the transaction manager does in the start
method would be finished before anything that depends on it was executed. Under MC,
depends seems to mean 'ensure the service I depend on has reached at least the same
point in the lifecycle as the one I'm transitioning to' by default.
|
Previous depend was/is like this:
A depends on B --> B created, then A could be created, B started, A could start
And this is still the same:
From ServiceDependencyMetaData
| visitor.addDependency(new LifecycleDependencyItem(name, other,
ControllerState.CREATE));
| visitor.addDependency(new LifecycleDependencyItem(name, other,
ControllerState.START));
|
From MC's AbstractDependencyMetaData
| DependencyItem item = new LifecycleDependencyItem(context.getName(),
ControllerState.CREATE);
| visitor.addDependency(item);
| item = new LifecycleDependencyItem(context.getName(), ControllerState.START);
| visitor.addDependency(item);
|
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4108852#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...