There is an EJB adaptor to JMX use that to proxy your invocation to the target j2ee deploy (or something like that ;). If not make a custom ejb whose sole purpose in life is to call that mbean on the target system, should be straightforward
It's not from an ejb... but you might look at JBossTestServices in the testsuite for some examples of remote programatic deployement (the testsuite all uses this).
1- you are absolutely correct the test suite does start from one VM to another so that code would be really relevant
2- motherf8cker how did you go up to 285 answers!!! ouch, you beat me on number of questions, that can't be, I am going to start answer "yes" "no" to any mail I read see if I catch up with you :)
I was able to use RMIConnector to call the J2eeDeployer bean from an EJB running on the same JBoss server. My goal is to get this bean to be able to call N different servers.
There is a slight problem with the API for creating the RMIConnectors to do this. The N different servers do not share the JNDI name space, so I have to reconfigure getting the InitialContext to lookup the Adaptor for each Connector by setting PROVIDER_URL. I cannot use a single jndi.properties file. So the constructor for RMIConnector that tries to lookup the Adaptor in JNDI is useless. I have to manually lookup the Adaptor myself and call the other constructor. No big deal, if this is the intended usage.
Hopefully, I'll test today invocations across JBoss servers.
Thanks for replies.
Is this anatoly akkerman?
submit a patch man, do you have a problem with giving us that code?
> Is this anatoly akkerman?
Yeap, that's me.
> submit a patch man, do you have a problem with giving
> us that code?
I have not patched anything, just using a different constructor. For now it works. If I see a need to modify the API, I might patch it. Don't fix it if it ain't broken :)
I am new to JMX, so for now let me just try using what's there already.