I realize this may be more of a ClassLoader question, but how can I get an instance of the JBossMX RelationService and not the Sun Ref Impl version?
I am using JBoss 4.03 with Java 1.5.0-05. I get the following traceback when attempting to add a relationship via RelationService. 2005-11-02 10:09:27,278 INFO [STDOUT] javax.management.relation.InvalidRoleValueException: Child has an MBean reference to an MBean not of the expected class of references for that role. 2005-11-02 10:09:27,279 INFO [STDOUT] at javax.management.relation.RelationService.throwRoleProblemException(RelationService.java:3703) 2005-11-02 10:09:27,279 INFO [STDOUT] at javax.management.relation.RelationService.addRelationInt(RelationService.java:3252) 2005-11-02 10:09:27,279 INFO [STDOUT] at javax.management.relation.RelationService.addRelation(RelationService.java:779) 2005-11-02 10:09:27,279 INFO [STDOUT] at com.tripos.af.management.ManageableResource.addChildResource(ManageableResource.java:157) <blah blah> I can see from the line numbers in the traceback that it has entered into the RI version of the class, not JBossMX's which is the one I really want of course. Regardless of whether I create RelationService by direct instantiation or by subclassing it, I get the RI version. I've tried something like this as well to no avail: MBeanServer server = MBeanServerLocator.locateJBoss(); ClassLoader cl = server.getClassLoader(null); Class clazz = cl.loadClass("javax.management.relation.RelationService"); I can't take the RI out of the JRE or override it via EndorsedLibraries. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3904917#3904917 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3904917 ------------------------------------------------------- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42" plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php _______________________________________________ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user