The JMX annotation seems a good approach at first, but when I replace the old
mbean
| <mbean code="com.arjuna.ats.jbossatx.jta.TransactionManagerService"
| name="jboss:service=TransactionManager">
| <attribute name="TransactionTimeout">300</attribute>
| <attribute
name="ObjectStoreDir">${jboss.server.data.dir}/tx-object-store</attribute>
| </mbean>
|
with the new annotated bean
| <bean name="TransactionManager"
class="com.arjuna.ats.jbossatx.jta.TransactionManagerService">
|
<annotation>@org.jboss.aop.microcontainer.aspects.jmx.JMX(name="jboss:service=TransactionManager",
exposedInterface=com.arjuna.ats.jbossatx.jta.TransactionManagerServiceMBean.class,
registerDirectly=true)</annotation>
|
| <property name="TransactionTimeout">300</property>
| <property
name="ObjectStoreDir">${jboss.server.data.dir}/tx-object-store</property>
| </bean>
|
then the dependent mbeans e.g.
| <mbean code="org.jboss.invocation.unified.server.UnifiedInvoker"
| name="jboss:service=invoker,type=unified">
| <depends>jboss:service=TransactionManager</depends>
| <depends>jboss.remoting:service=Connector,transport=socket</depends>
| </mbean>
fail to find the service they depend on:
| ...
| 14:01:46,883 INFO [JMXKernel] Legacy JMX core initialized
| 14:01:59,184 INFO [WebService] Using RMI server codebase:
http://127.0.0.1:8083/
| 14:02:01,913 ERROR [ProfileServiceBootstrap] Failed to load profile:
Summary of incomplete deployments (SEE PREVIOUS ERRORS FOR DETAILS):
|
| *** CONTEXTS MISSING DEPENDENCIES: Name -> Dependency{Required State:Actual
State}
|
| jboss:service=invoker,type=jrmp
| -> jboss:service=TransactionManager{Start:** NOT FOUND **}
| -> jboss:service=TransactionManager{Create:** NOT FOUND **}
| ...
| *** CONTEXTS IN ERROR: Name -> Error
|
| jboss:service=TransactionManager -> ** NOT FOUND **
|
Perhaps the annotation is being processed at a later stage of the lifecycle so
it's not yet present when the mbean dependencies go to look for it?
Anyhow, it seems there are issues with interop between the old mbean style and
the new bean style. My options at this point seem equally unpalatable: either
link the transactions code again some new AS library (lots of work with no
apparent advantage over the existing situation of linking against
ServiceMBeanSupport) or convert everything that depends on the transaction
manager from mbeans to beans also, transitively. I vote for option 3: do
nothing. ServiceMBeanSupport works ok, why bother with this new MC stuff?
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4114219#4114219
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4114219
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user