-
1. Re: Evaluating IOC Containers
bkeh12 Mar 7, 2006 9:20 AM (in response to deaddowney)6. JMX interface for deployed components if desired
http://jira.jboss.com/jira/secure/IssueNavigator.jspa?reset=true&mode=hide&sorter/order=DESC&sorter/field=priority&resolutionIds=-1&pid=12310060&fixfor=12310587
7. Special Classloader to find jars in a specified directory so that startup scripts are minimal
http://jira.jboss.com/jira/secure/IssueNavigator.jspa?reset=true&mode=hide&sorter/order=DESC&sorter/field=priority&resolutionIds=-1&pid=12310060&fixfor=12310391 -
2. Re: Evaluating IOC Containers
eknathkadam Feb 27, 2007 3:31 AM (in response to deaddowney)"bkeh12" wrote:
6. JMX interface for deployed components if desired
http://jira.jboss.com/jira/secure/IssueNavigator.jspa?reset=true&mode=hide&sorter/order=DESC&sorter/field=priority&resolutionIds=-1&pid=12310060&fixfor=12310587
I clicked this link but found nothing, any update on point 6 ? -
3. Re: Evaluating IOC Containers
alesj Feb 27, 2007 5:04 AM (in response to deaddowney)"eknathkadam" wrote:
"bkeh12" wrote:
6. JMX interface for deployed components if desired
http://jira.jboss.com/jira/secure/IssueNavigator.jspa?reset=true&mode=hide&sorter/order=DESC&sorter/field=priority&resolutionIds=-1&pid=12310060&fixfor=12310587
I clicked this link but found nothing, any update on point 6 ?
Yes.
It is there for a while now.
Already used with JBoss5 clustering support.
See this issues:
- JMXDecoratedTestCase in MC testing
- http://www.jboss.org/index.html?module=bb&op=viewtopic&t=94154&start=0
- http://www.jboss.org/index.html?module=bb&op=viewtopic&t=102792 -
4. Re: Evaluating IOC Containers
vickyk Feb 27, 2007 5:38 AM (in response to deaddowney)org.jboss.aop.advice.AdviceBinding binding = new AdviceBinding("execution(POJO->new(..))", null); binding.addInterceptor(SimpleInterceptor.class); AspectManager.instance().addBinding(binding);
All we need to do is to have the above code formed through the xml file when using the MC . Am I right ?
And logically the Interceptor will
1) Read the annotation data of the POJO .
2) Get the MBeanServer .
3) Register the POJO in the MBeanServer .
Am I missing something here ? -
5. Re: Evaluating IOC Containers
alesj Feb 27, 2007 6:02 AM (in response to deaddowney)"vickyk" wrote:
All we need to do is to have the above code formed through the xml file when using the MC . Am I right ?
Yes, see how this is done in JMXDecoratedTestCase.(java|xml).
And this can be simplified now - less aop xml code. -
6. Re: Evaluating IOC Containers
alesj Feb 27, 2007 6:21 AM (in response to deaddowney)"alesj" wrote:
And this can be simplified now - less aop xml code.
See JMXLifecycleTestCase.xml. -
7. Re: Evaluating IOC Containers
eknathkadam Feb 28, 2007 12:55 AM (in response to deaddowney)I believe all this JMX support is for microcontainer that is supplied with Jboss5, I think the MC release is 2.0, is there any JMX support in prior release, the one supplied with Jboss 4.x (release 1.0, I guss.) ?
-
8. Re: Evaluating IOC Containers
alesj Feb 28, 2007 2:55 AM (in response to deaddowney)Can you look if KernelControllerContextAware interface is present with v1.0?
-
9. Re: Evaluating IOC Containers
alesj Feb 28, 2007 3:05 AM (in response to deaddowney)Or you can always add a MBean Exporter kind of bean.
Inject MBean server bean into it and all the beans that you want to export (along with ObjectName and exposed interface info).
There is no 'exporter' impl within MC, but you can probably use this one (with slight modifications) http://www.springframework.org/docs/api/org/springframework/jmx/export/MBeanExporter.html. -
10. Re: Evaluating IOC Containers
eknathkadam Feb 28, 2007 5:25 AM (in response to deaddowney)"alesj" wrote:
Can you look if KernelControllerContextAware interface is present with v1.0?
Yes, it is present with v1.0 -
11. Re: Evaluating IOC Containers
alesj Feb 28, 2007 5:33 AM (in response to deaddowney)Ok, I had some idea, but it is far uglier than the one with exporter.
Never mind about KCCA in v1.0.
Try with exporter.
Or what's the problem updating MC to v2.0(beta)? -
12. Re: Evaluating IOC Containers
eknathkadam Feb 28, 2007 8:00 AM (in response to deaddowney)Thanks for the response.
Eventually we would start using v2.0, but that also means Jboss5, for which we will have to wait for sometime untill GA is out. -
13. Re: Evaluating IOC Containers
alesj Feb 28, 2007 8:04 AM (in response to deaddowney)JBoss5_Beta2 is about to be released.
MC features are quite polished there.
Or maybe you can port MC v2.0 to replace v1.0 in JBoss4. -
14. Re: Evaluating IOC Containers
vickyk Feb 28, 2007 3:30 PM (in response to deaddowney)"alesj" wrote:
"vickyk" wrote:
All we need to do is to have the above code formed through the xml file when using the MC . Am I right ?
Yes, see how this is done in JMXDecoratedTestCase.(java|xml).
And this can be simplified now - less aop xml code.
After looking into the JMXDecoratedTestCase I have found this<beanfactory name="MetaDataContextAdvice" class="org.jboss.test.microcontainer.support.MetaDataContextInterceptor"> <property name="annotation">org.jboss.aop.microcontainer.aspects.jmx.JMX</property> </beanfactory>
What does this precisely do ?
I have prepared a POJO , I have prepared a jar of that and dropped in the server/default/lib as pojo.jar . The pojo.jar contains the required POJO .
The step where I am getting stuck is how to configure the pojo-beans.xml for the POJO
I am not able to understand what to have instead of this<beanfactory name="MetaDataContextAdvice" class="org.jboss.test.microcontainer.support.MetaDataContextInterceptor"> <property name="annotation">org.jboss.aop.microcontainer.aspects.jmx.JMX</property> </beanfactory>
Here goes my pojo-beans.xml contents<?xml version="1.0" encoding="UTF-8"?> <!-- deployment xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="urn:jboss:bean-deployer bean-deployer_2_0.xsd" xmlns="urn:jboss:bean-deployer:2.0" --> <deployment xmlns="urn:jboss:bean-deployer:2.0"> <!-- bean name="AspectManager" class="org.jboss.aop.AspectManager"> <constructor factoryClass="org.jboss.aop.AspectManager" factoryMethod="instance"/> </bean --> <beanfactory name="MetaDataContextAdvice" class="org.jboss.test.microcontainer.support.MetaDataContextInterceptor/???????"> <property name="annotation">org.jboss.aop.microcontainer.aspects.jmx.JMX</property> </beanfactory> <bean name="MetaDataContextAspect" class="org.jboss.aop.microcontainer.beans.Aspect"> <property name="advice"><inject bean="MetaDataContextAdvice"/></property> <property name="manager"><inject bean="AspectManager"/></property> </bean> <bean name="MetaDataContextBinding" class="org.jboss.aop.microcontainer.beans.AspectBinding"> <property name="pointcut">execution(* org.jboss.test.microcontainer.support.SimpleBeanImpl->*(..))</property> <property name="aspect"><inject bean="MetaDataContextAspect" property="definition"/></property> <property name="manager"><inject bean="AspectManager"/></property> </bean> <bean name="SimplePojo" class="org.jboss.mc.SimplePojo"> <!-- FIXME restore the property replacement on the partition name once JBMICROCONT-143 is fixed --> <annotation>@org.jboss.aop.microcontainer.aspects.jmx.JMX(name="jboss:service=POJO", exposedInterface=org.jboss.mc.SimplePojoMBean.class, registerDirectly=true)</annotation> </bean> </deployment>
What should be the entry for the beanfactory's classname in the pojo-beans.xml which I have pasted above? Looks like I need to write some class specific to POJO here or I can use some standard one from the Jboss itself ?