Hi,
I managed to do the 3.0 backpatch, whith just a few midifications. I had
to change the invoke name on the invokera (hopsidaisy) but it seems to
work find with the testsuites (although I am not fully shure since I
have never configured my system for clustering).
Now I am wondering: is this something we should include in the 3.0.x
line; and if - Scott do you want to have full controll ower patches
against 3.0.x or is it ok if I apply them (se also next mail)?
Here is the most obstructing changes done (then it is ofcourse the new
classes; and a new method to GenericProxyFactory.java):
Index:
jmx/src/main/org/jboss/mx/server/registry/ManagedMBeanRegistry.java
===================================================================
RCS file:
/cvsroot/jboss/jmx/src/main/org/jboss/mx/server/registry/Attic/ManagedMBeanRegistry.java,v
retrieving revision 1.2
diff -u -r1.2 ManagedMBeanRegistry.java
---
jmx/src/main/org/jboss/mx/server/registry/ManagedMBeanRegistry.java 14
Apr 2002 17:20:29 -0000 1.2
+++
jmx/src/main/org/jboss/mx/server/registry/ManagedMBeanRegistry.java 3
Mar 2003 14:19:46 -0000
@@ -176,6 +176,31 @@
descGetSize
);
+ // get operation
+ DescriptorSupport descGet = new DescriptorSupport();
+ descGet.setField("name", "get");
+ descGet.setField("descriptorType", "operation");
+ descGet.setField("role", "operation");
+ MBeanParameterInfo[] getParms =
+ new MBeanParameterInfo[]
+ {
+ new MBeanParameterInfo
+ (
+ "ObjectName",
+ ObjectName.class.getName(),
+ "The object name of the MBean to get MBeanEntry for"
+ )
+ };
+ ModelMBeanOperationInfo getInfo =
+ new ModelMBeanOperationInfo
+ (
+ "get",
+ "Gets the MBeanEntry for mbean",
+ getParms,
+ MBeanEntry.class.getName(),
+ ModelMBeanOperationInfo.INFO,
+ descGet
+ );
// Construct the modelmbean
DescriptorSupport descMBean = new DescriptorSupport();
descMBean.setField("name", "MBeanRegistry");
@@ -194,7 +219,8 @@
{
registerMBeanInfo,
unregisterMBeanInfo,
- getSizeInfo
+ getSizeInfo,
+ getInfo
},
(ModelMBeanNotificationInfo[]) null,
descMBean
Index: server/src/main/org/jboss/invocation/jrmp/server/JRMPInvoker.java
===================================================================
RCS file:
/cvsroot/jboss/jboss/src/main/org/jboss/invocation/jrmp/server/JRMPInvoker.java,v
retrieving revision 1.17.2.10
diff -u -r1.17.2.10 JRMPInvoker.java
--- server/src/main/org/jboss/invocation/jrmp/server/JRMPInvoker.java 4
Feb 2003 02:10:59 -0000 1.17.2.10
+++ server/src/main/org/jboss/invocation/jrmp/server/JRMPInvoker.java 3
Mar 2003 14:19:53 -0000
@@ -378,10 +378,10 @@
// store a map of these names under a specific entry
(lookup("ObjecNames")) and look on
// that subset FIXME it will speed up lookup times
ObjectName mbean = (ObjectName) Registry.lookup((Integer)
invocation.getObjectName());
-
+
// The cl on the thread should be set in another interceptor
Object obj = server.invoke(mbean,
- "",
+ "invoke",
new Object[] {invocation},
Invocation.INVOKE_SIGNATURE);
Index: server/src/main/org/jboss/invocation/local/LocalInvoker.java
===================================================================
RCS file:
/cvsroot/jboss/jboss/src/main/org/jboss/invocation/local/LocalInvoker.java,v
retrieving revision 1.6.2.1
diff -u -r1.6.2.1 LocalInvoker.java
--- server/src/main/org/jboss/invocation/local/LocalInvoker.java 4 Feb
2003 02:11:03 -0000 1.6.2.1
+++ server/src/main/org/jboss/invocation/local/LocalInvoker.java 3 Mar
2003 14:19:53 -0000
@@ -97,7 +97,7 @@
Registry.lookup((Integer)invocation.getObjectName());
return server.invoke(mbean,
- "",
+ "invoke",
new Object[] { invocation },
Invocation.INVOKE_SIGNATURE);
//Peter
On Fri, 2003-02-28 at 15:44, Adrian Brock wrote:
> Hi Peter,
>
> The MBeanRegistry is easy,
> there is already a ManagedMBeanRegistry implementation in 3.0.x, it
> should be simple to expose the classloader through an operation.
>
> The harder part is changing InvokerAdaptorServiceMBean
> to be a DynamicMBean, since 3.0.x uses operation "" instead of
> "invoke", alternatively fix and test the operation name.
>
> Regards,
> Adrian
>
> >From: Peter Antman <[EMAIL PROTECTED]>
> >Reply-To: [EMAIL PROTECTED]
> >To: [EMAIL PROTECTED]
> >Subject: Re: [JBoss-dev] RMIClassloader for MBean RMIAdaptor
> >Date: 28 Feb 2003 14:05:31 +0100
> >
> >Hi, wow,
> >last night I tought in desperation that I would have to write a detyped
> >invoker to solve the stuff: and now you have already done it!
> >
> >Unfortunately it seems like pain to port it to the 3.0.x line, mostly
> >because of the lack of access to the MBeanRegistry (wich makes it
> >imposible to get at the UCL for the MBean to invoke).
> >
> >I will however test another path more like the EJB stuff (when yout
> >binds a proxy for an MBean its will create an invoker with the
> >classloader and therefore it will have acces to it. I don't know if it
> >will work, we will see.
> >
> >//Peter
> >
> >On Fri, 2003-02-28 at 05:29, Adrian Brock wrote:
> > > Hi Peter,
> > >
> > > You shamed me into testing my alternate implementation
> > > of the RMI adaptor, which is now committed in 3.2
> > >
> > > This implementation uses the jboss invokers with
> > > late de-marshalling so it can be performed with the
> > > correct classloader.
> > >
> > > The three config parameters are
> > >
> > > JNDIName - for binding the proxy into jndi
> > > InterfaceClassName - Choose an interface that looks
> > > like an MBeanServer, it doesn't have to extend
> > > MBeanServer - it simiulates the loose coupling of the
> > > MBeanServer invocation,
> > > i.e. it matches name and parameter types.
> > > InvokerName - The JMX object name of the jboss invoker
> > >
> > > There is an example configuration for replacing
> > > the RMIAdaptor in
> > > server/default/deploy/jmx-invoker-adaptor-server.sar
> > >
> > > In principle this should work with other MBeanServer like interfaces
> > > and other jboss invokers.
> > >
> > > This is a stop gap solution until jboss4, which will have
> > > jboss remoting and jsr160's MBeanServerConnection
> > >
> > > Regards,
> > > Adrian
> > >
> > > >From: Peter Antman <[EMAIL PROTECTED]>
> > > >Reply-To: [EMAIL PROTECTED]
> > > >To: [EMAIL PROTECTED]
> > > >Subject: [JBoss-dev] RMIClassloader for MBean RMIAdaptor
> > > >Date: 27 Feb 2003 14:33:37 +0100
> > > >
> > > >Hi,
> > > >I am experiencing some trouble with remote MBean calls (with
> >RMIAdaptor)
> > > >to MBean loaded in a scoped deployment. Does any one know any way of
> > > >setting the context class loader that RMI uses when doing its
> > > >RMIClassLoading stuff. For jrmp ejb calls this works fine since the
> > > >invocation is detyped and the parameters and classes are loaded in the
> > > >correct thread context classloader; but as far as I can see invokation
> > > >of MBeans through rmi seems to require the classes to be available on
> > > >the global classloader repository. Does anyone know of a way around
> >this
> > > >or is it simply impossible to call a scopes MBean through RMI without
> > > >making the classes involed globaly visable?
> > > >
> > > >//Peter
> > > >--
> > > >------------------------------------------------------------
> > > >Peter Antman Chief Technology Officer, Development
> > > >Technology in Media, Box 34105 100 26 Stockholm
> > > >WWW: http://www.tim.se WWW: http://www.backsource.org
> > > >Email: [EMAIL PROTECTED]
> > > >Phone: +46-(0)8-506 381 11 Mobile: +46-(0)704 20 58 11
> > > >------------------------------------------------------------
> > > >
> > > >
> > > >
> > > >-------------------------------------------------------
> > > >This SF.NET email is sponsored by:
> > > >SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
> > > >http://www.vasoftware.com
> > > >_______________________________________________
> > > >Jboss-development mailing list
> > > >[EMAIL PROTECTED]
> > > >https://lists.sourceforge.net/lists/listinfo/jboss-development
> > >
> > >
> > > _________________________________________________________________
> > > Overloaded with spam? With MSN 8, you can filter it out
> > >
> >http://join.msn.com/?page=features/junkmail&pgmarket=en-gb&XAPID=32&DI=1059
> > >
> > >
> > >
> > > -------------------------------------------------------
> > > This sf.net email is sponsored by:ThinkGeek
> > > Welcome to geek heaven.
> > > http://thinkgeek.com/sf
> > > _______________________________________________
> > > Jboss-development mailing list
> > > [EMAIL PROTECTED]
> > > https://lists.sourceforge.net/lists/listinfo/jboss-development
> >--
> >------------------------------------------------------------
> >Peter Antman Chief Technology Officer, Development
> >Technology in Media, Box 34105 100 26 Stockholm
> >WWW: http://www.tim.se WWW: http://www.backsource.org
> >Email: [EMAIL PROTECTED]
> >Phone: +46-(0)8-506 381 11 Mobile: +46-(0)704 20 58 11
> >------------------------------------------------------------
> >
> >
> >
> >-------------------------------------------------------
> >This sf.net email is sponsored by:ThinkGeek
> >Welcome to geek heaven.
> >http://thinkgeek.com/sf
> >_______________________________________________
> >Jboss-development mailing list
> >[EMAIL PROTECTED]
> >https://lists.sourceforge.net/lists/listinfo/jboss-development
>
>
> _________________________________________________________________
> MSN Messenger - fast, easy and FREE! http://messenger.msn.co.uk
>
>
>
> -------------------------------------------------------
> This sf.net email is sponsored by:ThinkGeek
> Welcome to geek heaven.
> http://thinkgeek.com/sf
> _______________________________________________
> Jboss-development mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/jboss-development
--
------------------------------------------------------------
Peter Antman Chief Technology Officer, Development
Technology in Media, Box 34105 100 26 Stockholm
WWW: http://www.tim.se WWW: http://www.backsource.org
Email: [EMAIL PROTECTED]
Phone: +46-(0)8-506 381 11 Mobile: +46-(0)704 20 58 11
------------------------------------------------------------
-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development