Re: AW: [JBoss-dev] JBoss.net/IIOP and JBossMX integration
Hi CGJ, I think your problem is attributes. JBossMX doesn't support invocations like server.invoke(myObjectName, "getAttribute", new Object[0], new String[0]); You should use server.getAttribute("Attribute") instead. The RI for jmx1.0 allows the invoke, but it will be gone with jmx1.1. It was a bug. Sorry, I didn't spot your MBeanProvider, I used grep for \"get and \"set You might want to look at the code in common/src/main/org/jboss/util/jmx/MBeanProxy.java for interface based access to an MBean. But it might be a bit slow retrieving this information on the fly. Regards, Adrian > Hi Adrian, > > Just a quick feedback. Compilation is ok, most stuff > runs fine and faster > ;-) > > >From what I saw, the reflection of the Mbean > interfaces in jboss-jmx seems > to differ from jmxri.jar ... > > Because I use to define first client-side (non-Mbean) > interfaces from which > the Mbean interfaces are extended, I know run > into ReflectionException(NoSuchMethodException) when > trying to invoke those > methods via MBeanServer.invoke > > I have to check how to work-around this issue. I have > no idea what the spec > says to this pattern. > > Best, > CGJ > > ___ > Jboss-development mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-dev > lopment _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11954 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] I ask for advice on CVS lock
Hi Oleg, I had the same problem last week. Jason told me to submit a request at http://sourceforge.net/tracker/?func=add&group_id=1&atid=21 Regards, Adrian > Hi All, > > I am trying to update Jetty in JBoss CVS, but there > is a lock in > /cvsroot/jboss/contrib/jetty/src/main/org/mortbay/htt > > so that I cannot commit changes to this dir. > I don't know how to solve this issue. > Probably I should contact somebody from SourceForge? > Any ideas? > > Thanks in advance, > Oleg > > ___ > Jboss-development mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-dev > lopment _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11821 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS write access problem
Hi, I just applied a fix to Branch_2_4. I'm trying to tag with Rel_2_4_5_10. It gets part way through, then tells me I haven't got write access. Is this a file system authority? bash-2.05$ cvs tag Rel_2_4_5_10 ? jboss_co.log ? jnp_co.log ? jbosssx_co.log ? jbossmq_co.log ? jbosscx_co.log ? jbosspool_co.log ? jbossj2ee_co.log ? tomcat.log ? catalina.log ? jetty.log ? jboss.log ? jboss-j2ee.log ? jnp.log ? jbosssx.log ? jbosscx.log ? jbosspool.log ? jbossmq.log ? jboss2.log cvs server: Tagging . cvs server: Tagging docs cvs server: Tagging external cvs server: Tagging lib cvs server: Tagging src cvs server: Tagging src/bin cvs server: Tagging src/build cvs server: Tagging src/client cvs server: Tagging src/client/admin cvs server: Tagging src/client/admin/lib cvs server: Tagging src/docs cvs server: Tagging src/docs/images cvs server: Tagging src/etc cvs server: Tagging src/etc/beaninfo cvs server: Tagging src/etc/beaninfo/jaws cvs server: Tagging src/etc/conf cvs server: Tagging src/etc/conf/default cvs server: Tagging src/etc/deploy cvs server: Tagging src/lib cvs server: Tagging src/main cvs server: Tagging src/main/org cvs server: Tagging src/main/org/jboss cvs server: Tagging src/main/org/jboss/configuration cvs server: Tagging src/main/org/jboss/deployment cvs server: Tagging src/main/org/jboss/deployment/scope cvs server: Tagging src/main/org/jboss/ejb cvs server: Tagging src/main/org/jboss/ejb/plugins cvs server: Tagging src/main/org/jboss/ejb/plugins/jaws cvs server: Tagging src/main/org/jboss/ejb/plugins/jaws/bmp cvs server: Tagging src/main/org/jboss/ejb/plugins/jaws/jdbc cvs server: Tagging src/main/org/jboss/ejb/plugins/jaws/metadata cvs server: Tagging src/main/org/jboss/ejb/plugins/jms cvs server: Tagging src/main/org/jboss/ejb/plugins/jrmp cvs server: Tagging src/main/org/jboss/ejb/plugins/jrmp/interfaces cvs server: Tagging src/main/org/jboss/ejb/plugins/jrmp/server cvs server: Tagging src/main/org/jboss/ejb/plugins/jrmp12 cvs server: Tagging src/main/org/jboss/ejb/plugins/jrmp12/interfaces cvs server: Tagging src/main/org/jboss/ejb/plugins/jrmp12/server cvs server: Tagging src/main/org/jboss/ejb/plugins/jrmp13 cvs server: Tagging src/main/org/jboss/ejb/plugins/jrmp13/interfaces cvs server: Tagging src/main/org/jboss/ejb/plugins/jrmp13/server cvs server: Tagging src/main/org/jboss/ejb/plugins/local cvs server: Tagging src/main/org/jboss/ejb/plugins/lock cvs server: Tagging src/main/org/jboss/jdbc cvs server: Tagging src/main/org/jboss/jms cvs server: Tagging src/main/org/jboss/jms/asf cvs server: Tagging src/main/org/jboss/jms/jndi cvs server: Tagging src/main/org/jboss/jms/ra cvs server: Tagging src/main/org/jboss/jms/ra/client cvs server: Tagging src/main/org/jboss/jmx cvs server: Tagging src/main/org/jboss/jmx/client cvs server: Tagging src/main/org/jboss/jmx/interfaces cvs server: Tagging src/main/org/jboss/jmx/server cvs server: Tagging src/main/org/jboss/logging cvs server: Tagging src/main/org/jboss/logging/log4j cvs server: Tagging src/main/org/jboss/mail cvs server: Tagging src/main/org/jboss/management cvs server: Tagging src/main/org/jboss/metadata cvs server: Tagging src/main/org/jboss/monitor cvs server: Tagging src/main/org/jboss/monitor/client cvs server: Tagging src/main/org/jboss/naming cvs server: Tagging src/main/org/jboss/naming/java cvs server: Tagging src/main/org/jboss/proxy cvs server: Tagging src/main/org/jboss/security cvs server: Tagging src/main/org/jboss/security/plugins cvs server: Tagging src/main/org/jboss/security/plugins/samples cvs server: Tagging src/main/org/jboss/tm cvs server: Tagging src/main/org/jboss/tm/plugins cvs server: Tagging src/main/org/jboss/tm/plugins/tyrex cvs server: Tagging src/main/org/jboss/tm/usertx cvs server: Tagging src/main/org/jboss/tm/usertx/client cvs server: Tagging src/main/org/jboss/tm/usertx/interfaces cvs server: Tagging src/main/org/jboss/tm/usertx/server cvs server: Tagging src/main/org/jboss/util cvs server: Tagging src/main/org/jboss/util/timeout cvs server: Tagging src/main/org/jboss/verifier cvs server: Tagging src/main/org/jboss/verifier/event cvs server: Tagging src/main/org/jboss/verifier/factory cvs server: Tagging src/main/org/jboss/verifier/strategy cvs server: Tagging src/main/org/jboss/web cvs server: Tagging src/main/test cvs server: Tagging src/main/test/jboss cvs server: Tagging src/main/test/jboss/deployment cvs server: Tagging src/main/test/jboss/jmx cvs server: Tagging src/main/test/jboss/jrmp cvs server: Tagging src/main/test/jboss/minerva cvs server: Tagging src/main/test/jboss/minerva/factories cvs server: Tagging src/main/test/jboss/minerva/pools cvs server: Tagging src/main/test/jboss/naming cvs server: Tagging src/main/test/jboss/testdb cvs server: Tagging src/resources cvs server: Tagging src/resources/org cvs server: Tagging src/resources/org/jboss cvs server: Tagging src/resources/org/jboss/ejb cvs server: Tagging src/resources/org/jboss/ejb/deployment cvs server: Tagging src/resources/org/jb
[JBoss-dev] CVS update: jboss/src/main/org/jboss/util Shutdown.java
User: ejort Date: 02/03/29 07:06:29 Modified:src/main/org/jboss/util Tag: Branch_2_4 Shutdown.java Log: Fixed shutdown bug no 536633 Revision ChangesPath No revision No revision 1.2.6.2 +9 -2 jboss/src/main/org/jboss/util/Attic/Shutdown.java Index: Shutdown.java === RCS file: /cvsroot/jboss/jboss/src/main/org/jboss/util/Attic/Shutdown.java,v retrieving revision 1.2.6.1 retrieving revision 1.2.6.2 diff -u -r1.2.6.1 -r1.2.6.2 --- Shutdown.java 20 Nov 2001 09:42:57 - 1.2.6.1 +++ Shutdown.java 29 Mar 2002 15:06:28 - 1.2.6.2 @@ -19,7 +19,7 @@ * * @see * @author Rickard Öberg ([EMAIL PROTECTED]) - * @version $Revision: 1.2.6.1 $ + * @version $Revision: 1.2.6.2 $ */ public class Shutdown implements MBeanRegistration, ShutdownMBean @@ -36,7 +36,14 @@ // Public --- public void shutdown() { - System.exit(0); // This will execute the shutdown hook + new Thread() + { + public void run() + { +log.info("Shutting down the JVM now!"); +System.exit(0); // This will execute the shutdown hook + } + }.start(); } // MBeanRegistration implementation -- ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jmx/src/main/test/compliance/notcompliant NCMBeanTEST.java
User: ejort Date: 02/03/29 04:14:35 Modified:src/main/test/compliance/notcompliant NCMBeanTEST.java Log: Merge differences between RelMX_1_0_0_13 and RelMX_1_0_0_14 to head Revision ChangesPath 1.2 +66 -23jmx/src/main/test/compliance/notcompliant/NCMBeanTEST.java Index: NCMBeanTEST.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/notcompliant/NCMBeanTEST.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- NCMBeanTEST.java 18 Jan 2002 17:28:41 - 1.1 +++ NCMBeanTEST.java 29 Mar 2002 12:14:35 - 1.2 @@ -1,14 +1,14 @@ -/* - * JBoss, the OpenSource J2EE webOS - * - * Distributable under LGPL license. - * See terms of license at gnu.org. - */ -package test.compliance.notcompliant; - -import junit.framework.TestCase; - -import javax.management.MalformedObjectNameException; +/* + * JBoss, the OpenSource J2EE webOS + * + * Distributable under LGPL license. + * See terms of license at gnu.org. + */ +package test.compliance.notcompliant; + +import junit.framework.TestCase; + +import javax.management.MalformedObjectNameException; import javax.management.ObjectName; import javax.management.MBeanServerFactory; import javax.management.MBeanServer; @@ -17,16 +17,19 @@ import java.util.Hashtable; import test.compliance.notcompliant.support.OverloadedAttribute1; -import test.compliance.notcompliant.support.OverloadedAttribute3; import test.compliance.notcompliant.support.OverloadedAttribute2; -import test.compliance.notcompliant.support.DynamicAndStandard; - -public class NCMBeanTEST extends TestCase -{ - public NCMBeanTEST(String s) - { - super(s); - } +import test.compliance.notcompliant.support.OverloadedAttribute3; +import test.compliance.notcompliant.support.OverloadedAttribute4; +import test.compliance.notcompliant.support.OverloadedAttribute5; +import test.compliance.notcompliant.support.InterfaceProblems; +import test.compliance.notcompliant.support.DynamicAndStandard; + +public class NCMBeanTEST extends TestCase +{ + public NCMBeanTEST(String s) + { + super(s); + } public void testOverloadedAttribute1() { @@ -43,6 +46,16 @@ registerAndTest(new OverloadedAttribute3()); } + public void testOverloadedAttribute4() + { + registerAndTest(new OverloadedAttribute4()); + } + + public void testOverloadedAttribute5() + { + registerAndTest(new OverloadedAttribute5()); + } + public void testMixedDynamicStandard() { registerAndTest(new DynamicAndStandard()); @@ -52,12 +65,17 @@ { registerAndTest(new NoConstructor()); } - + + public void testInterfaceProblems() + { + registerAndDontTest(new InterfaceProblems()); + } + private void registerAndTest(Object mbean) { + MBeanServer server = MBeanServerFactory.createMBeanServer(); try { - MBeanServer server = MBeanServerFactory.newMBeanServer(); server.registerMBean(mbean, new ObjectName("test:foo=bar")); fail("expected a NotCompliantMBeanException for " + mbean.getClass().getName()); } @@ -69,5 +87,30 @@ { fail("unexpected exception when registering " + mbean.getClass().getName() + ": " + e.getMessage()); } + finally + { + MBeanServerFactory.releaseMBeanServer(server); + } + } + + private void registerAndDontTest(Object mbean) + { + MBeanServer server = MBeanServerFactory.createMBeanServer(); + try + { + server.registerMBean(mbean, new ObjectName("test:foo=bar")); + } + catch (NotCompliantMBeanException e) + { + fail("FAILS IN RI: Cannot cope with overriden get/is in interfaces"); + } + catch (Exception e) + { + fail("unexpected exception when registering " + mbean.getClass().getName() + ": " + e.getMessage()); + } + finally + { + MBeanServerFactory.releaseMBeanServer(server); + } } -} +} ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jmx/src/main/test/compliance/monitor MonitorTestCase.java
User: ejort Date: 02/03/29 04:14:34 Modified:src/main/test/compliance/monitor MonitorTestCase.java Log: Merge differences between RelMX_1_0_0_13 and RelMX_1_0_0_14 to head Revision ChangesPath 1.3 +1321 -183 jmx/src/main/test/compliance/monitor/MonitorTestCase.java Index: MonitorTestCase.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/MonitorTestCase.java,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- MonitorTestCase.java 24 Mar 2002 13:12:12 - 1.2 +++ MonitorTestCase.java 29 Mar 2002 12:14:34 - 1.3 @@ -23,9 +23,11 @@ import java.util.ArrayList; import java.util.Date; +import java.util.HashSet; import java.util.Iterator; import javax.management.Attribute; +import javax.management.MBeanNotificationInfo; import javax.management.MBeanServer; import javax.management.MBeanServerFactory; import javax.management.ObjectName; @@ -37,9 +39,9 @@ import javax.management.monitor.MonitorNotification; import javax.management.monitor.StringMonitor; +import junit.framework.AssertionFailedError; import junit.framework.TestCase; - /** * Monitor Notification Tests * @@ -64,64 +66,998 @@ ObjectName monitorName; /** -* The monitor +* The monitor +*/ + Monitor monitor; + + /** +* The object name of the mbean monitored +*/ + ObjectName monitoredName; + + /** +* The monitored mbean +*/ + MonitorSupport monitored; + + /** +* The notifications +*/ + ArrayList notifications = new ArrayList(); + + // Constructor - + + /** +* Construct the test +*/ + public MonitorTestCase(String s) + { + super(s); + } + + // Tests --- + + /** +* Test notification types differ +*/ + public void testNotificationTypes() + { + assertEquals(MonitorNotification.OBSERVED_ATTRIBUTE_ERROR, + "jmx.monitor.error.attribute"); + assertEquals(MonitorNotification.OBSERVED_ATTRIBUTE_TYPE_ERROR, + "jmx.monitor.error.type"); + assertEquals(MonitorNotification.OBSERVED_OBJECT_ERROR, + "jmx.monitor.error.mbean"); + assertEquals(MonitorNotification.RUNTIME_ERROR, + "jmx.monitor.error.runtime"); + assertEquals(MonitorNotification.STRING_TO_COMPARE_VALUE_DIFFERED, + "jmx.monitor.string.differs"); + assertEquals(MonitorNotification.STRING_TO_COMPARE_VALUE_MATCHED, + "jmx.monitor.string.matches"); + assertEquals(MonitorNotification.THRESHOLD_ERROR, + "jmx.monitor.error.threshold"); + assertEquals(MonitorNotification.THRESHOLD_HIGH_VALUE_EXCEEDED, + "jmx.monitor.gauge.high"); + assertEquals(MonitorNotification.THRESHOLD_LOW_VALUE_EXCEEDED, + "jmx.monitor.gauge.low"); + assertEquals(MonitorNotification.THRESHOLD_VALUE_EXCEEDED, + "jmx.monitor.counter.threshold"); + } + + // Counter monitor notification info --- + + /** +* Test the notification info of the counter +*/ + public void testCounterNotificationInfo() + throws Exception + { + HashSet expected = new HashSet(); + expected.add(MonitorNotification.OBSERVED_ATTRIBUTE_ERROR); + expected.add(MonitorNotification.OBSERVED_ATTRIBUTE_TYPE_ERROR); + expected.add(MonitorNotification.OBSERVED_OBJECT_ERROR); + expected.add(MonitorNotification.RUNTIME_ERROR); + expected.add(MonitorNotification.THRESHOLD_ERROR); + expected.add(MonitorNotification.THRESHOLD_VALUE_EXCEEDED); + + MBeanNotificationInfo[] mbni = new CounterMonitor().getNotificationInfo(); + checkNotificationInfo("Counter", mbni, expected); + } + + // Counter normal no offset no modulus tests --- + + /** +* Test normal counter threshold no offset no modulus +*/ + public void testNormalCounterThresholdExceededEarlyNoOffsetNoModulus() + throws Exception + { + initTest(); + try + { + initCounterMonitor(true, new Integer(10), +false, new Integer(0), new Integer(0)); + expectStartMonitor(new Integer(10), +MonitorNotification.THRESHOLD_VALUE_EXCEEDED); + } + finally + { + stopMonitor(); + MBeanServerFactory.releaseMBeanServer(server); + } + } + + /** +* Test normal counter threshold no offset no mo
[JBoss-dev] CVS update: jmx/src/main/test/compliance/notcompliant/support InterfaceProblems.java InterfaceProblemsMBean.java InterfaceProblemsSuperMBean.java OverloadedAttribute4.java OverloadedAttribute4MBean.java OverloadedAttribute5.java OverloadedAttribute5MBean.java
User: ejort Date: 02/03/29 04:14:35 Added: src/main/test/compliance/notcompliant/support InterfaceProblems.java InterfaceProblemsMBean.java InterfaceProblemsSuperMBean.java OverloadedAttribute4.java OverloadedAttribute4MBean.java OverloadedAttribute5.java OverloadedAttribute5MBean.java Log: Merge differences between RelMX_1_0_0_13 and RelMX_1_0_0_14 to head Revision ChangesPath 1.2 +24 -0 jmx/src/main/test/compliance/notcompliant/support/InterfaceProblems.java 1.2 +14 -0 jmx/src/main/test/compliance/notcompliant/support/InterfaceProblemsMBean.java 1.2 +13 -0 jmx/src/main/test/compliance/notcompliant/support/InterfaceProblemsSuperMBean.java 1.2 +23 -0 jmx/src/main/test/compliance/notcompliant/support/OverloadedAttribute4.java 1.2 +13 -0 jmx/src/main/test/compliance/notcompliant/support/OverloadedAttribute4MBean.java 1.2 +23 -0 jmx/src/main/test/compliance/notcompliant/support/OverloadedAttribute5.java 1.2 +13 -0 jmx/src/main/test/compliance/notcompliant/support/OverloadedAttribute5MBean.java ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jmx/src/main/javax/management Notification.java
User: ejort Date: 02/03/29 04:14:33 Modified:src/main/javax/management Notification.java Log: Merge differences between RelMX_1_0_0_13 and RelMX_1_0_0_14 to head Revision ChangesPath 1.2 +196 -34 jmx/src/main/javax/management/Notification.java Index: Notification.java === RCS file: /cvsroot/jboss/jmx/src/main/javax/management/Notification.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- Notification.java 3 Dec 2001 02:08:47 - 1.1 +++ Notification.java 29 Mar 2002 12:14:33 - 1.2 @@ -1,104 +1,266 @@ /* - * LGPL + * JBoss, the OpenSource J2EE webOS + * + * Distributable under LGPL license. + * See terms of license at gnu.org. */ package javax.management; -public class Notification extends java.util.EventObject { - +/** + * A Notification. + * + * Revisions: + * 20020329 Adrian Brock: + * + * Make the source serializable + * + * + * @author mailto:[EMAIL PROTECTED]";>Adrian Brock. + * @version $Revision$ + */ +public class Notification + extends java.util.EventObject +{ + // Constants --- + + // Attributes -- + + /** +* The notification type +*/ private String type = null; + + /** +* The sequence number of the notification +*/ private long sequenceNumber = 0; + + /** +* The message of the notification +*/ private String message = null; + + /** +* The time of the notification +*/ private long timeStamp = System.currentTimeMillis(); + + /** +* The user data of the notification +*/ private Object userData = null; - - - public Notification(java.lang.String type, - java.lang.Object source, - long sequenceNumber) { + + /** +* The source of the notification +*/ + private Object mySource = null; + + // Static -- + + // Constructors + + /** +* Create a new notification +* +* @param type the type of the notification +* @param source the source of the notification +* @param sequenceNumber the sequence number of the notification +*/ + public Notification(String type, + Object source, + long sequenceNumber) + { super(source); + mySource = source; this.type = type; this.sequenceNumber = sequenceNumber; this.timeStamp = System.currentTimeMillis(); } - - public Notification(java.lang.String type, - java.lang.Object source, + + /** +* Create a new notification +* +* @param type the type of the notification +* @param source the source of the notification +* @param sequenceNumber the sequence number of the notification +* @param message the message of the notification +*/ + public Notification(String type, + Object source, long sequenceNumber, - java.lang.String message) { + String message) + { this(type, source, sequenceNumber); this.message = message; this.timeStamp = System.currentTimeMillis(); } - public Notification(java.lang.String type, - java.lang.Object source, + /** +* Create a new notification +* +* @param type the type of the notification +* @param source the source of the notification +* @param sequenceNumber the sequence number of the notification +* @param timeStamp the time of the notification +*/ + public Notification(String type, + Object source, long sequenceNumber, - long timeStamp) { + long timeStamp) + { this(type, source, sequenceNumber); this.timeStamp = timeStamp; } - public Notification(java.lang.String type, - java.lang.Object source, + /** +* Create a new notification +* +* @param type the type of the notification +* @param source the source of the notification +* @param sequenceNumber the sequence number of the notification +* @param timeStamp the time of the notification +* @param message the message of the notification +*/ + public Notification(String type, + Object source, long sequenceNumber, long t
[JBoss-dev] CVS update: jmx/src/main/test/compliance/monitor/support CounterSupport.java GaugeSupport.java MonitorSupport.java StringSupport.java
User: ejort Date: 02/03/29 04:14:35 Modified:src/main/test/compliance/monitor/support CounterSupport.java GaugeSupport.java MonitorSupport.java StringSupport.java Log: Merge differences between RelMX_1_0_0_13 and RelMX_1_0_0_14 to head Revision ChangesPath 1.3 +2 -8 jmx/src/main/test/compliance/monitor/support/CounterSupport.java Index: CounterSupport.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/support/CounterSupport.java,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- CounterSupport.java 24 Mar 2002 13:12:13 - 1.2 +++ CounterSupport.java 29 Mar 2002 12:14:34 - 1.3 @@ -15,15 +15,9 @@ public Number getValue() { + unlock("get"); lock("get"); - try - { -return value; - } - finally - { -unlock("get"); - } + return value; } public void setValue(Number value) 1.3 +2 -8 jmx/src/main/test/compliance/monitor/support/GaugeSupport.java Index: GaugeSupport.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/support/GaugeSupport.java,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- GaugeSupport.java 24 Mar 2002 13:12:13 - 1.2 +++ GaugeSupport.java 29 Mar 2002 12:14:34 - 1.3 @@ -15,15 +15,9 @@ public Number getValue() { + unlock("get"); lock("get"); - try - { -return value; - } - finally - { -unlock("get"); - } + return value; } public void setValue(Number value) 1.3 +10 -4 jmx/src/main/test/compliance/monitor/support/MonitorSupport.java Index: MonitorSupport.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/support/MonitorSupport.java,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- MonitorSupport.java 24 Mar 2002 13:12:13 - 1.2 +++ MonitorSupport.java 29 Mar 2002 12:14:34 - 1.3 @@ -11,25 +11,31 @@ public class MonitorSupport { - String last = "get"; + boolean done = false; + String last = "set"; public synchronized void lock(String who) { - if (last.equals(who)) + if (!done && last.equals(who)) { try { wait(MonitorSUITE.MAX_WAIT); } catch (InterruptedException e) {} - if (last.equals(who)) + if (!done && last.equals(who)) throw new RuntimeException("-- Time Out --"); } } public synchronized void unlock(String who) { - if (last.equals(who)) + if (!done && last.equals(who)) throw new RuntimeException("-- Synchronization failure --"); last=who; + notifyAll(); + } + public synchronized void end() + { + done = true; notifyAll(); } } 1.3 +2 -9 jmx/src/main/test/compliance/monitor/support/StringSupport.java Index: StringSupport.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/support/StringSupport.java,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- StringSupport.java24 Mar 2002 13:12:13 - 1.2 +++ StringSupport.java29 Mar 2002 12:14:34 - 1.3 @@ -15,20 +15,13 @@ public String getValue() { + unlock("get"); lock("get"); - try - { -return value; - } - finally - { -unlock("get"); - } + return value; } public void setValue(String value) { - lock("set"); this.value = value; } ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jmx/src/main/org/jboss/mx/metadata StandardMetaData.java
User: ejort Date: 02/03/29 04:14:34 Modified:src/main/org/jboss/mx/metadata StandardMetaData.java Log: Merge differences between RelMX_1_0_0_13 and RelMX_1_0_0_14 to head Revision ChangesPath 1.7 +20 -7 jmx/src/main/org/jboss/mx/metadata/StandardMetaData.java Index: StandardMetaData.java === RCS file: /cvsroot/jboss/jmx/src/main/org/jboss/mx/metadata/StandardMetaData.java,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- StandardMetaData.java 26 Feb 2002 02:02:59 - 1.6 +++ StandardMetaData.java 29 Mar 2002 12:14:34 - 1.7 @@ -66,7 +66,7 @@ HashMap getters = new HashMap(); HashMap setters = new HashMap(); - List operInfo = new ArrayList(); + HashMap operInfo = new HashMap(); List attrInfo = new ArrayList(); for (int i = 0; i < methods.length; ++i) @@ -78,24 +78,37 @@ if (methodName.startsWith("set") && signature.length == 1 && returnType == Void.TYPE) { String key = methodName.substring(3, methodName.length()); - if (setters.get(key) != null) + Method setter = (Method) setters.get(key); + if (setter != null && setter.getParameterTypes()[0].equals(signature[0]) == false) { - throw new IntrospectionException("overloaded type for attribute: " + key); + throw new IntrospectionException("overloaded type for attribute set: " + key); } setters.put(key, methods[i]); } else if (methodName.startsWith("get") && signature.length == 0 && returnType != Void.TYPE) { - getters.put(methodName.substring(3, methodName.length()), methods[i]); + String key = methodName.substring(3, methodName.length()); + Method getter = (Method) getters.get(key); + if (getter != null && getter.getName().startsWith("get") == false) + { + throw new IntrospectionException("mixed use of get/is for attribute " + key); + } + getters.put(key, methods[i]); } else if (methodName.startsWith("is") && signature.length == 0 && (returnType == Boolean.class || returnType == Boolean.TYPE)) { - getters.put(methodName.substring(2, methodName.length()), methods[i]); + String key = methodName.substring(2, methodName.length()); + Method getter = (Method) getters.get(key); + if (getter != null && getter.getName().startsWith("is") == false) + { + throw new IntrospectionException("mixed use of get/is for attribute " + key); + } + getters.put(key, methods[i]); } else { MBeanOperationInfo info = new MBeanOperationInfo("MBean Operation.", methods[i]); - operInfo.add(info); + operInfo.put(methods[i].toString(), info); } } @@ -120,7 +133,7 @@ // save away the attribute and operation info objects MBeanAttributeInfo[] attributeInfo = (MBeanAttributeInfo[]) attrInfo.toArray(new MBeanAttributeInfo[0]); - MBeanOperationInfo[] operationInfo = (MBeanOperationInfo[]) operInfo.toArray(new MBeanOperationInfo[0]); + MBeanOperationInfo[] operationInfo = (MBeanOperationInfo[]) operInfo.values().toArray(new MBeanOperationInfo[0]); MBeanNotificationInfo[] notifications = null; if (mbeanInstance instanceof NotificationBroadcaster) ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jmx/src/main/javax/management/monitor CounterMonitor.java
User: ejort Date: 02/03/29 04:14:34 Modified:src/main/javax/management/monitor CounterMonitor.java Log: Merge differences between RelMX_1_0_0_13 and RelMX_1_0_0_14 to head Revision ChangesPath 1.3 +7 -1 jmx/src/main/javax/management/monitor/CounterMonitor.java Index: CounterMonitor.java === RCS file: /cvsroot/jboss/jmx/src/main/javax/management/monitor/CounterMonitor.java,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- CounterMonitor.java 24 Mar 2002 13:12:12 - 1.2 +++ CounterMonitor.java 29 Mar 2002 12:14:34 - 1.3 @@ -19,6 +19,12 @@ * * Reset the threshold when the value becomes negative in difference mode * + * 20020326 Adrian Brock: + * + * The spec says the modulus should be *strictly* exceeded. It appears + * from testing the RI, it is a mathematical definition of modulus. e.g. + * 10 exceeds a modulus of 10 + * * * @author mailto:[EMAIL PROTECTED]";>Adrian Brock * @version $Revision$ @@ -285,7 +291,7 @@ // For normal mode, restart when modulus exceeded if (differenceMode == false && modulus.longValue() != 0 && -number.longValue() > modulus.longValue()) +number.longValue() >= modulus.longValue()) { threshold = initialThreshold; alreadyNotified &= ~THRESHOLD_EXCEEDED_NOTIFIED; ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jmx/src/main/javax/management Notification.java
User: ejort Date: 02/03/29 02:42:43 Modified:src/main/javax/management Tag: BranchMX_1_0 Notification.java Log: Allow the source to be serialized in notifications Revision ChangesPath No revision No revision 1.1.2.1 +196 -34 jmx/src/main/javax/management/Notification.java Index: Notification.java === RCS file: /cvsroot/jboss/jmx/src/main/javax/management/Notification.java,v retrieving revision 1.1 retrieving revision 1.1.2.1 diff -u -r1.1 -r1.1.2.1 --- Notification.java 3 Dec 2001 02:08:47 - 1.1 +++ Notification.java 29 Mar 2002 10:42:43 - 1.1.2.1 @@ -1,104 +1,266 @@ /* - * LGPL + * JBoss, the OpenSource J2EE webOS + * + * Distributable under LGPL license. + * See terms of license at gnu.org. */ package javax.management; -public class Notification extends java.util.EventObject { - +/** + * A Notification. + * + * Revisions: + * 20020329 Adrian Brock: + * + * Make the source serializable + * + * + * @author mailto:[EMAIL PROTECTED]";>Adrian Brock. + * @version $Revision: 1.1.2.1 $ + */ +public class Notification + extends java.util.EventObject +{ + // Constants --- + + // Attributes -- + + /** +* The notification type +*/ private String type = null; + + /** +* The sequence number of the notification +*/ private long sequenceNumber = 0; + + /** +* The message of the notification +*/ private String message = null; + + /** +* The time of the notification +*/ private long timeStamp = System.currentTimeMillis(); + + /** +* The user data of the notification +*/ private Object userData = null; - - - public Notification(java.lang.String type, - java.lang.Object source, - long sequenceNumber) { + + /** +* The source of the notification +*/ + private Object mySource = null; + + // Static -- + + // Constructors + + /** +* Create a new notification +* +* @param type the type of the notification +* @param source the source of the notification +* @param sequenceNumber the sequence number of the notification +*/ + public Notification(String type, + Object source, + long sequenceNumber) + { super(source); + mySource = source; this.type = type; this.sequenceNumber = sequenceNumber; this.timeStamp = System.currentTimeMillis(); } - - public Notification(java.lang.String type, - java.lang.Object source, + + /** +* Create a new notification +* +* @param type the type of the notification +* @param source the source of the notification +* @param sequenceNumber the sequence number of the notification +* @param message the message of the notification +*/ + public Notification(String type, + Object source, long sequenceNumber, - java.lang.String message) { + String message) + { this(type, source, sequenceNumber); this.message = message; this.timeStamp = System.currentTimeMillis(); } - public Notification(java.lang.String type, - java.lang.Object source, + /** +* Create a new notification +* +* @param type the type of the notification +* @param source the source of the notification +* @param sequenceNumber the sequence number of the notification +* @param timeStamp the time of the notification +*/ + public Notification(String type, + Object source, long sequenceNumber, - long timeStamp) { + long timeStamp) + { this(type, source, sequenceNumber); this.timeStamp = timeStamp; } - public Notification(java.lang.String type, - java.lang.Object source, + /** +* Create a new notification +* +* @param type the type of the notification +* @param source the source of the notification +* @param sequenceNumber the sequence number of the notification +* @param timeStamp the time of the notification +* @param message the message of the notification +*/ + public Notification(Str
[JBoss-dev] CVS update: jmx/src/main/test/compliance/monitor MonitorTestCase.java
User: ejort Date: 02/03/29 02:44:32 Modified:src/main/test/compliance/monitor Tag: BranchMX_1_0 MonitorTestCase.java Log: More monitor testing Revision ChangesPath No revision No revision 1.1.2.2 +1316 -178 jmx/src/main/test/compliance/monitor/MonitorTestCase.java Index: MonitorTestCase.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/MonitorTestCase.java,v retrieving revision 1.1.2.1 retrieving revision 1.1.2.2 diff -u -r1.1.2.1 -r1.1.2.2 --- MonitorTestCase.java 24 Mar 2002 11:50:27 - 1.1.2.1 +++ MonitorTestCase.java 29 Mar 2002 10:44:32 - 1.1.2.2 @@ -23,9 +23,11 @@ import java.util.ArrayList; import java.util.Date; +import java.util.HashSet; import java.util.Iterator; import javax.management.Attribute; +import javax.management.MBeanNotificationInfo; import javax.management.MBeanServer; import javax.management.MBeanServerFactory; import javax.management.ObjectName; @@ -37,9 +39,9 @@ import javax.management.monitor.MonitorNotification; import javax.management.monitor.StringMonitor; +import junit.framework.AssertionFailedError; import junit.framework.TestCase; - /** * Monitor Notification Tests * @@ -64,64 +66,998 @@ ObjectName monitorName; /** -* The monitor +* The monitor +*/ + Monitor monitor; + + /** +* The object name of the mbean monitored +*/ + ObjectName monitoredName; + + /** +* The monitored mbean +*/ + MonitorSupport monitored; + + /** +* The notifications +*/ + ArrayList notifications = new ArrayList(); + + // Constructor - + + /** +* Construct the test +*/ + public MonitorTestCase(String s) + { + super(s); + } + + // Tests --- + + /** +* Test notification types differ +*/ + public void testNotificationTypes() + { + assertEquals(MonitorNotification.OBSERVED_ATTRIBUTE_ERROR, + "jmx.monitor.error.attribute"); + assertEquals(MonitorNotification.OBSERVED_ATTRIBUTE_TYPE_ERROR, + "jmx.monitor.error.type"); + assertEquals(MonitorNotification.OBSERVED_OBJECT_ERROR, + "jmx.monitor.error.mbean"); + assertEquals(MonitorNotification.RUNTIME_ERROR, + "jmx.monitor.error.runtime"); + assertEquals(MonitorNotification.STRING_TO_COMPARE_VALUE_DIFFERED, + "jmx.monitor.string.differs"); + assertEquals(MonitorNotification.STRING_TO_COMPARE_VALUE_MATCHED, + "jmx.monitor.string.matches"); + assertEquals(MonitorNotification.THRESHOLD_ERROR, + "jmx.monitor.error.threshold"); + assertEquals(MonitorNotification.THRESHOLD_HIGH_VALUE_EXCEEDED, + "jmx.monitor.gauge.high"); + assertEquals(MonitorNotification.THRESHOLD_LOW_VALUE_EXCEEDED, + "jmx.monitor.gauge.low"); + assertEquals(MonitorNotification.THRESHOLD_VALUE_EXCEEDED, + "jmx.monitor.counter.threshold"); + } + + // Counter monitor notification info --- + + /** +* Test the notification info of the counter +*/ + public void testCounterNotificationInfo() + throws Exception + { + HashSet expected = new HashSet(); + expected.add(MonitorNotification.OBSERVED_ATTRIBUTE_ERROR); + expected.add(MonitorNotification.OBSERVED_ATTRIBUTE_TYPE_ERROR); + expected.add(MonitorNotification.OBSERVED_OBJECT_ERROR); + expected.add(MonitorNotification.RUNTIME_ERROR); + expected.add(MonitorNotification.THRESHOLD_ERROR); + expected.add(MonitorNotification.THRESHOLD_VALUE_EXCEEDED); + + MBeanNotificationInfo[] mbni = new CounterMonitor().getNotificationInfo(); + checkNotificationInfo("Counter", mbni, expected); + } + + // Counter normal no offset no modulus tests --- + + /** +* Test normal counter threshold no offset no modulus +*/ + public void testNormalCounterThresholdExceededEarlyNoOffsetNoModulus() + throws Exception + { + initTest(); + try + { + initCounterMonitor(true, new Integer(10), +false, new Integer(0), new Integer(0)); + expectStartMonitor(new Integer(10), +MonitorNotification.THRESHOLD_VALUE_EXCEEDED); + } + finally + { + stopMonitor(); + MBeanServerFactory.releaseMBeanServer(s
[JBoss-dev] CVS update: jmx/src/main/test/compliance/monitor/support CounterSupport.java GaugeSupport.java MonitorSupport.java StringSupport.java
User: ejort Date: 02/03/29 02:44:32 Modified:src/main/test/compliance/monitor/support Tag: BranchMX_1_0 CounterSupport.java GaugeSupport.java MonitorSupport.java StringSupport.java Log: More monitor testing Revision ChangesPath No revision No revision 1.1.2.2 +2 -8 jmx/src/main/test/compliance/monitor/support/CounterSupport.java Index: CounterSupport.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/support/CounterSupport.java,v retrieving revision 1.1.2.1 retrieving revision 1.1.2.2 diff -u -r1.1.2.1 -r1.1.2.2 --- CounterSupport.java 24 Mar 2002 11:50:27 - 1.1.2.1 +++ CounterSupport.java 29 Mar 2002 10:44:32 - 1.1.2.2 @@ -15,15 +15,9 @@ public Number getValue() { + unlock("get"); lock("get"); - try - { -return value; - } - finally - { -unlock("get"); - } + return value; } public void setValue(Number value) 1.1.2.2 +2 -8 jmx/src/main/test/compliance/monitor/support/GaugeSupport.java Index: GaugeSupport.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/support/GaugeSupport.java,v retrieving revision 1.1.2.1 retrieving revision 1.1.2.2 diff -u -r1.1.2.1 -r1.1.2.2 --- GaugeSupport.java 24 Mar 2002 11:50:27 - 1.1.2.1 +++ GaugeSupport.java 29 Mar 2002 10:44:32 - 1.1.2.2 @@ -15,15 +15,9 @@ public Number getValue() { + unlock("get"); lock("get"); - try - { -return value; - } - finally - { -unlock("get"); - } + return value; } public void setValue(Number value) 1.1.2.2 +10 -4 jmx/src/main/test/compliance/monitor/support/MonitorSupport.java Index: MonitorSupport.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/support/MonitorSupport.java,v retrieving revision 1.1.2.1 retrieving revision 1.1.2.2 diff -u -r1.1.2.1 -r1.1.2.2 --- MonitorSupport.java 24 Mar 2002 11:50:27 - 1.1.2.1 +++ MonitorSupport.java 29 Mar 2002 10:44:32 - 1.1.2.2 @@ -11,25 +11,31 @@ public class MonitorSupport { - String last = "get"; + boolean done = false; + String last = "set"; public synchronized void lock(String who) { - if (last.equals(who)) + if (!done && last.equals(who)) { try { wait(MonitorSUITE.MAX_WAIT); } catch (InterruptedException e) {} - if (last.equals(who)) + if (!done && last.equals(who)) throw new RuntimeException("-- Time Out --"); } } public synchronized void unlock(String who) { - if (last.equals(who)) + if (!done && last.equals(who)) throw new RuntimeException("-- Synchronization failure --"); last=who; + notifyAll(); + } + public synchronized void end() + { + done = true; notifyAll(); } } 1.1.2.2 +2 -9 jmx/src/main/test/compliance/monitor/support/StringSupport.java Index: StringSupport.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/support/StringSupport.java,v retrieving revision 1.1.2.1 retrieving revision 1.1.2.2 diff -u -r1.1.2.1 -r1.1.2.2 --- StringSupport.java24 Mar 2002 11:50:27 - 1.1.2.1 +++ StringSupport.java29 Mar 2002 10:44:32 - 1.1.2.2 @@ -15,20 +15,13 @@ public String getValue() { + unlock("get"); lock("get"); - try - { -return value; - } - finally - { -unlock("get"); - } + return value; } public void setValue(String value) { - lock("set"); this.value = value; } ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jmx/src/main/javax/management/monitor CounterMonitor.java
User: ejort Date: 02/03/29 02:44:32 Modified:src/main/javax/management/monitor Tag: BranchMX_1_0 CounterMonitor.java Log: More monitor testing Revision ChangesPath No revision No revision 1.1.2.2 +8 -2 jmx/src/main/javax/management/monitor/CounterMonitor.java Index: CounterMonitor.java === RCS file: /cvsroot/jboss/jmx/src/main/javax/management/monitor/CounterMonitor.java,v retrieving revision 1.1.2.1 retrieving revision 1.1.2.2 diff -u -r1.1.2.1 -r1.1.2.2 --- CounterMonitor.java 24 Mar 2002 11:50:27 - 1.1.2.1 +++ CounterMonitor.java 29 Mar 2002 10:44:32 - 1.1.2.2 @@ -19,9 +19,15 @@ * * Reset the threshold when the value becomes negative in difference mode * + * 20020326 Adrian Brock: + * + * The spec says the modulus should be *strictly* exceeded. It appears + * from testing the RI, it is a mathematical definition of modulus. e.g. + * 10 exceeds a modulus of 10 + * * * @author mailto:[EMAIL PROTECTED]";>Adrian Brock - * @version $Revision: 1.1.2.1 $ + * @version $Revision: 1.1.2.2 $ * */ public class CounterMonitor @@ -285,7 +291,7 @@ // For normal mode, restart when modulus exceeded if (differenceMode == false && modulus.longValue() != 0 && -number.longValue() > modulus.longValue()) +number.longValue() >= modulus.longValue()) { threshold = initialThreshold; alreadyNotified &= ~THRESHOLD_EXCEEDED_NOTIFIED; ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jmx/src/main/test/compliance/notcompliant/support InterfaceProblems.java InterfaceProblemsMBean.java InterfaceProblemsSuperMBean.java OverloadedAttribute4.java OverloadedAttribute4MBean.java OverloadedAttribute5.java OverloadedAttribute5MBean.java
User: ejort Date: 02/03/29 02:40:47 Added: src/main/test/compliance/notcompliant/support Tag: BranchMX_1_0 InterfaceProblems.java InterfaceProblemsMBean.java InterfaceProblemsSuperMBean.java OverloadedAttribute4.java OverloadedAttribute4MBean.java OverloadedAttribute5.java OverloadedAttribute5MBean.java Log: Added new tests for Standard MetaData Revision ChangesPath No revision No revision 1.1.2.1 +24 -0 jmx/src/main/test/compliance/notcompliant/support/Attic/InterfaceProblems.java 1.1.2.1 +14 -0 jmx/src/main/test/compliance/notcompliant/support/Attic/InterfaceProblemsMBean.java 1.1.2.1 +13 -0 jmx/src/main/test/compliance/notcompliant/support/Attic/InterfaceProblemsSuperMBean.java 1.1.2.1 +23 -0 jmx/src/main/test/compliance/notcompliant/support/Attic/OverloadedAttribute4.java 1.1.2.1 +13 -0 jmx/src/main/test/compliance/notcompliant/support/Attic/OverloadedAttribute4MBean.java 1.1.2.1 +23 -0 jmx/src/main/test/compliance/notcompliant/support/Attic/OverloadedAttribute5.java 1.1.2.1 +13 -0 jmx/src/main/test/compliance/notcompliant/support/Attic/OverloadedAttribute5MBean.java ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jmx/src/main/test/compliance/notcompliant NCMBeanTEST.java
User: ejort Date: 02/03/29 02:40:47 Modified:src/main/test/compliance/notcompliant Tag: BranchMX_1_0 NCMBeanTEST.java Log: Added new tests for Standard MetaData Revision ChangesPath No revision No revision 1.1.2.1 +66 -23jmx/src/main/test/compliance/notcompliant/NCMBeanTEST.java Index: NCMBeanTEST.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/notcompliant/NCMBeanTEST.java,v retrieving revision 1.1 retrieving revision 1.1.2.1 diff -u -r1.1 -r1.1.2.1 --- NCMBeanTEST.java 18 Jan 2002 17:28:41 - 1.1 +++ NCMBeanTEST.java 29 Mar 2002 10:40:46 - 1.1.2.1 @@ -1,14 +1,14 @@ -/* - * JBoss, the OpenSource J2EE webOS - * - * Distributable under LGPL license. - * See terms of license at gnu.org. - */ -package test.compliance.notcompliant; - -import junit.framework.TestCase; - -import javax.management.MalformedObjectNameException; +/* + * JBoss, the OpenSource J2EE webOS + * + * Distributable under LGPL license. + * See terms of license at gnu.org. + */ +package test.compliance.notcompliant; + +import junit.framework.TestCase; + +import javax.management.MalformedObjectNameException; import javax.management.ObjectName; import javax.management.MBeanServerFactory; import javax.management.MBeanServer; @@ -17,16 +17,19 @@ import java.util.Hashtable; import test.compliance.notcompliant.support.OverloadedAttribute1; -import test.compliance.notcompliant.support.OverloadedAttribute3; import test.compliance.notcompliant.support.OverloadedAttribute2; -import test.compliance.notcompliant.support.DynamicAndStandard; - -public class NCMBeanTEST extends TestCase -{ - public NCMBeanTEST(String s) - { - super(s); - } +import test.compliance.notcompliant.support.OverloadedAttribute3; +import test.compliance.notcompliant.support.OverloadedAttribute4; +import test.compliance.notcompliant.support.OverloadedAttribute5; +import test.compliance.notcompliant.support.InterfaceProblems; +import test.compliance.notcompliant.support.DynamicAndStandard; + +public class NCMBeanTEST extends TestCase +{ + public NCMBeanTEST(String s) + { + super(s); + } public void testOverloadedAttribute1() { @@ -43,6 +46,16 @@ registerAndTest(new OverloadedAttribute3()); } + public void testOverloadedAttribute4() + { + registerAndTest(new OverloadedAttribute4()); + } + + public void testOverloadedAttribute5() + { + registerAndTest(new OverloadedAttribute5()); + } + public void testMixedDynamicStandard() { registerAndTest(new DynamicAndStandard()); @@ -52,12 +65,17 @@ { registerAndTest(new NoConstructor()); } - + + public void testInterfaceProblems() + { + registerAndDontTest(new InterfaceProblems()); + } + private void registerAndTest(Object mbean) { + MBeanServer server = MBeanServerFactory.createMBeanServer(); try { - MBeanServer server = MBeanServerFactory.newMBeanServer(); server.registerMBean(mbean, new ObjectName("test:foo=bar")); fail("expected a NotCompliantMBeanException for " + mbean.getClass().getName()); } @@ -69,5 +87,30 @@ { fail("unexpected exception when registering " + mbean.getClass().getName() + ": " + e.getMessage()); } + finally + { + MBeanServerFactory.releaseMBeanServer(server); + } + } + + private void registerAndDontTest(Object mbean) + { + MBeanServer server = MBeanServerFactory.createMBeanServer(); + try + { + server.registerMBean(mbean, new ObjectName("test:foo=bar")); + } + catch (NotCompliantMBeanException e) + { + fail("FAILS IN RI: Cannot cope with overriden get/is in interfaces"); + } + catch (Exception e) + { + fail("unexpected exception when registering " + mbean.getClass().getName() + ": " + e.getMessage()); + } + finally + { + MBeanServerFactory.releaseMBeanServer(server); + } } -} +} ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jmx/src/main/org/jboss/mx/metadata StandardMetaData.java
User: ejort Date: 02/03/29 02:38:35 Modified:src/main/org/jboss/mx/metadata Tag: BranchMX_1_0 StandardMetaData.java Log: Fix the standard mbean validation Revision ChangesPath No revision No revision 1.6.2.1 +20 -7 jmx/src/main/org/jboss/mx/metadata/StandardMetaData.java Index: StandardMetaData.java === RCS file: /cvsroot/jboss/jmx/src/main/org/jboss/mx/metadata/StandardMetaData.java,v retrieving revision 1.6 retrieving revision 1.6.2.1 diff -u -r1.6 -r1.6.2.1 --- StandardMetaData.java 26 Feb 2002 02:02:59 - 1.6 +++ StandardMetaData.java 29 Mar 2002 10:38:35 - 1.6.2.1 @@ -66,7 +66,7 @@ HashMap getters = new HashMap(); HashMap setters = new HashMap(); - List operInfo = new ArrayList(); + HashMap operInfo = new HashMap(); List attrInfo = new ArrayList(); for (int i = 0; i < methods.length; ++i) @@ -78,24 +78,37 @@ if (methodName.startsWith("set") && signature.length == 1 && returnType == Void.TYPE) { String key = methodName.substring(3, methodName.length()); - if (setters.get(key) != null) + Method setter = (Method) setters.get(key); + if (setter != null && setter.getParameterTypes()[0].equals(signature[0]) == false) { - throw new IntrospectionException("overloaded type for attribute: " + key); + throw new IntrospectionException("overloaded type for attribute set: " + key); } setters.put(key, methods[i]); } else if (methodName.startsWith("get") && signature.length == 0 && returnType != Void.TYPE) { - getters.put(methodName.substring(3, methodName.length()), methods[i]); + String key = methodName.substring(3, methodName.length()); + Method getter = (Method) getters.get(key); + if (getter != null && getter.getName().startsWith("get") == false) + { + throw new IntrospectionException("mixed use of get/is for attribute " + key); + } + getters.put(key, methods[i]); } else if (methodName.startsWith("is") && signature.length == 0 && (returnType == Boolean.class || returnType == Boolean.TYPE)) { - getters.put(methodName.substring(2, methodName.length()), methods[i]); + String key = methodName.substring(2, methodName.length()); + Method getter = (Method) getters.get(key); + if (getter != null && getter.getName().startsWith("is") == false) + { + throw new IntrospectionException("mixed use of get/is for attribute " + key); + } + getters.put(key, methods[i]); } else { MBeanOperationInfo info = new MBeanOperationInfo("MBean Operation.", methods[i]); - operInfo.add(info); + operInfo.put(methods[i].toString(), info); } } @@ -120,7 +133,7 @@ // save away the attribute and operation info objects MBeanAttributeInfo[] attributeInfo = (MBeanAttributeInfo[]) attrInfo.toArray(new MBeanAttributeInfo[0]); - MBeanOperationInfo[] operationInfo = (MBeanOperationInfo[]) operInfo.toArray(new MBeanOperationInfo[0]); + MBeanOperationInfo[] operationInfo = (MBeanOperationInfo[]) operInfo.values().toArray(new MBeanOperationInfo[0]); MBeanNotificationInfo[] notifications = null; if (mbeanInstance instanceof NotificationBroadcaster) ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jboss/src/main/org/jboss/invocation MarshalledInvocation.java
User: ejort Date: 02/03/29 02:17:19 Modified:src/main/org/jboss/invocation MarshalledInvocation.java Log: Fixed a memory leak in the method hashes Revision ChangesPath 1.8 +5 -9 jboss/src/main/org/jboss/invocation/MarshalledInvocation.java Index: MarshalledInvocation.java === RCS file: /cvsroot/jboss/jboss/src/main/org/jboss/invocation/MarshalledInvocation.java,v retrieving revision 1.7 retrieving revision 1.8 diff -u -r1.7 -r1.8 --- MarshalledInvocation.java 7 Mar 2002 18:59:52 - 1.7 +++ MarshalledInvocation.java 29 Mar 2002 10:17:18 - 1.8 @@ -34,7 +34,7 @@ * * @see * @author mailto:[EMAIL PROTECTED]";>Marc Fleury -* @version $Revision: 1.7 $ +* @version $Revision: 1.8 $ * Revisions: * * Revisions: @@ -76,7 +76,7 @@ * @param intf * @return */ - public static Map getInterfaceHashes(Class intf, boolean methodToLong) + public static Map getInterfaceHashes(Class intf) { // Create method hashes Method[] methods = intf.getDeclaredMethods(); @@ -103,11 +103,7 @@ byte abyte0[] = messagedigest.digest(); for(int j = 0; j < Math.min(8, abyte0.length); j++) hash += (long)(abyte0[j] & 0xff) << j * 8; -if (methodToLong) - map.put(method, new Long(hash)); -else - map.put(new Long(hash), method); - +map.put(method.toString(), new Long(hash)); } catch (Exception e) { @@ -169,7 +165,7 @@ if (methodHashes == null) { - methodHashes = getInterfaceHashes(method.getDeclaringClass(), true); + methodHashes = getInterfaceHashes(method.getDeclaringClass()); // Copy and add WeakHashMap newHashMap = new WeakHashMap(); @@ -178,7 +174,7 @@ hashMap = newHashMap; } - return ((Long)methodHashes.get(method)).longValue(); + return ((Long)methodHashes.get(method.toString())).longValue(); } // Constructors -- ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] CVS update: jbossmq/src/main/org/jboss/mq/server JMSServer.
Hi, This breaks on Windows :-( The id is used as a file name in file persistence. You are not allowed a : in the file name for windows. Regards, Adrian > User: lqd > Date: 02/03/25 22:55:34 > > Modified:src/main/org/jboss/mq/server > r JMSServer.java > Log: > Fix for bug #533824. JMS spec requoires the > e MessageID to be prefixed > with 'ID:' instead of just 'ID' > > Revision ChangesPath > 1.17 +2 -2 > 2 > > > > jbossmq/src/main/org/jboss/mq/server/JMSServer.java > > Index: JMSServer.java > > = > = > RCS file: > : > /cvsroot/jboss/jbossmq/src/main/org/jboss/mq/server/JM > Server.java,v > retrieving revision 1.16 > retrieving revision 1.17 > diff -u -r1.16 -r1.17 > --- JMSServer.java 9 Mar 2002 15:32:34 - 1.16 > +++ JMSServer.java 26 Mar 2002 06:55:34 - 1.17 > @@ -52,7 +52,7 @@ > * @authorHiram Chirino > ino ([EMAIL PROTECTED]) > * @authorDavid Maplesden > den ([EMAIL PROTECTED]) > * @author mailto:[EMAIL PROTECTED]";>Peter > ter Antman > - * @version $Revision: 1.16 $ > + * @version $Revision: 1.17 $ > */ >public class JMSServer implements JMSServerInvoker >{ > @@ -239,7 +239,7 @@ > { >synchronized (idLock) >{ > - ID = "ID" + (new > w Integer(lastID++).toString()); > + ID = "ID:" + (new > w Integer(lastID++).toString()); >} >stateManager.addLoggedOnClientId(ID); >break; > > > > > ___ > Jboss-development mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-dev > lopment _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11593 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] JMX HTML... From the Pure Fluff Department...
It is a Sun utility, it comes from jmxtools.jar and is just a front-end to the MBeanServer. As part of JBossMX we want to provide a better version. Mainly for security, but there are other improvements, making it pretty is just one. You need to remember that it needs to run embedded within JBoss. There might not be a web container. Of course, there could be two versions. One for embedded, and one using servlets/jsp. Regards, Adrian > What would it take to pretty up the output from the > JMX HTML adapter? > > Since a lot of folks will probably be using that to > manage the server, we > might want to think about beautifying it a bit... > Nothing fancy or > cumbersome, but a little sprucing up here and > there... > > I'm happy to see what I can contribute here, we have > a team of top notch Web > guys that I could steal some time from... > > Does anyone know off-hand where this is generated? > I'll go poking around... > > Hunter > > > ___ > Jboss-development mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-dev > lopment _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11618 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: build/jbossmq build.xml
User: ejort Date: 02/03/24 09:38:31 Modified:jbossmq build.xml Log: Integrate JBossMX into JBossMQ standalone, bring the build up-to-date Revision ChangesPath 1.14 +382 -158 build/jbossmq/build.xml Index: build.xml === RCS file: /cvsroot/jboss/build/jbossmq/build.xml,v retrieving revision 1.13 retrieving revision 1.14 diff -u -r1.13 -r1.14 --- build.xml 28 Feb 2002 04:39:24 - 1.13 +++ build.xml 24 Mar 2002 17:38:30 - 1.14 @@ -12,7 +12,7 @@ - + @@ -108,6 +108,10 @@ + + + + @@ -128,6 +132,10 @@ + + + + @@ -172,15 +180,31 @@ + + + + + + - + @@ -222,21 +246,16 @@ + + - - - - - - - - + @@ -262,6 +281,36 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -272,8 +321,8 @@ value="${project.root}/${_module.name}/output"/> - - + + @@ -299,32 +348,47 @@ - + - - + + - - - + + + - + - + - + + + + + + + + + + + + + + + + - + @@ -332,142 +396,212 @@ + + + + + + + + - + - - + + - + + - - - + + + - - + - - - + + + + + + - - + + + + + + + + + - - - + + + + + + + - - + + + + + + + + + + + + + - --> + + + + + - - - + + - + - --> - - - + + + + - --> + - - - + + + + ---> - - + + + + + + + + + + + + + + + + + + + + + + + + - - - - + + + + + + - - + + + + - --> - - + + + + - --> + - - + + + + + + + + + + + + - --> - - + + + - + + + + - + - - - + - + @@ -476,53 +610,59 @@ - - - - - - - - - - - - - - - - - + + + + - - - + + + + + + + + + + + - - - - - + + + + + + + - -
[JBoss-dev] CVS update: build/jbossmq/etc version.mf
User: ejort Date: 02/03/24 09:38:31 Added: jbossmq/etc version.mf Log: Integrate JBossMX into JBossMQ standalone, bring the build up-to-date Revision ChangesPath 1.1 build/jbossmq/etc/version.mf Index: version.mf === Specification-Title: [EMAIL PROTECTED]@[EMAIL PROTECTED]@[EMAIL PROTECTED]@@version.tag@ Specification-Version: @version.major@[EMAIL PROTECTED]@[EMAIL PROTECTED]@@version.tag@ Specification-Vendor: JBoss Group, LLC Implementation-Title: [EMAIL PROTECTED]@[EMAIL PROTECTED]@[EMAIL PROTECTED]@@version.tag@ [EMAIL PROTECTED]@ Implementation-Version: @version.major@[EMAIL PROTECTED]@[EMAIL PROTECTED]@@version.tag@ Date:@build.id@ Implementation-Vendor: JBoss Group, LLC ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] JBossMX and JBossMQ standalone
Hi Hiram, I've got a bootable system now. It is a bit bloated for standalone JBossMQ. I've converted it to Jason's latest build system. I'll commit soon and leave you to cut out the fat :-) Regards, Adrian > > Ahh, yep it's out of date. It's been a while since I > did a standalone > build. If you want, I'll look into bringing the > build upto date. > > Regards, > Hiram > > >From: Adrian Brock <[EMAIL PROTECTED]> > >Reply-To: [EMAIL PROTECTED] > >To: [EMAIL PROTECTED] > >Subject: Re: [JBoss-dev] JBossMX and JBossMQ > standalone > >Date: Sun, 24 Mar 2002 09:44:51 -0600 > > > >Hi Hiram, > > > >I'm not sure I'm doing this correctly. > > > >JBossMQ standalone includes JBossServer. > >The standalone version hasn't been update with > >the system, common, management module changes. > >It also has a missing version.mf that I've added. > > > >I'm going to keep going, but it is getting closer > >to jboss-all? > > > >Regards, > >Adrian > > > > > > > > Yes please modify. The standalone JBossMQ should > run > > > under the same > > > enviorment that the integrated one does. So if > JBoss > > > is making the switch > > > to JBossMX, JBossMQ should do the same also. > Makes > > > maintenance easier. > > > > > > Regards, > > > Hiram > > > > > > >From: Adrian Brock <[EMAIL PROTECTED]> > > > >Reply-To: > [EMAIL PROTECTED] > > > >To: [EMAIL PROTECTED] > > > >Subject: [JBoss-dev] JBossMX and JBossMQ > standalone > > > >Date: Sat, 23 Mar 2002 16:29:44 -0600 > > > > > > > >There is a standalone checkout of JBossMQ that > is > > > >still using jmxri.jar > > > > > > > >Part of the reason for doing the integration is > to > > > stop > > > >developers using invoke() to get/set attributes. > > > >Something that should never have been allowed > and > > > will be > > > >stopped in the RI from JMX1.1 > > > > > > > >I can modify this, but it means modifying > > > CVSROOT/modules > > > >to include the jmx module. > > > > > > > >I can do this, but should I? > > > > > > > >Regards, > > > >Adrian > > > > >_ > > > ___ > > > >View thread online: > > > > http://main.jboss.org/thread.jsp?forum=66&thread=11480 > > > > > > > >___ > > > >Jboss-development mailing list > > > >[EMAIL PROTECTED] > > > > >https://lists.sourceforge.net/lists/listinfo/jboss-de > > > elopment > > > > > > > > > > > > > > > > __ > > > __ > > > Join the worlds largest e-mail service with MSN > > > Hotmail. > > > http://www.hotmail.com > > > > > > > > > ___ > > > Jboss-development mailing list > > > [EMAIL PROTECTED] > > > > https://lists.sourceforge.net/lists/listinfo/jboss-dev > > > lopment > > > > > >_ > ___ > >View thread online: > http://main.jboss.org/thread.jsp?forum=66&thread=11488 > > > >___ > >Jboss-development mailing list > >[EMAIL PROTECTED] > >https://lists.sourceforge.net/lists/listinfo/jboss-de > elopment > > > > > __ > __ > Join the worlds largest e-mail service with MSN > Hotmail. > http://www.hotmail.com > > > ___ > Jboss-development mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-dev > lopment _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11502 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] jboss-all daily clean failed
> Hi, > > --- Adrian Brock <[EMAIL PROTECTED]> wrote: > > Have I broken the hourly compile? > > > > I noticed last night's test runs didn't clobber > > the testsuite first. The cluster tests still > failed. > > > > I requested a full checkout, and since then it has > > been reporting a missing build.sh > > > > It went AWOL for some reason... I think it is back to > normal now. I > think I have stopped it sending these messages too - > they should be > for me only. The list should only get compile/test > failures. > > What surprised me was that the jdk1.4 tests worked > this morning too! This is an additional feature of JBossMX I forgot to mention :-) > Although they only ran as quick as the IBM jdk1.3 > test... > > Chris > > = > http://www.soccer2002.org.uk - join in and win CA$H! > > __ > Do You Yahoo!? > Yahoo! Movies - coverage of the 74th Academy Awards® > http://movies.yahoo.com/ > > ___ > Jboss-development mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-dev > lopment Regards, Adrian _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=8978 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: CVSROOT modules
User: ejort Date: 02/03/24 09:12:21 Modified:.modules Log: Standalone jbossmq needs pool and connector as well Revision ChangesPath 1.109 +2 -0 CVSROOT/modules Index: modules === RCS file: /cvsroot/jboss/CVSROOT/modules,v retrieving revision 1.108 retrieving revision 1.109 diff -u -r1.108 -r1.109 --- modules 24 Mar 2002 15:47:56 - 1.108 +++ modules 24 Mar 2002 17:12:21 - 1.109 @@ -197,6 +197,8 @@ _jboss_j2ee \ _jboss_management \ _jboss_naming \ +_jboss_pool \ +_jboss_connector \ _jboss_server \ _jboss_messaging \ _jboss_security ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: CVSROOT modules
User: ejort Date: 02/03/24 07:47:57 Modified:.modules Log: Add JBossManagement to JBossMQ standalone Revision ChangesPath 1.108 +1 -0 CVSROOT/modules Index: modules === RCS file: /cvsroot/jboss/CVSROOT/modules,v retrieving revision 1.107 retrieving revision 1.108 diff -u -r1.107 -r1.108 --- modules 24 Mar 2002 15:27:33 - 1.107 +++ modules 24 Mar 2002 15:47:56 - 1.108 @@ -195,6 +195,7 @@ _jboss_system \ _jboss_jmx \ _jboss_j2ee \ +_jboss_management \ _jboss_naming \ _jboss_server \ _jboss_messaging \ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] JBossMX and JBossMQ standalone
Hi Hiram, I'm not sure I'm doing this correctly. JBossMQ standalone includes JBossServer. The standalone version hasn't been update with the system, common, management module changes. It also has a missing version.mf that I've added. I'm going to keep going, but it is getting closer to jboss-all? Regards, Adrian > > Yes please modify. The standalone JBossMQ should run > under the same > enviorment that the integrated one does. So if JBoss > is making the switch > to JBossMX, JBossMQ should do the same also. Makes > maintenance easier. > > Regards, > Hiram > > >From: Adrian Brock <[EMAIL PROTECTED]> > >Reply-To: [EMAIL PROTECTED] > >To: [EMAIL PROTECTED] > >Subject: [JBoss-dev] JBossMX and JBossMQ standalone > >Date: Sat, 23 Mar 2002 16:29:44 -0600 > > > >There is a standalone checkout of JBossMQ that is > >still using jmxri.jar > > > >Part of the reason for doing the integration is to > stop > >developers using invoke() to get/set attributes. > >Something that should never have been allowed and > will be > >stopped in the RI from JMX1.1 > > > >I can modify this, but it means modifying > CVSROOT/modules > >to include the jmx module. > > > >I can do this, but should I? > > > >Regards, > >Adrian > >_ > ___ > >View thread online: > http://main.jboss.org/thread.jsp?forum=66&thread=11480 > > > >___ > >Jboss-development mailing list > >[EMAIL PROTECTED] > >https://lists.sourceforge.net/lists/listinfo/jboss-de > elopment > > > > > __ > __ > Join the worlds largest e-mail service with MSN > Hotmail. > http://www.hotmail.com > > > ___ > Jboss-development mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-dev > lopment _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11488 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: CVSROOT modules
User: ejort Date: 02/03/24 07:27:33 Modified:.modules Log: Standalone JBossMQ missing the common and system modules Revision ChangesPath 1.107 +2 -0 CVSROOT/modules Index: modules === RCS file: /cvsroot/jboss/CVSROOT/modules,v retrieving revision 1.106 retrieving revision 1.107 diff -u -r1.106 -r1.107 --- modules 24 Mar 2002 15:16:47 - 1.106 +++ modules 24 Mar 2002 15:27:33 - 1.107 @@ -191,6 +191,8 @@ jbossmq-modules -a \ _jbossmq_build \ +_jboss_common \ +_jboss_system \ _jboss_jmx \ _jboss_j2ee \ _jboss_naming \ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: CVSROOT modules
User: ejort Date: 02/03/24 07:16:47 Modified:.modules Log: Add JBossMX thirdparty support to JBossMQ standalone Revision ChangesPath 1.106 +8 -6 CVSROOT/modules Index: modules === RCS file: /cvsroot/jboss/CVSROOT/modules,v retrieving revision 1.105 retrieving revision 1.106 diff -u -r1.105 -r1.106 --- modules 24 Mar 2002 14:43:18 - 1.105 +++ modules 24 Mar 2002 15:16:47 - 1.106 @@ -182,10 +182,12 @@ thirdparty/gnu \ thirdparty/hsql \ thirdparty/hsqldb \ +thirdparty/jdom \ thirdparty/junit \ thirdparty/oswego \ thirdparty/javagroups \ -thirdparty/sun +thirdparty/sun \ +thirdparty/xml jbossmq-modules -a \ _jbossmq_build \ @@ -210,15 +212,15 @@ &_jboss-mx-modules _jboss-mx-thirdparty-a \ -thirdparty/xml \ +thirdparty/apache/bcel \ +thirdparty/apache/log4j \ thirdparty/gnu \ -thirdparty/oswego \ -thirdparty/junit \ thirdparty/jdom \ +thirdparty/junit \ +thirdparty/oswego \ thirdparty/sun/jmx \ thirdparty/sun/jaxp \ -thirdparty/apache/log4j \ -thirdparty/apache/bcel +thirdparty/xml _jboss-mx-modules -a \ _jboss-mx_build \ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: CVSROOT modules
User: ejort Date: 02/03/24 06:43:19 Modified:.modules Log: Added JBossMX to standalone JBossMQ Revision ChangesPath 1.105 +1 -0 CVSROOT/modules Index: modules === RCS file: /cvsroot/jboss/CVSROOT/modules,v retrieving revision 1.104 retrieving revision 1.105 diff -u -r1.104 -r1.105 --- modules 10 Mar 2002 01:54:33 - 1.104 +++ modules 24 Mar 2002 14:43:18 - 1.105 @@ -189,6 +189,7 @@ jbossmq-modules -a \ _jbossmq_build \ +_jboss_jmx \ _jboss_j2ee \ _jboss_naming \ _jboss_server \ ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] jboss-all daily clean failed
Have I broken the hourly compile? I noticed last night's test runs didn't clobber the testsuite first. The cluster tests still failed. I requested a full checkout, and since then it has been reporting a missing build.sh Regards, Adrian _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=8978 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jmx/src/main/test/compliance/query QueryTestCase.java
User: ejort Date: 02/03/24 05:12:13 Modified:src/main/test/compliance/query QueryTestCase.java Log: merge RelMX_1_0_0_12 to RelMX_1_0_0_13 to dev branch Revision ChangesPath 1.2 +64 -0 jmx/src/main/test/compliance/query/QueryTestCase.java Index: QueryTestCase.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/query/QueryTestCase.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- QueryTestCase.java15 Mar 2002 20:26:40 - 1.1 +++ QueryTestCase.java24 Mar 2002 13:12:13 - 1.2 @@ -1001,6 +1001,38 @@ } /** +* Test threading, tests that running the same query in multiple threads +* works. This test might not catch a threading problem on every run. +*/ + public void testThreading() throws Exception + { + MBeanServer server1 = MBeanServerFactory.createMBeanServer("server1"); + MBeanServer server2 = MBeanServerFactory.createMBeanServer("server2"); + try + { + ObjectName name = new ObjectName("Domain1:type=instance1"); + NumberTest bean1 = new NumberTest(1); + NumberTest bean2 = new NumberTest(2); + server1.registerMBean(bean1, name); + server2.registerMBean(bean2, name); + QueryExp query = Query.eq(Query.attr("Number"), Query.value(2)); + QueryThread thread1 = new QueryThread(server1, query, 0); + QueryThread thread2 = new QueryThread(server2, query, 1); + thread1.start(); + thread2.start(); + thread1.join(1); + thread1.check(); + thread2.join(1); + thread2.check(); + } + finally + { + MBeanServerFactory.releaseMBeanServer(server1); + MBeanServerFactory.releaseMBeanServer(server2); + } + } + + /** * Test pathological */ public void testPathological() throws Exception @@ -1553,6 +1585,38 @@ { fail("Expected instance " + iterator.next() + "\nfor query " + queryExp); + } + } + } + + public class QueryThread + extends Thread + { + MBeanServer server; + QueryExp query; + int expected; + int result; + public QueryThread(MBeanServer server, QueryExp query, int expected) + { + this.server = server; + this.query = query; + this.expected = expected; + } + public int getExpected() + { + return expected; + } + public void check() + { + assertEquals(expected, result); + } + public void run() + { + for (int i = 0; i < 1000; i++) + { +result = server.queryNames(null, query).size(); +if (result != expected) + return; } } } ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jmx/src/main/test/compliance/monitor/support GaugeSupport.java GaugeSupportMBean.java MonitorSupport.java CounterSupport.java CounterSupportMBean.java StringSupport.java StringSupportMBean.java
User: ejort Date: 02/03/24 05:12:13 Modified:src/main/test/compliance/monitor/support CounterSupport.java CounterSupportMBean.java StringSupport.java StringSupportMBean.java Added: src/main/test/compliance/monitor/support GaugeSupport.java GaugeSupportMBean.java MonitorSupport.java Log: merge RelMX_1_0_0_12 to RelMX_1_0_0_13 to dev branch Revision ChangesPath 1.2 +31 -4 jmx/src/main/test/compliance/monitor/support/CounterSupport.java Index: CounterSupport.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/support/CounterSupport.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- CounterSupport.java 26 Jan 2002 21:02:21 - 1.1 +++ CounterSupport.java 24 Mar 2002 13:12:13 - 1.2 @@ -8,17 +8,44 @@ package test.compliance.monitor.support; public class CounterSupport + extends MonitorSupport implements CounterSupportMBean { - private int value; + private Number value; - public int getValue() + public Number getValue() { -return value; + lock("get"); + try + { +return value; + } + finally + { +unlock("get"); + } } - public void setValue(int value) + public void setValue(Number value) { this.value = value; + } + + public Number getWrongNull() + { +return null; + } + + public String getWrongType() + { +return "Wrong"; + } + + public Number getWrongException() + { + throw new RuntimeException("It is broke"); + } + public void setWriteOnly(Number value) + { } } 1.2 +6 -2 jmx/src/main/test/compliance/monitor/support/CounterSupportMBean.java Index: CounterSupportMBean.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/support/CounterSupportMBean.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- CounterSupportMBean.java 26 Jan 2002 21:02:21 - 1.1 +++ CounterSupportMBean.java 24 Mar 2002 13:12:13 - 1.2 @@ -9,6 +9,10 @@ public interface CounterSupportMBean { - public int getValue(); - public void setValue(int value); + public Number getValue(); + public void setValue(Number value); + public Number getWrongNull(); + public String getWrongType(); + public Number getWrongException(); + public void setWriteOnly(Number value); } 1.2 +29 -1 jmx/src/main/test/compliance/monitor/support/StringSupport.java Index: StringSupport.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/support/StringSupport.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- StringSupport.java26 Jan 2002 21:02:21 - 1.1 +++ StringSupport.java24 Mar 2002 13:12:13 - 1.2 @@ -8,17 +8,45 @@ package test.compliance.monitor.support; public class StringSupport + extends MonitorSupport implements StringSupportMBean { private String value; public String getValue() { -return value; + lock("get"); + try + { +return value; + } + finally + { +unlock("get"); + } } public void setValue(String value) { + lock("set"); this.value = value; + } + + public String getWrongNull() + { +return null; + } + + public Integer getWrongType() + { +return new Integer(0); + } + + public String getWrongException() + { + throw new RuntimeException("It is broke"); + } + public void setWriteOnly(String value) + { } } 1.2 +4 -0 jmx/src/main/test/compliance/monitor/support/StringSupportMBean.java Index: StringSupportMBean.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/support/StringSupportMBean.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- StringSupportMBean.java 26 Jan 2002 21:02:21 - 1.1 +++ StringSupportMBean.java 24 Mar 2002 13:12:13 - 1.2 @@ -11,4 +11,8 @@ { public String getValue(); public void setValue(String value); + public String getWrongNull(); + public Integer getWrongType(); + public String getWrongException(); + public void setWriteOnly(String value); } 1.2 +51 -0 jmx/src/main/test/compliance/monitor/support/GaugeSupport.java 1.2 +18 -0 jmx/src
[JBoss-dev] CVS update: jmx/src/main/javax/management/monitor CounterMonitor.java Monitor.java
User: ejort Date: 02/03/24 05:12:12 Modified:src/main/javax/management/monitor CounterMonitor.java Monitor.java Log: merge RelMX_1_0_0_12 to RelMX_1_0_0_13 to dev branch Revision ChangesPath 1.2 +390 -376 jmx/src/main/javax/management/monitor/CounterMonitor.java Index: CounterMonitor.java === RCS file: /cvsroot/jboss/jmx/src/main/javax/management/monitor/CounterMonitor.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- CounterMonitor.java 21 Dec 2001 01:39:37 - 1.1 +++ CounterMonitor.java 24 Mar 2002 13:12:12 - 1.2 @@ -1,376 +1,390 @@ -/* -* JBoss, the OpenSource EJB server -* -* Distributable under LGPL license. -* See terms of license at gnu.org. -*/ -package javax.management.monitor; - -import javax.management.MBeanAttributeInfo; -import javax.management.MBeanNotificationInfo; - -// REVIEW: Check synchronization - -/** - * The counter monitor service. - * - * @author mailto:[EMAIL PROTECTED]";>Adrian Brock - * @version $Revision$ - * - */ -public class CounterMonitor - extends Monitor - implements CounterMonitorMBean -{ - // Constants - - - /** - * The counter threshold exceeded has been notified. - */ - int THRESHOLD_EXCEEDED_NOTIFIED = 16; - - /** - * The threshold type error has been notified. - */ - int THRESHOLD_ERROR_NOTIFIED = 32; - - // Attributes - - /** - * The derived gauge. - */ - private Number derivedGauge = new Integer(0); - - /** - * The last value. - */ - private Number lastValue = null; - - /** - * The derived gauge timeStamp. - */ - private long derivedGaugeTimeStamp = 0; - - /** - * The offset. - */ - Number offset = new Integer(0); - - /** - * The modulus. - */ - Number modulus = new Integer(0); - - /** - * The threshold. - */ - Number threshold = new Integer(0); - - /** - * The last stated threshold. - */ - Number lastThreshold = new Integer(0); - - /** - * Difference mode. - */ - boolean differenceMode = false; - - /** - * Notify. - */ - boolean notify = false; - - // Static - - // Constructors -- - - /** - * Default Constructor - */ - public CounterMonitor() - { -dbgTag = "CounterMonitor"; - } - - // Public - - public MBeanNotificationInfo[] getNotificationInfo() - { -MBeanNotificationInfo[] result = new MBeanNotificationInfo[1]; -String[] types = new String[] -{ - MonitorNotification.RUNTIME_ERROR, - MonitorNotification.OBSERVED_OBJECT_ERROR, - MonitorNotification.OBSERVED_ATTRIBUTE_ERROR, - MonitorNotification.OBSERVED_ATTRIBUTE_TYPE_ERROR, - MonitorNotification.THRESHOLD_ERROR, - MonitorNotification.THRESHOLD_VALUE_EXCEEDED -}; -result[0] = new MBeanNotificationInfo(types, - "javax.management.monitor.MonitorNotification", - "Notifications sent by the Counter Monitor Service MBean"); -return result; - } - - // CounterMonitorMBean implementation - - public Number getDerivedGauge() - { -return derivedGauge; - } - - public long getDerivedGaugeTimeStamp() - { -return derivedGaugeTimeStamp; - } - - public boolean getDifferenceMode() - { -return differenceMode; - } - - public void setDifferenceMode(boolean value) - { -differenceMode = value; - } - - public Number getModulus() - { -return modulus; - } - - public void setModulus(Number value) -throws IllegalArgumentException - { -if (value == null) - throw new IllegalArgumentException("Null modulus"); -if (value.longValue() < 0) - throw new IllegalArgumentException("Negative modulus"); -modulus = value; -alreadyNotified = RESET_FLAGS_ALREADY_NOTIFIED; - } - - public boolean getNotify() - { -return notify; - } - - public void setNotify(boolean value) - { -notify = value; - } - - public Number getOffset() - { -return offset; - } - - public void setOffset(Number value) -throws IllegalArgumentException - { -if (value == null) - throw new IllegalArgumentException("Null offset"); -if (value.longValue() < 0) - throw new IllegalArgumentException("Negative offset&
[JBoss-dev] CVS update: jmx/src/main/test/compliance/monitor MonitorTestCase.java MonitorSUITE.java BasicTEST.java MonitorUnitTestSUITE.java
User: ejort Date: 02/03/24 05:12:13 Modified:src/main/test/compliance/monitor MonitorSUITE.java Added: src/main/test/compliance/monitor MonitorTestCase.java Removed: src/main/test/compliance/monitor BasicTEST.java MonitorUnitTestSUITE.java Log: merge RelMX_1_0_0_12 to RelMX_1_0_0_13 to dev branch Revision ChangesPath 1.2 +12 -2 jmx/src/main/test/compliance/monitor/MonitorSUITE.java Index: MonitorSUITE.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/MonitorSUITE.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- MonitorSUITE.java 26 Jan 2002 21:02:20 - 1.1 +++ MonitorSUITE.java 24 Mar 2002 13:12:12 - 1.2 @@ -19,6 +19,17 @@ extends TestSuite { /** + * The maximum wait for a notification + */ + public static final long MAX_WAIT = 1000; + + /** + * The time between notifications + */ + + public static final long GRANULARITY_TIME = 1; + + /** * Run the tests * * @param args the arguments for the test @@ -37,8 +48,7 @@ { TestSuite suite = new TestSuite("Monitor Service Tests"); -suite.addTest(new TestSuite(BasicTEST.class)); -suite.addTest(MonitorUnitTestSUITE.suite()); +suite.addTest(new TestSuite(MonitorTestCase.class)); return suite; } 1.2 +1268 -0 jmx/src/main/test/compliance/monitor/MonitorTestCase.java ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jmx/src/main/javax/management AndQueryExp.java AnySubStringQueryExp.java AttributeValueExp.java BetweenQueryExp.java BinaryComparisonQueryExp.java BinaryOpValueExp.java ClassAttributeValueExp.java FinalSubStringQueryExp.java InQueryExp.java InitialSubStringQueryExp.java MatchQueryExp.java NotQueryExp.java NumberValueExp.java OrQueryExp.java QualifiedAttributeValueExp.java QueryEval.java QueryExpSupport.java StringValueExp.java ValueExpSupport.java
User: ejort Date: 02/03/24 05:12:12 Modified:src/main/javax/management AndQueryExp.java AnySubStringQueryExp.java AttributeValueExp.java BetweenQueryExp.java BinaryComparisonQueryExp.java BinaryOpValueExp.java ClassAttributeValueExp.java FinalSubStringQueryExp.java InQueryExp.java InitialSubStringQueryExp.java MatchQueryExp.java NotQueryExp.java NumberValueExp.java OrQueryExp.java QualifiedAttributeValueExp.java QueryEval.java QueryExpSupport.java StringValueExp.java ValueExpSupport.java Log: merge RelMX_1_0_0_12 to RelMX_1_0_0_13 to dev branch Revision ChangesPath 1.3 +6 -8 jmx/src/main/javax/management/AndQueryExp.java Index: AndQueryExp.java === RCS file: /cvsroot/jboss/jmx/src/main/javax/management/AndQueryExp.java,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- AndQueryExp.java 15 Mar 2002 20:26:38 - 1.2 +++ AndQueryExp.java 24 Mar 2002 13:12:11 - 1.3 @@ -18,12 +18,16 @@ * * Fix the human readable expression * + * 20020317 Adrian Brock: + * + * Make queries thread safe + * * * @author mailto:[EMAIL PROTECTED]";>Adrian Brock. * @version $Revision$ */ /*package*/ class AndQueryExp - implements QueryExp + extends QueryExpSupport { // Constants --- @@ -66,12 +70,6 @@ InvalidApplicationException { return first.apply(name) && second.apply(name); - } - - public void setMBeanServer(MBeanServer server) - { - first.setMBeanServer(server); - second.setMBeanServer(server); } // Object overrides 1.2 +8 -8 jmx/src/main/javax/management/AnySubStringQueryExp.java Index: AnySubStringQueryExp.java === RCS file: /cvsroot/jboss/jmx/src/main/javax/management/AnySubStringQueryExp.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- AnySubStringQueryExp.java 22 Feb 2002 16:44:32 - 1.1 +++ AnySubStringQueryExp.java 24 Mar 2002 13:12:11 - 1.2 @@ -12,12 +12,18 @@ * An Any Substring Query Expression. * * Returns true when an attribute value contains the string expression. + * + * Revisions: + * 20020317 Adrian Brock: + * + * Make queries thread safe + * * * @author mailto:[EMAIL PROTECTED]";>Adrian Brock. * @version $Revision$ */ /*package*/ class AnySubStringQueryExp - implements QueryExp + extends QueryExpSupport { // Constants --- @@ -68,12 +74,6 @@ } // REVIEW: correct? return false; - } - - public void setMBeanServer(MBeanServer server) - { - attr.setMBeanServer(server); - string.setMBeanServer(server); } // Object overrides 1.3 +9 -24 jmx/src/main/javax/management/AttributeValueExp.java Index: AttributeValueExp.java === RCS file: /cvsroot/jboss/jmx/src/main/javax/management/AttributeValueExp.java,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- AttributeValueExp.java22 Feb 2002 16:44:32 - 1.2 +++ AttributeValueExp.java24 Mar 2002 13:12:11 - 1.3 @@ -8,15 +8,18 @@ /** * A String that is an arguement to a query. - * - * There is some duplication of implementation because of the poor - * design. * + * Revisions: + * 20020317 Adrian Brock: + * + * Make queries thread safe + * + * * @author mailto:[EMAIL PROTECTED]";>Adrian Brock. * @version $Revision$ */ public class AttributeValueExp - implements ValueExp + extends ValueExpSupport { // Constants --- @@ -27,11 +30,6 @@ */ private String value; - /** -* The MBean server for this expression -*/ - private MBeanServer server; - // Static - // Constructors @@ -84,11 +82,6 @@ throw new BadAttributeValueExpException(object); } - public void setMBeanServer(MBeanServer server) - { - this.server = server; - } - // Object overrides
[JBoss-dev] CVS update: jmx/src/main/javax/management AndQueryExp.java AnySubStringQueryExp.java AttributeValueExp.java BetweenQueryExp.java BinaryComparisonQueryExp.java BinaryOpValueExp.java ClassAttributeValueExp.java FinalSubStringQueryExp.java InQueryExp.java InitialSubStringQueryExp.java MatchQueryExp.java NotQueryExp.java NumberValueExp.java OrQueryExp.java QualifiedAttributeValueExp.java QueryEval.java QueryExpSupport.java StringValueExp.java ValueExpSupport.java
User: ejort Date: 02/03/24 03:50:26 Modified:src/main/javax/management Tag: BranchMX_1_0 AndQueryExp.java AnySubStringQueryExp.java AttributeValueExp.java BetweenQueryExp.java BinaryComparisonQueryExp.java BinaryOpValueExp.java ClassAttributeValueExp.java FinalSubStringQueryExp.java InQueryExp.java InitialSubStringQueryExp.java MatchQueryExp.java NotQueryExp.java NumberValueExp.java OrQueryExp.java QualifiedAttributeValueExp.java QueryEval.java QueryExpSupport.java StringValueExp.java ValueExpSupport.java Log: Made queries threadsafe, better but still incomplete monitor tests Revision ChangesPath No revision No revision 1.1.2.2 +6 -8 jmx/src/main/javax/management/AndQueryExp.java Index: AndQueryExp.java === RCS file: /cvsroot/jboss/jmx/src/main/javax/management/AndQueryExp.java,v retrieving revision 1.1.2.1 retrieving revision 1.1.2.2 diff -u -r1.1.2.1 -r1.1.2.2 --- AndQueryExp.java 16 Mar 2002 12:38:50 - 1.1.2.1 +++ AndQueryExp.java 24 Mar 2002 11:50:26 - 1.1.2.2 @@ -18,12 +18,16 @@ * * Fix the human readable expression * + * 20020317 Adrian Brock: + * + * Make queries thread safe + * * * @author mailto:[EMAIL PROTECTED]";>Adrian Brock. - * @version $Revision: 1.1.2.1 $ + * @version $Revision: 1.1.2.2 $ */ /*package*/ class AndQueryExp - implements QueryExp + extends QueryExpSupport { // Constants --- @@ -66,12 +70,6 @@ InvalidApplicationException { return first.apply(name) && second.apply(name); - } - - public void setMBeanServer(MBeanServer server) - { - first.setMBeanServer(server); - second.setMBeanServer(server); } // Object overrides 1.1.2.1 +7 -7 jmx/src/main/javax/management/AnySubStringQueryExp.java Index: AnySubStringQueryExp.java === RCS file: /cvsroot/jboss/jmx/src/main/javax/management/AnySubStringQueryExp.java,v retrieving revision 1.1 retrieving revision 1.1.2.1 diff -u -r1.1 -r1.1.2.1 --- AnySubStringQueryExp.java 22 Feb 2002 16:44:32 - 1.1 +++ AnySubStringQueryExp.java 24 Mar 2002 11:50:26 - 1.1.2.1 @@ -12,12 +12,18 @@ * An Any Substring Query Expression. * * Returns true when an attribute value contains the string expression. + * + * Revisions: + * 20020317 Adrian Brock: + * + * Make queries thread safe + * * * @author mailto:[EMAIL PROTECTED]";>Adrian Brock. - * @version $Revision: 1.1 $ + * @version $Revision: 1.1.2.1 $ */ /*package*/ class AnySubStringQueryExp - implements QueryExp + extends QueryExpSupport { // Constants --- @@ -68,12 +74,6 @@ } // REVIEW: correct? return false; - } - - public void setMBeanServer(MBeanServer server) - { - attr.setMBeanServer(server); - string.setMBeanServer(server); } // Object overrides 1.2.2.1 +9 -24 jmx/src/main/javax/management/AttributeValueExp.java Index: AttributeValueExp.java === RCS file: /cvsroot/jboss/jmx/src/main/javax/management/AttributeValueExp.java,v retrieving revision 1.2 retrieving revision 1.2.2.1 diff -u -r1.2 -r1.2.2.1 --- AttributeValueExp.java22 Feb 2002 16:44:32 - 1.2 +++ AttributeValueExp.java24 Mar 2002 11:50:26 - 1.2.2.1 @@ -8,15 +8,18 @@ /** * A String that is an arguement to a query. - * - * There is some duplication of implementation because of the poor - * design. * + * Revisions: + * 20020317 Adrian Brock: + * + * Make queries thread safe + * + * * @author mailto:[EMAIL PROTECTED]";>Adrian Brock. - * @version $Revision: 1.2 $ + * @version $Revision: 1.2.2.1 $ */ public class AttributeValueExp - implements ValueExp + extends ValueExpSupport { // Constants --- @@ -27,11 +30,6 @@ */ private String value; - /** -* The MBean server for this expression -*/ - private MBeanServer server; - // Static - // Constructors --
[JBoss-dev] CVS update: jmx/src/main/test/compliance/monitor/support GaugeSupport.java GaugeSupportMBean.java MonitorSupport.java CounterSupport.java CounterSupportMBean.java StringSupport.java StringSupportMBean.java
User: ejort Date: 02/03/24 03:50:27 Modified:src/main/test/compliance/monitor/support Tag: BranchMX_1_0 CounterSupport.java CounterSupportMBean.java StringSupport.java StringSupportMBean.java Added: src/main/test/compliance/monitor/support Tag: BranchMX_1_0 GaugeSupport.java GaugeSupportMBean.java MonitorSupport.java Log: Made queries threadsafe, better but still incomplete monitor tests Revision ChangesPath No revision No revision 1.1.2.1 +31 -4 jmx/src/main/test/compliance/monitor/support/CounterSupport.java Index: CounterSupport.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/support/CounterSupport.java,v retrieving revision 1.1 retrieving revision 1.1.2.1 diff -u -r1.1 -r1.1.2.1 --- CounterSupport.java 26 Jan 2002 21:02:21 - 1.1 +++ CounterSupport.java 24 Mar 2002 11:50:27 - 1.1.2.1 @@ -8,17 +8,44 @@ package test.compliance.monitor.support; public class CounterSupport + extends MonitorSupport implements CounterSupportMBean { - private int value; + private Number value; - public int getValue() + public Number getValue() { -return value; + lock("get"); + try + { +return value; + } + finally + { +unlock("get"); + } } - public void setValue(int value) + public void setValue(Number value) { this.value = value; + } + + public Number getWrongNull() + { +return null; + } + + public String getWrongType() + { +return "Wrong"; + } + + public Number getWrongException() + { + throw new RuntimeException("It is broke"); + } + public void setWriteOnly(Number value) + { } } 1.1.2.1 +6 -2 jmx/src/main/test/compliance/monitor/support/CounterSupportMBean.java Index: CounterSupportMBean.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/support/CounterSupportMBean.java,v retrieving revision 1.1 retrieving revision 1.1.2.1 diff -u -r1.1 -r1.1.2.1 --- CounterSupportMBean.java 26 Jan 2002 21:02:21 - 1.1 +++ CounterSupportMBean.java 24 Mar 2002 11:50:27 - 1.1.2.1 @@ -9,6 +9,10 @@ public interface CounterSupportMBean { - public int getValue(); - public void setValue(int value); + public Number getValue(); + public void setValue(Number value); + public Number getWrongNull(); + public String getWrongType(); + public Number getWrongException(); + public void setWriteOnly(Number value); } 1.1.2.1 +29 -1 jmx/src/main/test/compliance/monitor/support/StringSupport.java Index: StringSupport.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/support/StringSupport.java,v retrieving revision 1.1 retrieving revision 1.1.2.1 diff -u -r1.1 -r1.1.2.1 --- StringSupport.java26 Jan 2002 21:02:21 - 1.1 +++ StringSupport.java24 Mar 2002 11:50:27 - 1.1.2.1 @@ -8,17 +8,45 @@ package test.compliance.monitor.support; public class StringSupport + extends MonitorSupport implements StringSupportMBean { private String value; public String getValue() { -return value; + lock("get"); + try + { +return value; + } + finally + { +unlock("get"); + } } public void setValue(String value) { + lock("set"); this.value = value; + } + + public String getWrongNull() + { +return null; + } + + public Integer getWrongType() + { +return new Integer(0); + } + + public String getWrongException() + { + throw new RuntimeException("It is broke"); + } + public void setWriteOnly(String value) + { } } 1.1.2.1 +4 -0 jmx/src/main/test/compliance/monitor/support/StringSupportMBean.java Index: StringSupportMBean.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/support/StringSupportMBean.java,v retrieving revision 1.1 retrieving revision 1.1.2.1 diff -u -r1.1 -r1.1.2.1 --- StringSupportMBean.java 26 Jan 2002 21:02:21 - 1.1 +++ StringSupportMBean.java 24 Mar 2002 11:50:27 - 1.1.2.1 @@ -11,4 +11,8 @@ { public String getValue(); public void setValue(String value); + public String getWrongNull(); + public Integer getWrongType(); + public String getWrongExc
[JBoss-dev] CVS update: jmx/src/main/javax/management/monitor CounterMonitor.java Monitor.java
User: ejort Date: 02/03/24 03:50:27 Modified:src/main/javax/management/monitor Tag: BranchMX_1_0 CounterMonitor.java Monitor.java Log: Made queries threadsafe, better but still incomplete monitor tests Revision ChangesPath No revision No revision 1.1.2.1 +390 -376 jmx/src/main/javax/management/monitor/CounterMonitor.java Index: CounterMonitor.java === RCS file: /cvsroot/jboss/jmx/src/main/javax/management/monitor/CounterMonitor.java,v retrieving revision 1.1 retrieving revision 1.1.2.1 diff -u -r1.1 -r1.1.2.1 --- CounterMonitor.java 21 Dec 2001 01:39:37 - 1.1 +++ CounterMonitor.java 24 Mar 2002 11:50:27 - 1.1.2.1 @@ -1,376 +1,390 @@ -/* -* JBoss, the OpenSource EJB server -* -* Distributable under LGPL license. -* See terms of license at gnu.org. -*/ -package javax.management.monitor; - -import javax.management.MBeanAttributeInfo; -import javax.management.MBeanNotificationInfo; - -// REVIEW: Check synchronization - -/** - * The counter monitor service. - * - * @author mailto:[EMAIL PROTECTED]";>Adrian Brock - * @version $Revision: 1.1 $ - * - */ -public class CounterMonitor - extends Monitor - implements CounterMonitorMBean -{ - // Constants - - - /** - * The counter threshold exceeded has been notified. - */ - int THRESHOLD_EXCEEDED_NOTIFIED = 16; - - /** - * The threshold type error has been notified. - */ - int THRESHOLD_ERROR_NOTIFIED = 32; - - // Attributes - - /** - * The derived gauge. - */ - private Number derivedGauge = new Integer(0); - - /** - * The last value. - */ - private Number lastValue = null; - - /** - * The derived gauge timeStamp. - */ - private long derivedGaugeTimeStamp = 0; - - /** - * The offset. - */ - Number offset = new Integer(0); - - /** - * The modulus. - */ - Number modulus = new Integer(0); - - /** - * The threshold. - */ - Number threshold = new Integer(0); - - /** - * The last stated threshold. - */ - Number lastThreshold = new Integer(0); - - /** - * Difference mode. - */ - boolean differenceMode = false; - - /** - * Notify. - */ - boolean notify = false; - - // Static - - // Constructors -- - - /** - * Default Constructor - */ - public CounterMonitor() - { -dbgTag = "CounterMonitor"; - } - - // Public - - public MBeanNotificationInfo[] getNotificationInfo() - { -MBeanNotificationInfo[] result = new MBeanNotificationInfo[1]; -String[] types = new String[] -{ - MonitorNotification.RUNTIME_ERROR, - MonitorNotification.OBSERVED_OBJECT_ERROR, - MonitorNotification.OBSERVED_ATTRIBUTE_ERROR, - MonitorNotification.OBSERVED_ATTRIBUTE_TYPE_ERROR, - MonitorNotification.THRESHOLD_ERROR, - MonitorNotification.THRESHOLD_VALUE_EXCEEDED -}; -result[0] = new MBeanNotificationInfo(types, - "javax.management.monitor.MonitorNotification", - "Notifications sent by the Counter Monitor Service MBean"); -return result; - } - - // CounterMonitorMBean implementation - - public Number getDerivedGauge() - { -return derivedGauge; - } - - public long getDerivedGaugeTimeStamp() - { -return derivedGaugeTimeStamp; - } - - public boolean getDifferenceMode() - { -return differenceMode; - } - - public void setDifferenceMode(boolean value) - { -differenceMode = value; - } - - public Number getModulus() - { -return modulus; - } - - public void setModulus(Number value) -throws IllegalArgumentException - { -if (value == null) - throw new IllegalArgumentException("Null modulus"); -if (value.longValue() < 0) - throw new IllegalArgumentException("Negative modulus"); -modulus = value; -alreadyNotified = RESET_FLAGS_ALREADY_NOTIFIED; - } - - public boolean getNotify() - { -return notify; - } - - public void setNotify(boolean value) - { -notify = value; - } - - public Number getOffset() - { -return offset; - } - - public void setOffset(Number value) -throws IllegalArgumentException - { -if (value == null) - throw new IllegalArgumentException("N
[JBoss-dev] CVS update: jmx/src/main/test/compliance/monitor MonitorTestCase.java MonitorSUITE.java BasicTEST.java MonitorUnitTestSUITE.java
User: ejort Date: 02/03/24 03:50:27 Modified:src/main/test/compliance/monitor Tag: BranchMX_1_0 MonitorSUITE.java Added: src/main/test/compliance/monitor Tag: BranchMX_1_0 MonitorTestCase.java Removed: src/main/test/compliance/monitor Tag: BranchMX_1_0 BasicTEST.java MonitorUnitTestSUITE.java Log: Made queries threadsafe, better but still incomplete monitor tests Revision ChangesPath No revision No revision 1.1.2.1 +12 -2 jmx/src/main/test/compliance/monitor/MonitorSUITE.java Index: MonitorSUITE.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/monitor/MonitorSUITE.java,v retrieving revision 1.1 retrieving revision 1.1.2.1 diff -u -r1.1 -r1.1.2.1 --- MonitorSUITE.java 26 Jan 2002 21:02:20 - 1.1 +++ MonitorSUITE.java 24 Mar 2002 11:50:27 - 1.1.2.1 @@ -19,6 +19,17 @@ extends TestSuite { /** + * The maximum wait for a notification + */ + public static final long MAX_WAIT = 1000; + + /** + * The time between notifications + */ + + public static final long GRANULARITY_TIME = 1; + + /** * Run the tests * * @param args the arguments for the test @@ -37,8 +48,7 @@ { TestSuite suite = new TestSuite("Monitor Service Tests"); -suite.addTest(new TestSuite(BasicTEST.class)); -suite.addTest(MonitorUnitTestSUITE.suite()); +suite.addTest(new TestSuite(MonitorTestCase.class)); return suite; } No revision No revision 1.1.2.1 +1268 -0 jmx/src/main/test/compliance/monitor/Attic/MonitorTestCase.java ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jmx/src/main/test/compliance/query QueryTestCase.java
User: ejort Date: 02/03/24 03:50:27 Modified:src/main/test/compliance/query Tag: BranchMX_1_0 QueryTestCase.java Log: Made queries threadsafe, better but still incomplete monitor tests Revision ChangesPath No revision No revision 1.1.2.2 +64 -0 jmx/src/main/test/compliance/query/QueryTestCase.java Index: QueryTestCase.java === RCS file: /cvsroot/jboss/jmx/src/main/test/compliance/query/QueryTestCase.java,v retrieving revision 1.1.2.1 retrieving revision 1.1.2.2 diff -u -r1.1.2.1 -r1.1.2.2 --- QueryTestCase.java16 Mar 2002 12:38:52 - 1.1.2.1 +++ QueryTestCase.java24 Mar 2002 11:50:27 - 1.1.2.2 @@ -1001,6 +1001,38 @@ } /** +* Test threading, tests that running the same query in multiple threads +* works. This test might not catch a threading problem on every run. +*/ + public void testThreading() throws Exception + { + MBeanServer server1 = MBeanServerFactory.createMBeanServer("server1"); + MBeanServer server2 = MBeanServerFactory.createMBeanServer("server2"); + try + { + ObjectName name = new ObjectName("Domain1:type=instance1"); + NumberTest bean1 = new NumberTest(1); + NumberTest bean2 = new NumberTest(2); + server1.registerMBean(bean1, name); + server2.registerMBean(bean2, name); + QueryExp query = Query.eq(Query.attr("Number"), Query.value(2)); + QueryThread thread1 = new QueryThread(server1, query, 0); + QueryThread thread2 = new QueryThread(server2, query, 1); + thread1.start(); + thread2.start(); + thread1.join(1); + thread1.check(); + thread2.join(1); + thread2.check(); + } + finally + { + MBeanServerFactory.releaseMBeanServer(server1); + MBeanServerFactory.releaseMBeanServer(server2); + } + } + + /** * Test pathological */ public void testPathological() throws Exception @@ -1553,6 +1585,38 @@ { fail("Expected instance " + iterator.next() + "\nfor query " + queryExp); + } + } + } + + public class QueryThread + extends Thread + { + MBeanServer server; + QueryExp query; + int expected; + int result; + public QueryThread(MBeanServer server, QueryExp query, int expected) + { + this.server = server; + this.query = query; + this.expected = expected; + } + public int getExpected() + { + return expected; + } + public void check() + { + assertEquals(expected, result); + } + public void run() + { + for (int i = 0; i < 1000; i++) + { +result = server.queryNames(null, query).size(); +if (result != expected) + return; } } } ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: RE: [JBoss-dev] JBossMX and JBoss
> And for the thousands fucking time please send me > your BIO and picture for > the site > > PLEASE! it's been what... 2 month? I suppose you don't want to hear it is the only outstanding item in my e-mails ;-) I'm tempted to send you a Silhouette with a ? PS. England thrashed Wales, but it looks like France are going to win the Grand Slam, they easily beat Scotland. Regards, Adrian > > come'on you earned it already! > > marcf > > |-Original Message- > |From: [EMAIL PROTECTED] > |[mailto:[EMAIL PROTECTED] > On Behalf Of > |Adrian Brock > |Sent: Saturday, March 23, 2002 1:57 PM > |To: [EMAIL PROTECTED] > |Subject: [JBoss-dev] JBossMX and JBoss > | > | > |Ok, > | > |JBoss now builds and runs with JBossMX. > | > |I'll post other issues in different threads. Sorry > for > |the mail bombing, but I hate interlocking threads > with > |5 or 6 different topics. > | > |Since I'm posting from the forums, my direct mail > |address for any problems is > |[EMAIL PROTECTED] > | > |"any" means jbossmx integration problems :-) > | > |Regards, > |Adrian > |_ > ___ > |View thread online: > http://main.jboss.org/thread.jsp?forum=66&thread=11474 > | > |___ > |Jboss-development mailing list > |[EMAIL PROTECTED] > |https://lists.sourceforge.net/lists/listinfo/jboss-de > elopment > > > ___ > Jboss-development mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-dev > lopment _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11474 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: RE: [JBoss-dev] JBossMX - Features
> |1) UnifiedLoaderRepository. > > We will do that at Tahoe, > > |2) BCEL compilation of Standard MBeans to get near > |Dynamic MBean performance. > > ummm I think we could use it in the invocation chain > to call the target, > this way we would speed up the invocation chain on > JDK1.3. Supposedly > JDK1.4 has an optimized invocation chain anyway > sooo... It has been optimized, but... Look at these links http://main.jboss.org/thread.jsp?forum=63&thread=8590 http://main.jboss.org/thread.jsp?forum=63&thread=9047 > > marcf > > | > |It is probably best to speak to Juha about these. > | > |Regards, > |Adrian > |_ > ___ > |View thread online: > http://main.jboss.org/thread.jsp?forum=66&thread=11479 > | > |___ > |Jboss-development mailing list > |[EMAIL PROTECTED] > |https://lists.sourceforge.net/lists/listinfo/jboss-de > elopment > > > ___ > Jboss-development mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-dev > lopment Regards, Adrian _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11479 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] JBossMX and JBossMQ standalone
There is a standalone checkout of JBossMQ that is still using jmxri.jar Part of the reason for doing the integration is to stop developers using invoke() to get/set attributes. Something that should never have been allowed and will be stopped in the RI from JMX1.1 I can modify this, but it means modifying CVSROOT/modules to include the jmx module. I can do this, but should I? Regards, Adrian _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11480 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] JBossMX - Features
Hi, There are couple of features that JBoss could use. 1) UnifiedLoaderRepository. 2) BCEL compilation of Standard MBeans to get near Dynamic MBean performance. It is probably best to speak to Juha about these. Regards, Adrian _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11479 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] JBossMX - Core/Kernel
So far I've split out the basic jmx services. There's plenty of other bits I can move from core to services, e.g. QueryExp It just needs some testing and maybe some minor code changes. If we really wanted to provide a minimal kernel, Standard and ModelMBeans are really services on top of the DynamicMBean core. But that's probably not relevent to most users of JMX Regards, Adrian _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11478 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] JBoss.net/IIOP and JBossMX integration
Hi, I've changed these modules to build with jbossmx. Let me know if there are any problems. I also changed a .bat test program in axis that looked like they hadn't been modified since the alpha. Regards, Adrian _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11476 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] Clustering and JBossMX integration
Hi, I fixed the clustering tests that weren't deploying. I've also made a few mods where MBeanServer.invoke() was used to get/set attributes. I don't know enough to test this properly. I did cluster my Windows laptop and my Linux desktop using the bean from the testsuite. Cool stuff guys! Regards, Adrian _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11475 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] JBossMX and JBoss
Ok, JBoss now builds and runs with JBossMX. I'll post other issues in different threads. Sorry for the mail bombing, but I hate interlocking threads with 5 or 6 different topics. Since I'm posting from the forums, my direct mail address for any problems is [EMAIL PROTECTED] "any" means jbossmx integration problems :-) Regards, Adrian _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11474 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: contrib/varia build.xml
User: ejort Date: 02/03/23 13:11:04 Modified:variabuild.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.27 +9 -9 contrib/varia/build.xml Index: build.xml === RCS file: /cvsroot/jboss/contrib/varia/build.xml,v retrieving revision 1.26 retrieving revision 1.27 diff -u -r1.26 -r1.27 --- build.xml 11 Mar 2002 04:31:35 - 1.26 +++ build.xml 23 Mar 2002 21:11:04 - 1.27 @@ -12,7 +12,7 @@ - + @@ -76,13 +76,6 @@ - - - - - - - @@ -188,7 +181,6 @@ - @@ -228,6 +220,13 @@ + + + + + + + @@ -255,6 +254,7 @@ + ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jbosstest/src/resources/naming/ear/b/META-INF ejb-jar.xml
User: ejort Date: 02/03/23 13:11:04 Modified:src/resources/naming/ear/b/META-INF ejb-jar.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.2 +21 -0 jbosstest/src/resources/naming/ear/b/META-INF/ejb-jar.xml Index: ejb-jar.xml === RCS file: /cvsroot/jboss/jbosstest/src/resources/naming/ear/b/META-INF/ejb-jar.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- ejb-jar.xml 17 Mar 2002 12:56:30 - 1.1 +++ ejb-jar.xml 23 Mar 2002 21:11:04 - 1.2 @@ -17,6 +17,27 @@ org.jboss.test.naming.interfaces.TestEjbLink SessionA + +ejb/LocalSessionA +Session + org.jboss.test.naming.interfaces.TestEjbLinkLocalHome +org.jboss.test.naming.interfaces.TestEjbLinkLocal +SessionA + + +ejb/RelativeSessionA +Session +org.jboss.test.naming.interfaces.TestEjbLinkHome +org.jboss.test.naming.interfaces.TestEjbLink +../subdir/naminga.jar#SessionA + + +ejb/LocalRelativeSessionA +Session + org.jboss.test.naming.interfaces.TestEjbLinkLocalHome +org.jboss.test.naming.interfaces.TestEjbLinkLocal +../subdir/naminga.jar#SessionA + ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jbosstest build.xml
User: ejort Date: 02/03/23 13:11:03 Modified:.build.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.96 +13 -108 jbosstest/build.xml Index: build.xml === RCS file: /cvsroot/jboss/jbosstest/build.xml,v retrieving revision 1.95 retrieving revision 1.96 diff -u -r1.95 -r1.96 --- build.xml 23 Mar 2002 03:55:08 - 1.95 +++ build.xml 23 Mar 2002 21:11:03 - 1.96 @@ -13,22 +13,7 @@ - - - - - - - - - - - - - - - - + @@ -92,13 +77,6 @@ - - - - - - - @@ -185,8 +163,6 @@ - - @@ -348,41 +324,20 @@ - - + + - - - - - - - - - - - - - - - - - - - - - - + - + @@ -404,7 +359,7 @@ - + @@ -629,7 +584,7 @@ failonerror="${javac.fail.onerror}"> - + @@ -1378,6 +1333,7 @@ + @@ -1404,7 +1360,7 @@ - + @@ -1430,7 +1386,7 @@ - + @@ -1655,6 +1611,7 @@ + @@ -2294,16 +2251,6 @@ tests-jbossmx-performance, tests-report"> - - - - - - - - - - - - - - - - - - - - - - - ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jboss-system/src/main/org/jboss/system/server ServerLoader.java
User: ejort Date: 02/03/23 13:11:03 Modified:src/main/org/jboss/system/server ServerLoader.java Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.7 +9 -2 jboss-system/src/main/org/jboss/system/server/ServerLoader.java Index: ServerLoader.java === RCS file: /cvsroot/jboss/jboss-system/src/main/org/jboss/system/server/ServerLoader.java,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- ServerLoader.java 27 Feb 2002 09:24:26 - 1.6 +++ ServerLoader.java 23 Mar 2002 21:11:03 - 1.7 @@ -33,7 +33,7 @@ * *// add the jaxp & jmx library to use *loader.addLibrary("crimson.jar"); - *loader.addLibrary("jmxri.jar"); + *loader.addLibrary("jboss-jmx-core.jar"); * *// load and initialize the server instance *ClassLoader parent = Thread.currentThread().getContextClassLoader(); @@ -50,8 +50,15 @@ *server.shutdown(); * * - * @version $Revision: 1.6 $ + * Revisions: + * 20020321 Adrian Brock: + * + * Use JBossMX to run JBoss + * + * + * @version $Revision: 1.7 $ * @author mailto:[EMAIL PROTECTED]";>Jason Dillon + * @author mailto:[EMAIL PROTECTED]";>Adrian Brock */ public class ServerLoader { ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jbosstest/src/bin jmx-test.sh
User: ejort Date: 02/03/23 13:11:03 Modified:src/bin jmx-test.sh Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.4 +2 -2 jbosstest/src/bin/jmx-test.sh Index: jmx-test.sh === RCS file: /cvsroot/jboss/jbosstest/src/bin/jmx-test.sh,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- jmx-test.sh 17 Feb 2002 09:52:52 - 1.3 +++ jmx-test.sh 23 Mar 2002 21:11:03 - 1.4 @@ -1,11 +1,11 @@ #! /bin/sh -# $Id: jmx-test.sh,v 1.3 2002/02/17 09:52:52 user57 Exp $ +# $Id: jmx-test.sh,v 1.4 2002/03/23 21:11:03 ejort Exp $ TARGET_CLASSPATH=../lib/junit.jar -TARGET_CLASSPATH=$TARGET_CLASSPATH:../lib/jmxri.jar +TARGET_CLASSPATH=$TARGET_CLASSPATH:../lib/jboss-jmx.jar TARGET_CLASSPATH=$TARGET_CLASSPATH:../lib/jnp-client.jar TARGET_CLASSPATH=$TARGET_CLASSPATH:../lib/connector.jar TARGET_CLASSPATH=$TARGET_CLASSPATH:../lib/testjmx.jar ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jbossmq/src/main/org/jboss/mq/sm/file OldStateManager.java
User: ejort Date: 02/03/23 13:11:02 Modified:src/main/org/jboss/mq/sm/file OldStateManager.java Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.2 +1 -8 jbossmq/src/main/org/jboss/mq/sm/file/OldStateManager.java Index: OldStateManager.java === RCS file: /cvsroot/jboss/jbossmq/src/main/org/jboss/mq/sm/file/OldStateManager.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- OldStateManager.java 6 Mar 2002 17:27:51 - 1.1 +++ OldStateManager.java 23 Mar 2002 21:11:01 - 1.2 @@ -46,7 +46,7 @@ * @author Norbert Lataille ([EMAIL PROTECTED]) * @author Hiram Chirino * @author mailto:[EMAIL PROTECTED]";>Peter Antman - * @version$Revision: 1.1 $ + * @version$Revision: 1.2 $ */ public class OldStateManager extends ServiceMBeanSupport @@ -425,13 +425,6 @@ { loadConfig(); - - /*JMSServer server = (JMSServer)getServer().invoke(new ObjectName(org.jboss.mq.server.JBossMQServiceMBean.OBJECT_NAME), "getJMSServer", new Object[]{ -}, new String[]{ -});*/ - //server.setStateManager(this); - //initDurableSubscriptions(server); - } public Collection getDurableSubscriptionIdsForTopic(SpyTopic topic) ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jboss-system/src/main/org/jboss Main.java
User: ejort Date: 02/03/23 13:11:03 Modified:src/main/org/jboss Main.java Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.7 +9 -2 jboss-system/src/main/org/jboss/Main.java Index: Main.java === RCS file: /cvsroot/jboss/jboss-system/src/main/org/jboss/Main.java,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- Main.java 7 Mar 2002 06:27:43 - 1.6 +++ Main.java 23 Mar 2002 21:11:03 - 1.7 @@ -39,9 +39,16 @@ * ./run.sh -Dlog4j.configuration=log4j-debug.properties * * + * Revisions: + * 20020321 Adrian Brock: + * + * Use JBossMX to run JBoss + * + * * @author mailto:[EMAIL PROTECTED]";>Marc Fleury * @author mailto:[EMAIL PROTECTED]";>Jason Dillon - * @version $Revision: 1.6 $ + * @author mailto:[EMAIL PROTECTED]";>Adrian Brock + * @version $Revision: 1.7 $ */ public class Main { @@ -49,7 +56,7 @@ private String jaxpLib = "crimson.jar"; /** The JMX library to use. */ - private String jmxLib = "jmxri.jar"; + private String jmxLib = "jboss-jmx-core.jar"; /** Extra libraries to load the server with .*/ private List extraLibraries = new LinkedList(); ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jbossmq build.xml
User: ejort Date: 02/03/23 13:11:01 Modified:.build.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.27 +9 -9 jbossmq/build.xml Index: build.xml === RCS file: /cvsroot/jboss/jbossmq/build.xml,v retrieving revision 1.26 retrieving revision 1.27 diff -u -r1.26 -r1.27 --- build.xml 6 Mar 2002 21:03:02 - 1.26 +++ build.xml 23 Mar 2002 21:11:01 - 1.27 @@ -12,7 +12,7 @@ - + @@ -80,13 +80,6 @@ - - - - - - - @@ -134,7 +127,6 @@ - @@ -182,6 +174,13 @@ + + + + + + + @@ -196,6 +195,7 @@ + ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jbosssx build.xml
User: ejort Date: 02/03/23 13:11:02 Modified:.build.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.23 +9 -9 jbosssx/build.xml Index: build.xml === RCS file: /cvsroot/jboss/jbosssx/build.xml,v retrieving revision 1.22 retrieving revision 1.23 diff -u -r1.22 -r1.23 --- build.xml 13 Mar 2002 08:15:07 - 1.22 +++ build.xml 23 Mar 2002 21:11:02 - 1.23 @@ -12,7 +12,7 @@ - + @@ -69,13 +69,6 @@ - - - - - - - @@ -133,7 +126,6 @@ - @@ -183,6 +175,13 @@ + + + + + + + @@ -190,6 +189,7 @@ + ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: contrib/jboss.net/testsuite build.xml
User: ejort Date: 02/03/23 13:11:01 Modified:jboss.net/testsuite build.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.10 +9 -9 contrib/jboss.net/testsuite/build.xml Index: build.xml === RCS file: /cvsroot/jboss/contrib/jboss.net/testsuite/build.xml,v retrieving revision 1.9 retrieving revision 1.10 diff -u -r1.9 -r1.10 --- build.xml 12 Mar 2002 11:04:47 - 1.9 +++ build.xml 23 Mar 2002 21:11:01 - 1.10 @@ -12,7 +12,7 @@ - + @@ -87,13 +87,6 @@ - - - - - - - @@ -168,7 +161,6 @@ - @@ -208,6 +200,13 @@ + + + + + + + @@ -251,6 +250,7 @@ + ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jboss build.xml
User: ejort Date: 02/03/23 13:11:02 Modified:.build.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.80 +13 -9 jboss/build.xml Index: build.xml === RCS file: /cvsroot/jboss/jboss/build.xml,v retrieving revision 1.79 retrieving revision 1.80 diff -u -r1.79 -r1.80 --- build.xml 11 Mar 2002 04:31:34 - 1.79 +++ build.xml 23 Mar 2002 21:11:02 - 1.80 @@ -12,7 +12,7 @@ - + @@ -73,6 +73,10 @@ + + + + @@ -80,13 +84,6 @@ - - - - - - - @@ -175,7 +172,6 @@ - @@ -213,6 +209,13 @@ + + + + + + + @@ -233,6 +236,7 @@ + ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: contrib/jboss.net build.xml
User: ejort Date: 02/03/23 13:11:00 Modified:jboss.net build.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.18 +9 -9 contrib/jboss.net/build.xml Index: build.xml === RCS file: /cvsroot/jboss/contrib/jboss.net/build.xml,v retrieving revision 1.17 retrieving revision 1.18 diff -u -r1.17 -r1.18 --- build.xml 15 Mar 2002 10:04:23 - 1.17 +++ build.xml 23 Mar 2002 21:11:00 - 1.18 @@ -12,7 +12,7 @@ - + @@ -69,13 +69,6 @@ - - - - - - - @@ -131,7 +124,6 @@ - @@ -173,12 +165,20 @@ + + + + + + + + ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jboss/src/main/org/jboss/jmx/connector/notification PollingClientNotificationListener.java
User: ejort Date: 02/03/23 13:11:03 Modified:src/main/org/jboss/jmx/connector/notification PollingClientNotificationListener.java Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.3 +2 -4 jboss/src/main/org/jboss/jmx/connector/notification/PollingClientNotificationListener.java Index: PollingClientNotificationListener.java === RCS file: /cvsroot/jboss/jboss/src/main/org/jboss/jmx/connector/notification/PollingClientNotificationListener.java,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- PollingClientNotificationListener.java11 Oct 2001 01:41:59 - 1.2 +++ PollingClientNotificationListener.java23 Mar 2002 21:11:03 - 1.3 @@ -60,11 +60,9 @@ while( true ) { try { try { - List lNotifications = (List) mConnector.invoke( + List lNotifications = (List) mConnector.getAttribute( getRemoteListenerName(), - "getNotifications", - new Object[] {}, - new String[] {} + "Notifications" ); Iterator i = lNotifications.iterator(); while( i.hasNext() ) { ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jboss-common build.xml
User: ejort Date: 02/03/23 13:11:00 Modified:.build.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.10 +9 -9 jboss-common/build.xml Index: build.xml === RCS file: /cvsroot/jboss/jboss-common/build.xml,v retrieving revision 1.9 retrieving revision 1.10 diff -u -r1.9 -r1.10 --- build.xml 28 Feb 2002 04:08:01 - 1.9 +++ build.xml 23 Mar 2002 21:11:00 - 1.10 @@ -12,7 +12,7 @@ - + @@ -69,13 +69,6 @@ - - - - - - - @@ -101,7 +94,6 @@ - @@ -110,8 +102,16 @@ + + + + + + + + ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jbossmx/src/main/org/jbossmx/cluster/watchdog SwapMachines.java
User: ejort Date: 02/03/23 13:10:59 Modified:src/main/org/jbossmx/cluster/watchdog SwapMachines.java Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.2 +2 -2 jbossmx/src/main/org/jbossmx/cluster/watchdog/SwapMachines.java Index: SwapMachines.java === RCS file: /cvsroot/jboss/jbossmx/src/main/org/jbossmx/cluster/watchdog/SwapMachines.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- SwapMachines.java 29 Mar 2001 13:49:30 - 1.1 +++ SwapMachines.java 23 Mar 2002 21:10:59 - 1.2 @@ -343,8 +343,8 @@ //System.out.println("watchdogMachineAgent=" + watchdogMachineAgent); //System.out.println("watchdogObjectName=" + watchdogObjectName); -watchedRmiBinding = (String) watchdogMachineAgent.invokeMethodOnMBean( -watchdogObjectName, "getRmiAgentBinding", new Object[0], new String[0]); +watchedRmiBinding = (String) watchdogMachineAgent.getMBeanAttribute( +watchdogObjectName, "RmiAgentBinding"); //watchedRmiBinding = Configuration.getAgentWatcherDetails(rmiAgentBinding)[0]; ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: contrib/iiop build.xml
User: ejort Date: 02/03/23 13:11:00 Modified:iiop build.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.10 +9 -9 contrib/iiop/build.xml Index: build.xml === RCS file: /cvsroot/jboss/contrib/iiop/build.xml,v retrieving revision 1.9 retrieving revision 1.10 diff -u -r1.9 -r1.10 --- build.xml 15 Mar 2002 22:19:53 - 1.9 +++ build.xml 23 Mar 2002 21:11:00 - 1.10 @@ -12,7 +12,7 @@ - + @@ -76,13 +76,6 @@ - - - - - - - @@ -117,7 +110,6 @@ - @@ -158,12 +150,20 @@ + + + + + + + + ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: contrib/catalina build.xml
User: ejort Date: 02/03/23 13:10:59 Modified:catalina build.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.12 +9 -9 contrib/catalina/build.xml Index: build.xml === RCS file: /cvsroot/jboss/contrib/catalina/build.xml,v retrieving revision 1.11 retrieving revision 1.12 diff -u -r1.11 -r1.12 --- build.xml 28 Feb 2002 04:08:01 - 1.11 +++ build.xml 23 Mar 2002 21:10:59 - 1.12 @@ -12,7 +12,7 @@ - + @@ -52,13 +52,6 @@ - - - - - - - @@ -101,7 +94,6 @@ - @@ -142,6 +134,13 @@ + + + + + + + @@ -158,6 +157,7 @@ + ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jbossmx/src/main/org/jbossmx/cluster/watchdog/mbean/xmlet XMLetMetaDataNodeProcessor.java
User: ejort Date: 02/03/23 13:11:00 Modified:src/main/org/jbossmx/cluster/watchdog/mbean/xmlet XMLetMetaDataNodeProcessor.java Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.2 +3 -3 jbossmx/src/main/org/jbossmx/cluster/watchdog/mbean/xmlet/XMLetMetaDataNodeProcessor.java Index: XMLetMetaDataNodeProcessor.java === RCS file: /cvsroot/jboss/jbossmx/src/main/org/jbossmx/cluster/watchdog/mbean/xmlet/XMLetMetaDataNodeProcessor.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- XMLetMetaDataNodeProcessor.java 10 Apr 2001 20:50:09 - 1.1 +++ XMLetMetaDataNodeProcessor.java 23 Mar 2002 21:10:59 - 1.2 @@ -18,6 +18,7 @@ import org.jbossmx.cluster.watchdog.util.xml.XMLScripter; import org.jbossmx.cluster.watchdog.util.xml.XMLScriptException; +import javax.management.Attribute; import javax.management.MBeanServer; import javax.management.ObjectInstance; import javax.management.ObjectName; @@ -64,9 +65,8 @@ MBeanServer mbeanServer = xmlet.getMBeanServer(); -mbeanServer.invoke(new ObjectName(MetaDataServiceMBean.OBJECT_NAME), "setMetaData", -new Object[] {objectNameMetaData}, -new String[] {ObjectNameMetaData.class.getName()}); +mbeanServer.setAttribute(new ObjectName(MetaDataServiceMBean.OBJECT_NAME), +new Attribute("MetaData", objectNameMetaData)); } catch (Throwable t) { ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jbosstest/src/etc manifest.mf
User: ejort Date: 02/03/23 13:11:03 Modified:src/etc manifest.mf Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.2 +1 -1 jbosstest/src/etc/manifest.mf Index: manifest.mf === RCS file: /cvsroot/jboss/jbosstest/src/etc/manifest.mf,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- manifest.mf 27 Aug 2000 09:13:09 - 1.1 +++ manifest.mf 23 Mar 2002 21:11:03 - 1.2 @@ -1 +1 @@ -Class-Path: ejb.jar jnp-client.jar jboss-client.jar jndi.jar jmxri.jar junit.jar deploy.jar +Class-Path: ejb.jar jnp-client.jar jboss-client.jar jndi.jar jboss-jmx.jar junit.jar deploy.jar ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jbosspool build.xml
User: ejort Date: 02/03/23 13:11:02 Modified:.build.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.22 +9 -9 jbosspool/build.xml Index: build.xml === RCS file: /cvsroot/jboss/jbosspool/build.xml,v retrieving revision 1.21 retrieving revision 1.22 diff -u -r1.21 -r1.22 --- build.xml 9 Mar 2002 02:45:34 - 1.21 +++ build.xml 23 Mar 2002 21:11:02 - 1.22 @@ -12,7 +12,7 @@ - + @@ -69,13 +69,6 @@ - - - - - - - @@ -108,7 +101,6 @@ - @@ -126,9 +118,17 @@ + + + + + + + + ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jboss-system build.xml
User: ejort Date: 02/03/23 13:11:03 Modified:.build.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.9 +9 -9 jboss-system/build.xml Index: build.xml === RCS file: /cvsroot/jboss/jboss-system/build.xml,v retrieving revision 1.8 retrieving revision 1.9 diff -u -r1.8 -r1.9 --- build.xml 5 Mar 2002 05:35:38 - 1.8 +++ build.xml 23 Mar 2002 21:11:03 - 1.9 @@ -12,7 +12,7 @@ - + @@ -69,13 +69,6 @@ - - - - - - - @@ -110,7 +103,6 @@ - @@ -127,9 +119,17 @@ + + + + + + + + ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: build/jboss build.xml
User: ejort Date: 02/03/23 13:10:59 Modified:jbossbuild.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.111 +14 -21build/jboss/build.xml Index: build.xml === RCS file: /cvsroot/jboss/build/jboss/build.xml,v retrieving revision 1.110 retrieving revision 1.111 diff -u -r1.110 -r1.111 --- build.xml 12 Mar 2002 10:55:19 - 1.110 +++ build.xml 23 Mar 2002 21:10:59 - 1.111 @@ -12,7 +12,7 @@ - + @@ -175,12 +175,12 @@ + - @@ -199,7 +199,7 @@ - + @@ -211,11 +211,10 @@ @@ -415,6 +414,8 @@ + + @@ -926,7 +927,14 @@ - + + + + + + + + @@ -1313,21 +1321,6 @@ - - - ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: admin build.xml
User: ejort Date: 02/03/23 13:10:58 Modified:.build.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.20 +9 -9 admin/build.xml Index: build.xml === RCS file: /cvsroot/jboss/admin/build.xml,v retrieving revision 1.19 retrieving revision 1.20 diff -u -r1.19 -r1.20 --- build.xml 28 Feb 2002 04:08:00 - 1.19 +++ build.xml 23 Mar 2002 21:10:58 - 1.20 @@ -12,7 +12,7 @@ - + @@ -69,13 +69,6 @@ - - - - - - - @@ -108,7 +101,6 @@ - @@ -147,12 +139,20 @@ + + + + + + + + ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jbosstest/src/main/org/jboss/test/naming/test EjbLinkUnitTestCase.java
User: ejort Date: 02/03/23 13:11:04 Modified:src/main/org/jboss/test/naming/test EjbLinkUnitTestCase.java Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.2 +57 -0 jbosstest/src/main/org/jboss/test/naming/test/EjbLinkUnitTestCase.java Index: EjbLinkUnitTestCase.java === RCS file: /cvsroot/jboss/jbosstest/src/main/org/jboss/test/naming/test/EjbLinkUnitTestCase.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- EjbLinkUnitTestCase.java 17 Mar 2002 12:56:29 - 1.1 +++ EjbLinkUnitTestCase.java 23 Mar 2002 21:11:03 - 1.2 @@ -53,6 +53,63 @@ bean.remove(); } + /** +* Test an ejblink with a relative path +* +* @exception Exception Description of Exception +*/ + public void testEjbLinkRelative() throws Exception + { + Object obj = getInitialContext().lookup("naming/SessionB"); + obj = PortableRemoteObject.narrow(obj, TestEjbLinkHome.class); + TestEjbLinkHome home = (TestEjbLinkHome)obj; + getLog().debug("Found naming/SessionB"); + + TestEjbLink bean = home.create(); + getLog().debug("Created the bean"); + assertEquals("Works", bean.testEjbLinkCaller("java:comp/env/ejb/RelativeSessionA")); + getLog().debug("Test succeeded"); + bean.remove(); + } + + /** +* Test an ejblink using a local ejb-ref +* +* @exception Exception Description of Exception +*/ + public void testEjbLinkLocalNamed() throws Exception + { + Object obj = getInitialContext().lookup("naming/SessionB"); + obj = PortableRemoteObject.narrow(obj, TestEjbLinkHome.class); + TestEjbLinkHome home = (TestEjbLinkHome)obj; + getLog().debug("Found naming/SessionB"); + + TestEjbLink bean = home.create(); + getLog().debug("Created the bean"); + assertEquals("Works", bean.testEjbLinkCallerLocal("java:comp/env/ejb/LocalSessionA")); + getLog().debug("Test succeeded"); + bean.remove(); + } + + /** +* Test an ejblink using a local ejb-ref with a relative path +* +* @exception Exception Description of Exception +*/ + public void testEjbLinkLocalRelative() throws Exception + { + Object obj = getInitialContext().lookup("naming/SessionB"); + obj = PortableRemoteObject.narrow(obj, TestEjbLinkHome.class); + TestEjbLinkHome home = (TestEjbLinkHome)obj; + getLog().debug("Found naming/SessionB"); + + TestEjbLink bean = home.create(); + getLog().debug("Created the bean"); + assertEquals("Works", bean.testEjbLinkCallerLocal("java:comp/env/ejb/LocalRelativeSessionA")); + getLog().debug("Test succeeded"); + bean.remove(); + } + public static Test suite() throws Exception { return getDeploySetup(EjbLinkUnitTestCase.class, "naming.ear"); ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: contrib/jetty build.xml
User: ejort Date: 02/03/23 13:11:01 Modified:jettybuild.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.47 +8 -8 contrib/jetty/build.xml Index: build.xml === RCS file: /cvsroot/jboss/contrib/jetty/build.xml,v retrieving revision 1.46 retrieving revision 1.47 diff -u -r1.46 -r1.47 --- build.xml 16 Mar 2002 01:27:21 - 1.46 +++ build.xml 23 Mar 2002 21:11:01 - 1.47 @@ -76,13 +76,6 @@ - - - - - - - @@ -143,7 +136,6 @@ - @@ -184,6 +176,13 @@ + + + + + + + @@ -201,6 +200,7 @@ + ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: contrib/jboss.net/testsuite/src/bin testAxis.bat
User: ejort Date: 02/03/23 13:11:01 Modified:jboss.net/testsuite/src/bin testAxis.bat Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.2 +1 -1 contrib/jboss.net/testsuite/src/bin/testAxis.bat Index: testAxis.bat === RCS file: /cvsroot/jboss/contrib/jboss.net/testsuite/src/bin/testAxis.bat,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- testAxis.bat 7 Oct 2001 20:06:11 - 1.1 +++ testAxis.bat 23 Mar 2002 21:11:01 - 1.2 @@ -1,4 +1,4 @@ -set JBOSS_CLASSPATH=.;%JBOSS_CLASSPATH%;..\lib\ext\axis.jar;..\lib\ext\log4j.jar;..\deploy\lib\jbossdotnet.sar;..\lib\crimson.jar;..\lib\jmxri.jar +set JBOSS_CLASSPATH=.;%JBOSS_CLASSPATH%;..\lib\axis.jar;..\lib\log4j.jar;..\server\default\deploy\jbossdotnet.sar;..\lib\crimson.jar;..\lib\jboss-jmx.jar java -classpath "%JBOSS_CLASSPATH%" org.jboss.net.axis.AxisInvocationHandler http://localhost:8080/axis/services java -classpath "%JBOSS_CLASSPATH%" org.jboss.net.jmx.MBeanInvocationHandler http://localhost:8080/axis/services ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jboss/src/etc/manifest connector-client-factory.mf deploy.mf ejb-connector-client.mf ejb-connector.mf rmi-adaptor.mf rmi-connector-client.mf stop.mf
User: ejort Date: 02/03/23 13:11:02 Modified:src/etc/manifest connector-client-factory.mf deploy.mf ejb-connector-client.mf ejb-connector.mf rmi-adaptor.mf rmi-connector-client.mf stop.mf Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.3 +1 -1 jboss/src/etc/manifest/connector-client-factory.mf Index: connector-client-factory.mf === RCS file: /cvsroot/jboss/jboss/src/etc/manifest/connector-client-factory.mf,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- connector-client-factory.mf 17 Feb 2002 08:37:56 - 1.2 +++ connector-client-factory.mf 23 Mar 2002 21:11:02 - 1.3 @@ -1,5 +1,5 @@ Main-Class: org.jboss.jmx.connector.TestClient -Class-Path: ./ ./jmx-rmi-connector-client.jar ./jmx-ejb-connector-client.jar ./jmxri.jar ../lib/jmxri.jar ./jnp-client.jar ../lib/jnp-client.jar ./log4j.jar +Class-Path: ./ ./jmx-rmi-connector-client.jar ./jmx-ejb-connector-client.jar ./jboss-jmx.jar ../lib/jboss-jmx.jar ./jnp-client.jar ../lib/jnp-client.jar ./log4j.jar Specification-Title: [EMAIL PROTECTED]@[EMAIL PROTECTED]@[EMAIL PROTECTED]@@version.tag@ Specification-Version: @version.major@[EMAIL PROTECTED]@[EMAIL PROTECTED]@@version.tag@ Specification-Vendor: JBoss Group, LLC 1.2 +1 -1 jboss/src/etc/manifest/deploy.mf Index: deploy.mf === RCS file: /cvsroot/jboss/jboss/src/etc/manifest/deploy.mf,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- deploy.mf 16 Feb 2002 01:33:26 - 1.1 +++ deploy.mf 23 Mar 2002 21:11:02 - 1.2 @@ -1,2 +1,2 @@ Main-Class: org.jboss.jmx.service.Deployer -Class-Path: ./ jnp-client.jar jmxri.jar ../conf/ ../lib/jmxri.jar +Class-Path: ./ jnp-client.jar jboss-jmx.jar ../conf/ ../lib/jboss-jmx.jar 1.4 +1 -1 jboss/src/etc/manifest/ejb-connector-client.mf Index: ejb-connector-client.mf === RCS file: /cvsroot/jboss/jboss/src/etc/manifest/ejb-connector-client.mf,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- ejb-connector-client.mf 17 Feb 2002 09:52:52 - 1.3 +++ ejb-connector-client.mf 23 Mar 2002 21:11:02 - 1.4 @@ -1 +1 @@ -Class-Path: ./ ./jmxri.jar ../lib/jmxri.jar ./jnp-client.jar ./jboss-j2ee.jar ./jboss-client.jar ./jbossmq-client.jar ./log4j.jar +Class-Path: ./ ./jboss-jmx.jar ../lib/jboss-jmx.jar ./jnp-client.jar ./jboss-j2ee.jar ./jboss-client.jar ./jbossmq-client.jar ./log4j.jar 1.4 +1 -1 jboss/src/etc/manifest/ejb-connector.mf Index: ejb-connector.mf === RCS file: /cvsroot/jboss/jboss/src/etc/manifest/ejb-connector.mf,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- ejb-connector.mf 17 Feb 2002 09:52:52 - 1.3 +++ ejb-connector.mf 23 Mar 2002 21:11:02 - 1.4 @@ -1,2 +1,2 @@ Main-Class: org.jboss.jmx.connector.ejb.TestClient -Class-Path: ./ ../lib/jmxri.jar ./jnp-client.jar ./jboss-j2ee.jar ./jboss-client.jar ./jbossmq-client.jar ./log4j.jar +Class-Path: ./ ../lib/jboss-jmx.jar ./jnp-client.jar ./jboss-j2ee.jar ./jboss-client.jar ./jbossmq-client.jar ./log4j.jar 1.3 +1 -1 jboss/src/etc/manifest/rmi-adaptor.mf Index: rmi-adaptor.mf === RCS file: /cvsroot/jboss/jboss/src/etc/manifest/rmi-adaptor.mf,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- rmi-adaptor.mf17 Feb 2002 08:37:56 - 1.2 +++ rmi-adaptor.mf23 Mar 2002 21:11:02 - 1.3 @@ -1,5 +1,5 @@ Main-Class: org.jboss.jmx.connector.rmi.TestServer -Class-Path: ./ ./jmxri.jar ../lib/jmxri.jar ./jnpserver.jar ../lib/ext/jnpserver.jar ./log4j.jar +Class-Path: ./ ./jboss-jmx.jar ../lib/jboss-jmx.jar ./jnpserver.jar ../lib/ext/jnpserver.jar ./log4j.jar Specification-Title: [EMAIL PROTECTED]@[EMAIL PROTECTED]@[EMAIL PROTECTED]@@version.tag@ Specification-Version: @version.major@[EMAIL PROTECTED]@[EMAIL PROTECTED]@@version.tag@ Specification-Vendor: JBoss Group, LLC 1.2 +1 -1 jboss/src/etc/manifest/rmi-connector-client.mf Index: rmi-connector-client.mf === RCS file: /cvsroot/jboss/jboss/src/etc/manifest/rmi-connector-client.mf,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- rmi-connector-client.mf 16 Feb 2002 01:33:26 - 1.1 +++ rm
[JBoss-dev] CVS update: jboss-management build.xml
User: ejort Date: 02/03/23 13:11:01 Modified:.build.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.4 +9 -9 jboss-management/build.xml Index: build.xml === RCS file: /cvsroot/jboss/jboss-management/build.xml,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- build.xml 11 Mar 2002 22:32:31 - 1.3 +++ build.xml 23 Mar 2002 21:11:01 - 1.4 @@ -12,7 +12,7 @@ - + @@ -69,13 +69,6 @@ - - - - - - - @@ -99,7 +92,6 @@ - @@ -129,11 +121,19 @@ + + + + + + + + ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jbosstest/src/resources/naming/ear/a/META-INF ejb-jar.xml jboss.xml
User: ejort Date: 02/03/23 13:11:04 Modified:src/resources/naming/ear/a/META-INF ejb-jar.xml jboss.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.2 +2 -0 jbosstest/src/resources/naming/ear/a/META-INF/ejb-jar.xml Index: ejb-jar.xml === RCS file: /cvsroot/jboss/jbosstest/src/resources/naming/ear/a/META-INF/ejb-jar.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- ejb-jar.xml 17 Mar 2002 12:56:30 - 1.1 +++ ejb-jar.xml 23 Mar 2002 21:11:04 - 1.2 @@ -7,6 +7,8 @@ SessionA org.jboss.test.naming.interfaces.TestEjbLinkHome org.jboss.test.naming.interfaces.TestEjbLink + org.jboss.test.naming.interfaces.TestEjbLinkLocalHome + org.jboss.test.naming.interfaces.TestEjbLinkLocal org.jboss.test.naming.ejb.TestEjbLinkBean Stateless Container 1.2 +1 -0 jbosstest/src/resources/naming/ear/a/META-INF/jboss.xml Index: jboss.xml === RCS file: /cvsroot/jboss/jbosstest/src/resources/naming/ear/a/META-INF/jboss.xml,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- jboss.xml 17 Mar 2002 12:56:30 - 1.1 +++ jboss.xml 23 Mar 2002 21:11:04 - 1.2 @@ -5,6 +5,7 @@ SessionA naming/SessionA + naming/local/SessionA ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jboss/src/main/org/jboss/ejb EjbModule.java
User: ejort Date: 02/03/23 13:11:02 Modified:src/main/org/jboss/ejb EjbModule.java Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.14 +40 -10jboss/src/main/org/jboss/ejb/EjbModule.java Index: EjbModule.java === RCS file: /cvsroot/jboss/jboss/src/main/org/jboss/ejb/EjbModule.java,v retrieving revision 1.13 retrieving revision 1.14 diff -u -r1.13 -r1.14 --- EjbModule.java17 Mar 2002 12:59:44 - 1.13 +++ EjbModule.java23 Mar 2002 21:11:02 - 1.14 @@ -9,16 +9,20 @@ import java.lang.reflect.Constructor; +import java.net.MalformedURLException; import java.net.URL; +import java.net.URLClassLoader; import java.rmi.RemoteException; +import java.util.ArrayList; import java.util.Collection; import java.util.HashMap; import java.util.Hashtable; import java.util.Iterator; -import java.util.WeakHashMap; import javax.ejb.EJBLocalHome; +import javax.naming.InitialContext; import javax.management.MBeanServer; import javax.management.ObjectName; +import org.jboss.deployment.DeploymentException; import org.jboss.deployment.DeploymentInfo; import org.jboss.ejb.BeanLockManager; import org.jboss.ejb.Container; @@ -44,10 +48,6 @@ import org.jboss.system.ServiceMBeanSupport; import org.jboss.system.UnifiedClassLoader; import org.jboss.util.jmx.MBeanProxy; -import java.util.ArrayList; -import javax.naming.InitialContext; -import java.net.URLClassLoader; -import org.jboss.deployment.DeploymentException; import org.jboss.verifier.BeanVerifier; import org.jboss.verifier.event.VerificationEvent; import org.jboss.verifier.event.VerificationListener; @@ -78,7 +78,7 @@ * @author mailto:[EMAIL PROTECTED]";>David Jencks * @author mailto:[EMAIL PROTECTED]";>Francisco Reverbel * @author mailto:[EMAIL PROTECTED]";>Adrian.Brock - * @version $Revision: 1.13 $ + * @version $Revision: 1.14 $ * * @jmx:mbean extends="org.jboss.system.ServiceMBean" */ @@ -135,7 +135,7 @@ // Static /** Stores a map of DeploymentInfos to EjbModules. */ - private static WeakHashMap ejbModulesByDeploymentInfo = new WeakHashMap(); + private static HashMap ejbModulesByDeploymentInfo = new HashMap(); // Public @@ -145,9 +145,6 @@ { this.deploymentInfo = di; this.name = deploymentInfo.url.toString(); - - // Keep track of which deployments are ejbModules - ejbModulesByDeploymentInfo.put(di, this); } /** @@ -286,6 +283,12 @@ // Service implementation public void createService() throws Exception { + // Keep track of which deployments are ejbModules + synchronized(ejbModulesByDeploymentInfo) + { + ejbModulesByDeploymentInfo.put(deploymentInfo, this); + } + serviceController = (ServiceControllerMBean) MBeanProxy.create(ServiceControllerMBean.class, ServiceControllerMBean.OBJECT_NAME, @@ -442,6 +445,12 @@ { EJBModule.destroy(server, getModuleName().toString() ); } + + // Keep track of which deployments are ejbModules + synchronized(ejbModulesByDeploymentInfo) + { + ejbModulesByDeploymentInfo.remove(deploymentInfo); + } } // ** @@ -930,6 +939,10 @@ */ private Container locateContainer(String name) { + // Check for a relative path + if (name.startsWith("..")) + return locateContainerRelative(name); + // Get the top level deployment DeploymentInfo info = deploymentInfo; while (info.parent != null) @@ -974,6 +987,23 @@ } // Nothing found + return null; + } + + /** +* Find a container from this deployment package, used to process ejb-link +* that is a relative path +* +* Determines the path based on the url. +* +* @param name ejb-name name defined in ejb-jar.xml in some jar in +* the same deployment package +* @return container for the named bean, or null if the container was +* not found +*/ + private Container locateContainerRelative(String name) + { + log.warn("Not implemented: " + name); return null; } } ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jboss-ejb build.xml
User: ejort Date: 02/03/23 13:11:00 Modified:.build.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.3 +9 -9 jboss-ejb/build.xml Index: build.xml === RCS file: /cvsroot/jboss/jboss-ejb/build.xml,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- build.xml 28 Feb 2002 04:08:02 - 1.2 +++ build.xml 23 Mar 2002 21:11:00 - 1.3 @@ -12,7 +12,7 @@ - + @@ -69,13 +69,6 @@ - - - - - - - @@ -85,15 +78,22 @@ - + + + + + + + + ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jmx build.xml
User: ejort Date: 02/03/23 13:11:01 Modified:.build.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.30 +21 -1 jmx/build.xml Index: build.xml === RCS file: /cvsroot/jboss/jmx/build.xml,v retrieving revision 1.29 retrieving revision 1.30 diff -u -r1.29 -r1.30 --- build.xml 14 Mar 2002 18:28:25 - 1.29 +++ build.xml 23 Mar 2002 21:11:01 - 1.30 @@ -12,7 +12,7 @@ - + @@ -287,6 +287,26 @@ + + + + + + + + + + + + + + + + + + + + ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jbosscx build.xml
User: ejort Date: 02/03/23 13:11:00 Modified:.build.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.33 +9 -9 jbosscx/build.xml Index: build.xml === RCS file: /cvsroot/jboss/jbosscx/build.xml,v retrieving revision 1.32 retrieving revision 1.33 diff -u -r1.32 -r1.33 --- build.xml 22 Mar 2002 01:37:45 - 1.32 +++ build.xml 23 Mar 2002 21:11:00 - 1.33 @@ -12,7 +12,7 @@ - + @@ -69,13 +69,6 @@ - - - - - - - @@ -108,7 +101,6 @@ - @@ -162,6 +154,13 @@ + + + + + + + @@ -170,6 +169,7 @@ + ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jbossmx/src/main/org/jbossmx/cluster/watchdog/agent BaseAgent.java
User: ejort Date: 02/03/23 13:10:59 Modified:src/main/org/jbossmx/cluster/watchdog/agent BaseAgent.java Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.6 +35 -2 jbossmx/src/main/org/jbossmx/cluster/watchdog/agent/BaseAgent.java Index: BaseAgent.java === RCS file: /cvsroot/jboss/jbossmx/src/main/org/jbossmx/cluster/watchdog/agent/BaseAgent.java,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- BaseAgent.java8 Oct 2001 16:52:59 - 1.5 +++ BaseAgent.java23 Mar 2002 21:10:59 - 1.6 @@ -372,8 +372,7 @@ { try { -return (String) m_server.invoke(m_rmiConnectorObjectName, "getJNDIName", -m_sEmptyObject, m_sEmptyString); +return (String) m_server.getAttribute(m_rmiConnectorObjectName, "JNDIName"); } catch(Exception e) { @@ -428,6 +427,40 @@ { //LOG.warning(infe); +throw new RemoteException("", infe); +} +} + +/** + * Get an attribute from an MBean. + * + * @paramobjectName The object name of the MBean. + * @paramattrName The name of the attribute. + * + * @return The object returned by the operation, which represents the value of the attribute. + * @throws RemoteException + */ +public Object getMBeanAttribute(String objectName, String attrName) +throws RemoteException +{ +try +{ +return m_server.getAttribute(new ObjectName(objectName), attrName) +} +catch(MalformedObjectNameException mone) +{ +throw new RemoteException("", mone); +} +catch(ReflectionException re) +{ +throw new RemoteException("", re); +} +catch(MBeanException me) +{ +throw new RemoteException("", me); +} +catch(InstanceNotFoundException infe) +{ throw new RemoteException("", infe); } } ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jboss-common/src/main/org/jboss/util/jmx MBeanProxy.java
User: ejort Date: 02/03/23 13:11:00 Modified:src/main/org/jboss/util/jmx MBeanProxy.java Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.3 +99 -3 jboss-common/src/main/org/jboss/util/jmx/MBeanProxy.java Index: MBeanProxy.java === RCS file: /cvsroot/jboss/jboss-common/src/main/org/jboss/util/jmx/MBeanProxy.java,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- MBeanProxy.java 5 Mar 2002 02:59:52 - 1.2 +++ MBeanProxy.java 23 Mar 2002 21:11:00 - 1.3 @@ -13,16 +13,29 @@ import java.lang.reflect.Proxy; import java.lang.reflect.InvocationHandler; +import java.util.HashMap; + +import javax.management.Attribute; +import javax.management.InstanceNotFoundException; +import javax.management.MBeanAttributeInfo; +import javax.management.MBeanInfo; import javax.management.MBeanServer; import javax.management.ObjectName; import javax.management.MalformedObjectNameException; /** * A factory for producing MBean proxies. - * + * + * Revisions: + * 20020321 Adrian Brock: + * + * Don't process attributes using invoke. + * + * * @author mailto:[EMAIL PROTECTED]";>Rickard Öberg. * @author mailto:[EMAIL PROTECTED]";>Jason Dillon - * @version $Revision: 1.2 $ + * @author mailto:[EMAIL PROTECTED]";>Adrian Brock. + * @version $Revision: 1.3 $ */ public class MBeanProxy implements InvocationHandler @@ -32,6 +45,9 @@ /** The name of the object to invoke. */ private final ObjectName name; + + /** The MBean's attributes */ + private HashMap attributeMap = new HashMap(); /** * Construct a MBeanProxy. @@ -48,6 +64,20 @@ { this.name = name; this.server = server; + + // The MBean's attributes + try + { + MBeanInfo info = server.getMBeanInfo(name); + MBeanAttributeInfo[] attributes = info.getAttributes(); + + for (int i = 0; i < attributes.length; ++i) +attributeMap.put(attributes[i].getName(), attributes[i]); + } + catch (Exception e) + { + throw new RuntimeException("Error creating MBeanProxy: " + name); + } } /** @@ -59,6 +89,72 @@ Object[] args) throws Throwable { + String methodName = method.getName(); + + // Get attribute + if (methodName.startsWith("get") && args == null) + { + String attrName = methodName.substring(3); + MBeanAttributeInfo info = (MBeanAttributeInfo) attributeMap.get(attrName); + if (info != null) + { +String retType = method.getReturnType().getName(); +if (retType.equals(info.getType())) +{ + try + { + return server.getAttribute(name, attrName); + } + catch (Exception e) + { + throw JMXExceptionDecoder.decode(e); + } +} + } + } + + // Is attribute + else if (methodName.startsWith("is") && args == null) + { + String attrName = methodName.substring(2); + MBeanAttributeInfo info = (MBeanAttributeInfo) attributeMap.get(attrName); + if (info != null && info.isIs()) + { +Class retType = method.getReturnType(); +if (retType.equals(Boolean.class) || retType.equals(Boolean.TYPE)) +{ + try + { + return server.getAttribute(name, attrName); + } + catch (Exception e) + { + throw JMXExceptionDecoder.decode(e); + } +} + } + } + + // Set attribute + else if (methodName.startsWith("set") && args != null && args.length == 1) + { + String attrName = methodName.substring(3); + MBeanAttributeInfo info = (MBeanAttributeInfo) attributeMap.get(attrName); + if (info != null && method.getReturnType() == Void.TYPE) + { +try +{ + server.setAttribute(name, new Attribute(attrName, args[0])); + return null; +} +catch (Exception e) +{ + throw JMXExceptionDecoder.decode(e); +} + } + } + + // Operation if (args == null) args = new Object[0];
[JBoss-dev] CVS update: jbossmx/src/main/org/jbossmx/cluster/watchdog/mbean Watchdog.java
User: ejort Date: 02/03/23 13:10:59 Modified:src/main/org/jbossmx/cluster/watchdog/mbean Watchdog.java Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.6 +1 -5 jbossmx/src/main/org/jbossmx/cluster/watchdog/mbean/Watchdog.java Index: Watchdog.java === RCS file: /cvsroot/jboss/jbossmx/src/main/org/jbossmx/cluster/watchdog/mbean/Watchdog.java,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- Watchdog.java 4 Dec 2001 22:34:01 - 1.5 +++ Watchdog.java 23 Mar 2002 21:10:59 - 1.6 @@ -1087,8 +1087,6 @@ { result = ((Integer) m_server.invoke(objectName, "retrieveMBeanState", new Object[0], new String[0])).intValue(); - -//result = ((Integer) m_server.invoke(objectInstance.getObjectName(), "getMBeanState", new Object[0], new String[0])).intValue(); } catch(Exception e) { @@ -1616,8 +1614,6 @@ Integer result = (Integer) m_server.invoke(objectName,"retrieveMBeanState", new Object[0], new String[0]); -//m_server.invoke(objectInstance.getObjectName(), "getMBeanState", new Object[0], new String[0]); - running = (result.intValue() == Startable.RUNNING); } catch(Exception e) @@ -1745,7 +1741,7 @@ m_watchdogEventManagerObjectName = objectName; m_watchdogEventManagerRemoteInterface = (WatchdogEventManagerRemoteInterface) -m_server.invoke(objectName, "getRemoteInterface", new Object[0], new String[0]); +m_server.getAttribute(objectName, "RemoteInterface"); } /** ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jbossmx build.xml
User: ejort Date: 02/03/23 13:10:59 Modified:.build.xml Log: JBoss/JBossMX integration. Also includes a fix to the cluster tests and a more complete ejblink test that currently fails Revision ChangesPath 1.32 +9 -9 jbossmx/build.xml Index: build.xml === RCS file: /cvsroot/jboss/jbossmx/build.xml,v retrieving revision 1.31 retrieving revision 1.32 diff -u -r1.31 -r1.32 --- build.xml 28 Feb 2002 04:08:01 - 1.31 +++ build.xml 23 Mar 2002 21:10:59 - 1.32 @@ -12,7 +12,7 @@ - + @@ -69,13 +69,6 @@ - - - - - - - @@ -131,7 +124,6 @@ - @@ -187,6 +179,13 @@ + + + + + + + @@ -195,6 +194,7 @@ + ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] CVS locks?
Hi Scott, I didn't think the local tags would be very useful, except to me if I had to reverse the mod on individual sources. Yes, I am trying to get a before and after snapshot. Perhaps I should just stop worrying about it and keep a diff in a safe place. Regards, Adrian > What is the purpose of the tag your trying to apply? > If > your trying to define snaphosts before and after a > move > to the JBossMX JMX implementation this can be done > after the fact using tags based on timestamps. The > lastest > checkin was at Mar 22, 2002 8:55 PM PST. You can use > the > rtag command to apply the Rel_3_x_y tags after the > lock has > been cleared. I have updated the request to remove > the stale > locks so hopefully this won't take too long. If there > are no > changes to the jetty module you could tag everything > but that > module and apply the tags after the lock is cleared > as both tags > will point to the same versions in the jetty module. > > Setting a tag that is local to a few files is not > very useful > > > Scott Stark > Chief Technology Officer > JBoss Group, LLC > > - Original Message - > From: "Adrian Brock" <[EMAIL PROTECTED]> > To: <[EMAIL PROTECTED]> > Sent: Saturday, March 23, 2002 10:11 AM > Subject: Re: [JBoss-dev] CVS locks? > > > > I've got just over 40 source modifications. > > > > Is it acceptable to tag individually using a > > non Rel_3_* tag? > > > > I can do the tagging by hand on individual sources. > > > > Alternatively, I could just commit the changes. > > There are already java 1.4 users using jbossmx with > > jboss3 to solve the jsr77 problem, but these > probably > > aren't live users using it in anger. > > > > Regards, > > Adrian > > > > > > ___ > Jboss-development mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-dev > lopment _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11429 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] CVS locks?
I've got just over 40 source modifications. Is it acceptable to tag individually using a non Rel_3_* tag? I can do the tagging by hand on individual sources. Alternatively, I could just commit the changes. There are already java 1.4 users using jbossmx with jboss3 to solve the jsr77 problem, but these probably aren't live users using it in anger. Regards, Adrian > Thanks Scott, > > I'll wait for the locks to go away. > > Regards, > Adrian > > > No. You can tag latter by date or version. Tagging > > does not work on the working directory so you > can't > > just tag your local copy. > > > > > > Scott Stark > > Chief Technology Officer > > JBoss Group, LLC > > > > - Original Message - > > From: "Adrian Brock" <[EMAIL PROTECTED]> > > To: <[EMAIL PROTECTED]> > > Sent: Saturday, March 23, 2002 8:34 AM > > Subject: Re: [JBoss-dev] CVS locks? > > > > > > > IANACVSE - I am not a CVS expert :-) > > > > > > It is correct that I can tag later if I keep > > > CVS snapshots before and after my commit? > > > > > > Regards, > > > Adrian > > > > > > > Hi Jason, > > > > > > > > Sorry for the delay. If I'd just hung around > 15 > > mins > > > > :-) > > > > > > > > The full path is > > > > > > > /cvsroot/jboss/contrib/jetty/src/main/org/mortbay/jett > > > > > /jmx > > > > > > > > The locks are held by anoncvs_jboss and > maximal > > > > > > > > Regards, > > > > Adrian > > > > > > > > > Can you tell me what the full paths are that > > are > > > > > locked. > > > > > > > > > > --jason > > > > > > > > > > > > > > > Adrian Brock wrote: > > > > > > > > > > >Hi, > > > > > > > > > > > >Is there a problem with locks in cvs? Or is > > this > > > > > >deliberate? > > > > > > > > > > > >I'm trying to tag cvs before committing the > > > > jbossmx > > > > > >integration in case there's a problem. > > > > > > > > > > > >I've got two people locking jetty/jmx, one > is > > > > > anoncvs. > > > > > >They've had the lock for over an hour. > > > > > > > > > > > >Anyway, I'm going to get a couple of hours > > sleep > > > > > before > > > > > >trying again. > > > > > > > > > > > >Regards, > > > > > >Adrian > > > > > > > > > > > > >_ > > > > > > > > > > ___ > > > > > >View thread online: > > > > > > > > > > > > http://main.jboss.org/thread.jsp?forum=66&thread=11429 > > > > > > > > > > > > > > > > > > >___ > > > > > >Jboss-development mailing list > > > > > >[EMAIL PROTECTED] > > > > > > > > > > > > >https://lists.sourceforge.net/lists/listinfo/jboss-de > > > > > > > > > > elopment > > > > > > > > > > > > > > > > > > > > > > > > > > > ___ > > > > > Jboss-development mailing list > > > > > [EMAIL PROTECTED] > > > > > > > > > > > > https://lists.sourceforge.net/lists/listinfo/jboss-dev > > > > > > > > > > lopment > > > > > > > > > > > > > > > > __ > > > __ > > > View thread online: > > > http://main.jboss.org/thread.jsp?forum=66&thread=11429 > > > > > > > ___ > > > Jboss-development mailing list > > > [EMAIL PROTECTED] > > > > > > https://lists.sourceforge.net/lists/listinfo/jboss-dev > > > lopment > > > > > > > > > ___ > > Jboss-development mailing list > > [EMAIL PROTECTED] > > > https://lists.sourceforge.net/lists/listinfo/jboss-dev > > > lopment > _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11429 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] CVS locks?
Thanks Scott, I'll wait for the locks to go away. Regards, Adrian > No. You can tag latter by date or version. Tagging > does not work on the working directory so you can't > just tag your local copy. > > > Scott Stark > Chief Technology Officer > JBoss Group, LLC > > - Original Message - > From: "Adrian Brock" <[EMAIL PROTECTED]> > To: <[EMAIL PROTECTED]> > Sent: Saturday, March 23, 2002 8:34 AM > Subject: Re: [JBoss-dev] CVS locks? > > > > IANACVSE - I am not a CVS expert :-) > > > > It is correct that I can tag later if I keep > > CVS snapshots before and after my commit? > > > > Regards, > > Adrian > > > > > Hi Jason, > > > > > > Sorry for the delay. If I'd just hung around 15 > mins > > > :-) > > > > > > The full path is > > > > /cvsroot/jboss/contrib/jetty/src/main/org/mortbay/jett > > > /jmx > > > > > > The locks are held by anoncvs_jboss and maximal > > > > > > Regards, > > > Adrian > > > > > > > Can you tell me what the full paths are that > are > > > > locked. > > > > > > > > --jason > > > > > > > > > > > > Adrian Brock wrote: > > > > > > > > >Hi, > > > > > > > > > >Is there a problem with locks in cvs? Or is > this > > > > >deliberate? > > > > > > > > > >I'm trying to tag cvs before committing the > > > jbossmx > > > > >integration in case there's a problem. > > > > > > > > > >I've got two people locking jetty/jmx, one is > > > > anoncvs. > > > > >They've had the lock for over an hour. > > > > > > > > > >Anyway, I'm going to get a couple of hours > sleep > > > > before > > > > >trying again. > > > > > > > > > >Regards, > > > > >Adrian > > > > > > > > >_ > > > > > > > ___ > > > > >View thread online: > > > > > > > > http://main.jboss.org/thread.jsp?forum=66&thread=11429 > > > > > > > > > > > > > >___ > > > > >Jboss-development mailing list > > > > >[EMAIL PROTECTED] > > > > > > > > >https://lists.sourceforge.net/lists/listinfo/jboss-de > > > > > > > elopment > > > > > > > > > > > > > > > > > > > > > ___ > > > > Jboss-development mailing list > > > > [EMAIL PROTECTED] > > > > > > > > https://lists.sourceforge.net/lists/listinfo/jboss-dev > > > > > > > lopment > > > > > > > > > > __ > __ > > View thread online: > http://main.jboss.org/thread.jsp?forum=66&thread=11429 > > > > ___ > > Jboss-development mailing list > > [EMAIL PROTECTED] > > > https://lists.sourceforge.net/lists/listinfo/jboss-dev > lopment > > > > > ___ > Jboss-development mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-dev > lopment _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11429 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] CVS locks?
IANACVSE - I am not a CVS expert :-) It is correct that I can tag later if I keep CVS snapshots before and after my commit? Regards, Adrian > Hi Jason, > > Sorry for the delay. If I'd just hung around 15 mins > :-) > > The full path is > /cvsroot/jboss/contrib/jetty/src/main/org/mortbay/jett > /jmx > > The locks are held by anoncvs_jboss and maximal > > Regards, > Adrian > > > Can you tell me what the full paths are that are > > locked. > > > > --jason > > > > > > Adrian Brock wrote: > > > > >Hi, > > > > > >Is there a problem with locks in cvs? Or is this > > >deliberate? > > > > > >I'm trying to tag cvs before committing the > jbossmx > > >integration in case there's a problem. > > > > > >I've got two people locking jetty/jmx, one is > > anoncvs. > > >They've had the lock for over an hour. > > > > > >Anyway, I'm going to get a couple of hours sleep > > before > > >trying again. > > > > > >Regards, > > >Adrian > > > >_ > > > ___ > > >View thread online: > > > http://main.jboss.org/thread.jsp?forum=66&thread=11429 > > > > > > >___ > > >Jboss-development mailing list > > >[EMAIL PROTECTED] > > > >https://lists.sourceforge.net/lists/listinfo/jboss-de > > > elopment > > > > > > > > > > > ___ > > Jboss-development mailing list > > [EMAIL PROTECTED] > > > https://lists.sourceforge.net/lists/listinfo/jboss-dev > > > lopment > _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11429 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] CVS locks?
Hi Jason, Sorry for the delay. If I'd just hung around 15 mins :-) The full path is /cvsroot/jboss/contrib/jetty/src/main/org/mortbay/jetty/jmx The locks are held by anoncvs_jboss and maximal Regards, Adrian > Can you tell me what the full paths are that are > locked. > > --jason > > > Adrian Brock wrote: > > >Hi, > > > >Is there a problem with locks in cvs? Or is this > >deliberate? > > > >I'm trying to tag cvs before committing the jbossmx > >integration in case there's a problem. > > > >I've got two people locking jetty/jmx, one is > anoncvs. > >They've had the lock for over an hour. > > > >Anyway, I'm going to get a couple of hours sleep > before > >trying again. > > > >Regards, > >Adrian > >_ > ___ > >View thread online: > http://main.jboss.org/thread.jsp?forum=66&thread=11429 > > > >___ > >Jboss-development mailing list > >[EMAIL PROTECTED] > >https://lists.sourceforge.net/lists/listinfo/jboss-de > elopment > > > > > > ___ > Jboss-development mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-dev > lopment _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11429 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS locks?
Hi, Is there a problem with locks in cvs? Or is this deliberate? I'm trying to tag cvs before committing the jbossmx integration in case there's a problem. I've got two people locking jetty/jmx, one is anoncvs. They've had the lock for over an hour. Anyway, I'm going to get a couple of hours sleep before trying again. Regards, Adrian _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11429 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jbosstest/src/main/org/jboss/test/naming/ejb TestEjbLinkBean.java
User: ejort Date: 02/03/22 17:55:54 Modified:src/main/org/jboss/test/naming/ejb TestEjbLinkBean.java Log: Ejb link beans Revision ChangesPath 1.2 +21 -1 jbosstest/src/main/org/jboss/test/naming/ejb/TestEjbLinkBean.java Index: TestEjbLinkBean.java === RCS file: /cvsroot/jboss/jbosstest/src/main/org/jboss/test/naming/ejb/TestEjbLinkBean.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- TestEjbLinkBean.java 17 Mar 2002 12:56:29 - 1.1 +++ TestEjbLinkBean.java 23 Mar 2002 01:55:54 - 1.2 @@ -11,11 +11,13 @@ import org.jboss.test.naming.interfaces.TestEjbLinkHome; import org.jboss.test.naming.interfaces.TestEjbLink; +import org.jboss.test.naming.interfaces.TestEjbLinkLocalHome; +import org.jboss.test.naming.interfaces.TestEjbLinkLocal; /** A bean that tests ejb-link works @author mailto:[EMAIL PROTECTED]";>Adrian.Brock -@version $Revision: 1.1 $ +@version $Revision: 1.2 $ */ public class TestEjbLinkBean implements SessionBean { @@ -51,6 +53,24 @@ TestEjbLinkHome home = (TestEjbLinkHome) PortableRemoteObject.narrow(object, TestEjbLinkHome.class); TestEjbLink bean = home.create(); + return bean.testEjbLinkCalled(); + } + catch (Exception e) + { + log.debug("failed", e); + return "Failed"; + } +} + +public String testEjbLinkCallerLocal(String jndiName) +{ + try + { + InitialContext initial = new InitialContext(); + Object object = initial.lookup(jndiName); + TestEjbLinkLocalHome home = +(TestEjbLinkLocalHome) PortableRemoteObject.narrow(object, TestEjbLinkLocalHome.class); + TestEjbLinkLocal bean = home.create(); return bean.testEjbLinkCalled(); } catch (Exception e) ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jbosstest/src/main/org/jboss/test/naming/interfaces TestEjbLinkLocal.java TestEjbLinkLocalHome.java TestEjbLink.java
User: ejort Date: 02/03/22 16:54:14 Modified:src/main/org/jboss/test/naming/interfaces TestEjbLink.java Added: src/main/org/jboss/test/naming/interfaces TestEjbLinkLocal.java TestEjbLinkLocalHome.java Log: EjbLink test interfaces Revision ChangesPath 1.2 +7 -0 jbosstest/src/main/org/jboss/test/naming/interfaces/TestEjbLink.java Index: TestEjbLink.java === RCS file: /cvsroot/jboss/jbosstest/src/main/org/jboss/test/naming/interfaces/TestEjbLink.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- TestEjbLink.java 17 Mar 2002 12:56:29 - 1.1 +++ TestEjbLink.java 23 Mar 2002 00:54:14 - 1.2 @@ -7,7 +7,7 @@ /** @author mailto:[EMAIL PROTECTED]";>Adrian.Brock -@version $Revision: 1.1 $ +@version $Revision: 1.2 $ */ public interface TestEjbLink extends EJBObject { @@ -17,6 +17,13 @@ * @return the result of the call or "Failed" on an error */ public String testEjbLinkCaller(String jndiName) + throws RemoteException; + /** +* Call a bean with the passed jndi name bound using ejb-link +* @param jndiName the name of the bean specified in ejb-ref +* @return the result of the call or "Failed" on an error +*/ + public String testEjbLinkCallerLocal(String jndiName) throws RemoteException; /** 1.1 jbosstest/src/main/org/jboss/test/naming/interfaces/TestEjbLinkLocal.java Index: TestEjbLinkLocal.java === package org.jboss.test.naming.interfaces; import java.rmi.RemoteException; import javax.ejb.EJBLocalObject; /** @author mailto:[EMAIL PROTECTED]";>Adrian.Brock @version $Revision: 1.1 $ */ public interface TestEjbLinkLocal extends EJBLocalObject { /** * Call a bean with the passed jndi name bound using ejb-link * @param jndiName the name of the bean specified in ejb-ref * @return the result of the call or "Failed" on an error */ public String testEjbLinkCallerLocal(String jndiName) throws RemoteException; /** * Called by a bean specified in ejb-link * @return the string "Works" */ public String testEjbLinkCalled() throws RemoteException; } 1.1 jbosstest/src/main/org/jboss/test/naming/interfaces/TestEjbLinkLocalHome.java Index: TestEjbLinkLocalHome.java === package org.jboss.test.naming.interfaces; import java.rmi.RemoteException; import javax.ejb.CreateException; import javax.ejb.EJBLocalHome; /** @author mailto:[EMAIL PROTECTED]>Adrian Brock @version $Revision: 1.1 $ */ public interface TestEjbLinkLocalHome extends EJBLocalHome { public TestEjbLinkLocal create() throws CreateException, RemoteException; } ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: RE: [JBoss-dev] JBoss/JBossMX integeration
Sorry for the delay response. Ok, I'll keep it simple for now. I'll create a jboss-jmx-core.jar and jboss-jmx-services.jar We'll keep jboss-jmx.jar as everything for standalone distribution. On the modules point, you can checkout jboss modules individually. I want to modify all these standalone modules to include the jmx module. e.g. cvs co common also brings down jmx Time to sync my tree and retest. :-) Regards, Adrian _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11391 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] JBoss/JBossMX integeration
Hi, I believe we are ready to integrate JBoss and JBossMX. This will mean our only use of jmxri.jar is to run Sun's HTML adaptor. This will also be removed in time. There are only three objections I can think of. 1) Until the jmx1.1 spec comes out (long overrdue) we aren't serialverid compatible (it's not defined in jmx1.0) 2) jmx is core to most modules, most standalone modules are modified to also checkout the jmx module. 3) The jbossmx timer service currently uses oswego's concurrent.jar. This means concurrent.jar has to be in the server loader's initial path for the scheduler to work (it's on my list to remove this dependency) If nobody has any objections I would like to integrate this weekend. When I'm not watching England beat Wales at rugby :-) Regards, Adrian _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=11391 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] [ jboss-Bugs-525412 ] EAR Deployment Problem with
Hi, I've committed a fix for the problem below, but I've hit a snag with njar :-( I nearly got the ../products/product.jar#EJBProduct working from the EJB2.0 spec. But when I use new URL(context, spec) the njar separator is removed. e.g. if the above link is referenced from njar:file:/longpath/someapp.ear^/some.jar you get njar:file:/longpath/someapp.ear/products/product.jar#EJBProduct instead of the required njar:file:/longpath/someapp.ear^/products/product.jar#EJBProduct I think I've got to implement parseURL() in the njar's handler. Is this the correct solution or does somebody know a better way of doing this? PS. There's a memory leak in the committed version, which I've already fixed and I've also got tests for now as well. Regards, Adrian > Bugs item #525412, was opened at 2002-03-04 07:47 > You can respond by visiting: > http://sourceforge.net/tracker/?func=detail&atid=37668 > &aid=525412&group_id=22866 > > >Category: JBossServer > Group: v3.0 Rabbit Hole > Status: Open > Resolution: None > Priority: 5 > Submitted By: Peter Luttrell (objec) > >Assigned to: Adrian Brock (ejort) > Summary: EAR Deployment Problem with > > Initial Comment: > > According to the dtd for an ejb-jar, > (http://java.sun.com/dtd/ejb-jar_2_0.dtd), the value > of > the element must be . or in > another > ejb-jar file in the same J2EE application unit. > > I take this to mean that you can use the name of a > bean > in another ejb-jar within an ear. In my attached > example, the Titan.ear file contains 2 ejb jars: > CabinEJB.jar and TravelAgentEJB.jar. In the > deployment > descriptor for TravelAgentEJB, I have an > CabinEJB. "CabinEJB" is the name > of the entity bean within CabinEJB.jar. > > If I deploy this ear on JBoss3.0.0beta, deployment > fails because "CabinEJB" is not found. Based on my > intrepetation of the spec, I expect it to deploy > without a problem. > > Note that if I rearrange my deployment, such that > both > ejbs are in the same jar file with the same > deployment > descriptor, JBoss3.0.0beta deploys it perfectly. > > JBoss dist: JBoss3.0.0 + Tomcat 4.0.2 posted to > sourceforge on 2002-02-22 > OS: Redhat7.2 > jdk: 1.3.1 > > To run the sample, which illistrates the problem: > open > up the build script and set your jboss install dir, > then run the deploy-as-an-ear target. If you want to > see it work as an ejb jar run deploy-as-a-single-jar > target. > > Here's the first exception caused by this problem: > > ERROR [StatelessSessionContainer] > Exception > in service lifecycle operation: create > org.jboss.deployment.DeploymentException: Bean > CabinEJB > not found within this applicaion. > at > org.jboss.ejb.Container.setupEnvironment(Continer.java > 906) > > > Note that the sample code is from Richard > Monson-Haefel's book titled Enterprise JavaBeans. > > > -- > --- > > >Comment By: Adrian Brock (ejort) > Date: 2002-03-16 20:36 > > Message: > Logged In: YES > user_id=9459 > > The ear (deployment) level list of containers has > been > lost during the modifications to include ejbs in sars > at any > level. > The ejb-link is only checking for containers in the > same jar. > > Regards, > Adrian > > -- > --- > > You can respond by visiting: > http://sourceforge.net/tracker/?func=detail&atid=37668 > &aid=525412&group_id=22866 > > ___ > Jboss-development mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-dev > lopment _ View thread online: http://main.jboss.org/thread.jsp?forum=66&thread=10112 ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] CVS update: jboss/src/main/org/jboss/ejb Container.java EjbModule.java
User: ejort Date: 02/03/17 04:59:45 Modified:src/main/org/jboss/ejb Container.java EjbModule.java Log: ejb-link fix for ears Revision ChangesPath 1.83 +3 -3 jboss/src/main/org/jboss/ejb/Container.java Index: Container.java === RCS file: /cvsroot/jboss/jboss/src/main/org/jboss/ejb/Container.java,v retrieving revision 1.82 retrieving revision 1.83 diff -u -r1.82 -r1.83 --- Container.java11 Mar 2002 01:26:54 - 1.82 +++ Container.java17 Mar 2002 12:59:44 - 1.83 @@ -82,7 +82,7 @@ * @author mailto:[EMAIL PROTECTED]";>Scott Stark. * @author Bill Burke * @author mailto:[EMAIL PROTECTED]";>David Jencks -* @version $Revision: 1.82 $ +* @version $Revision: 1.83 $ ** Revisions: * * 2001/07/26 bill burke: @@ -921,7 +921,7 @@ // Internal link if (debug) log.debug("Binding "+ref.getName()+" to internal JNDI source: "+ref.getLink()); - Container refContainer = ejbModule.getContainer(ref.getLink()); + Container refContainer = ejbModule.findContainer(ref.getLink()); if (refContainer == null) throw new DeploymentException ("Bean "+ref.getLink()+" not found within this application."); Util.bind(envCtx, ref.getName(), new LinkRef(refContainer.getBeanMetaData().getJndiName())); @@ -958,7 +958,7 @@ { // Internal link log.debug("Binding "+refName+" to bean source: "+ref.getLink()); - Container refContainer = ejbModule.getContainer(ref.getLink()); + Container refContainer = ejbModule.findContainer(ref.getLink()); if (refContainer == null) { throw new DeploymentException ("Bean "+ref.getLink()+" not found within this application."); 1.13 +103 -16 jboss/src/main/org/jboss/ejb/EjbModule.java Index: EjbModule.java === RCS file: /cvsroot/jboss/jboss/src/main/org/jboss/ejb/EjbModule.java,v retrieving revision 1.12 retrieving revision 1.13 diff -u -r1.12 -r1.13 --- EjbModule.java14 Mar 2002 23:46:49 - 1.12 +++ EjbModule.java17 Mar 2002 12:59:44 - 1.13 @@ -15,6 +15,7 @@ import java.util.HashMap; import java.util.Hashtable; import java.util.Iterator; +import java.util.WeakHashMap; import javax.ejb.EJBLocalHome; import javax.management.MBeanServer; import javax.management.ObjectName; @@ -61,11 +62,14 @@ import org.jboss.util.jmx.ObjectNameFactory; /** - * An Application represents a collection of beans that are deployed as a + * An EjbModule represents a collection of beans that are deployed as a * unit. * - * The beans may use the Application to access other beans within the same + * The beans may use the EjbModule to access other beans within the same *deployment unit. + * + * The beans may use the EjbModule to access other beans within the same + *deployment package (e.g. an ear) using findContainer(String). * * @see Container * @see EJBDeployer @@ -73,7 +77,8 @@ * @author mailto:[EMAIL PROTECTED]";>Rickard Öberg * @author mailto:[EMAIL PROTECTED]";>David Jencks * @author mailto:[EMAIL PROTECTED]";>Francisco Reverbel - * @version $Revision: 1.12 $ + * @author mailto:[EMAIL PROTECTED]";>Adrian.Brock + * @version $Revision: 1.13 $ * * @jmx:mbean extends="org.jboss.system.ServiceMBean" */ @@ -108,14 +113,14 @@ // Attributes - /** Stores the containers for this application unit. */ + /** Stores the containers for this deployment unit. */ HashMap containers = new HashMap(); HashMap localHomes = new HashMap(); - /** Class loader of this application. */ + /** Class loader of this deployment unit. */ ClassLoader classLoader = null; - /** Name of this application, url it was deployed from */ + /** Name of this deployment unit, url it was deployed from */ final String name; private final DeploymentInfo deploymentInfo; @@ -128,6 +133,9 @@ //private MBeanServer server; // Static + + /** Stores a map of DeploymentInfos to EjbModules. */ + private static WeakHashMap ejbModulesByDeploymentInfo = new WeakHashMap(); // Public @@ -137,9 +145,13 @@ { this.deploymentInfo = di; this.name = deploymentInfo.url.toString(); + + // Keep track of which deployments are ejbMo
[JBoss-dev] CVS update: jbosstest/src/resources/naming/jar/META-INF ejb-jar.xml jboss.xml
User: ejort Date: 02/03/17 04:56:30 Added: src/resources/naming/jar/META-INF ejb-jar.xml jboss.xml Log: ejb-link test for an ear Revision ChangesPath 1.1 jbosstest/src/resources/naming/jar/META-INF/ejb-jar.xml Index: ejb-jar.xml === http://java.sun.com/j2ee/dtds/ejb-jar_1_1.dtd";> ENC Tests A session bean on looks up stuff in the ENC ENCBean org.jboss.test.naming.ejb.TestENCBean org.jboss.test.naming.interfaces.TestENCHome org.jboss.test.naming.interfaces.TestENC Stateless Container A flag indicating if the bean should perform the full ENC testsuite hasFullENC java.lang.Boolean true Integer0 Ints/i0 java.lang.Integer 0 Integer1 Ints/i1 java.lang.Integer 1 Float0 Floats/f0 java.lang.Float 0.0 Float1 Floats/f1 java.lang.Float 1.1 String0 Strings/s0 java.lang.String String0 String1 Strings/s1 java.lang.String String1 ejb/bean0 Session ENCBean0 org.jboss.test.naming.interfaces.TestENCHome2 org.jboss.test.naming.interfaces.TestENC ejb/bean1 Session ENCBean1 org.jboss.test.naming.interfaces.TestENCHome org.jboss.test.naming.interfaces.TestENC ejb/remote-bean Session org.jboss.test.naming.interfaces.TestENCHome org.jboss.test.naming.interfaces.TestENC The default DS jdbc/DefaultDS javax.sql.DataSource Container Default Mail mail/DefaultMail javax.mail.Session Container Default QueueFactory jms/QueFactory javax.jms.QueueConnectionFactory Container The JBoss Web Site HomePage url/JBossHomePage java.net.URL Container The SourceForge HomePage url/SourceforgeHomePage java.net.URL Container A test of the resource-env-ref tag res/aQueue javax.jms.Queue Referenced Bean0 Create by TestENCHome2 ENCBean0 org.jboss.test.naming.ejb.TestENCBean org.jboss.test.naming.interfaces.TestENCHome2 org.jboss.test.naming.interfaces.TestENC Stateless Container This bean should NOT have the same ENC as ENCBean hasFullENC java.lang.Boolean false Referenced Bean1 ENCBean1 org.jboss.test.naming.ejb.TestENCBean org.jboss.test.naming.interfaces.TestENCHome org.jboss.test.naming.interfaces.TestENC Stateless Container This bean should NOT have the same ENC as ENCBean hasFullENC java.lang.Boolean false 1.1 jbosstest/src/resources/naming/jar/META-INF/jboss.xml Index: jboss.xml === ENCBean ejb/bean1 jnp://localhost:1099/ENCTests/ejbs/ENCBean1 ejb/remote-bean jnp