Return-Path: Delivered-To: apmail-geronimo-scm-archive@www.apache.org Received: (qmail 34997 invoked from network); 13 Oct 2004 00:56:35 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 13 Oct 2004 00:56:35 -0000 Received: (qmail 57874 invoked by uid 500); 13 Oct 2004 00:56:34 -0000 Delivered-To: apmail-geronimo-scm-archive@geronimo.apache.org Received: (qmail 57845 invoked by uid 500); 13 Oct 2004 00:56:34 -0000 Mailing-List: contact scm-help@geronimo.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: list-post: Reply-To: dev@geronimo.apache.org Delivered-To: mailing list scm@geronimo.apache.org Received: (qmail 57831 invoked by uid 99); 13 Oct 2004 00:56:34 -0000 X-ASF-Spam-Status: No, hits=-10.0 required=10.0 tests=ALL_TRUSTED,NO_REAL_NAME X-Spam-Check-By: apache.org Received: from [209.237.227.194] (HELO minotaur.apache.org) (209.237.227.194) by apache.org (qpsmtpd/0.28) with SMTP; Tue, 12 Oct 2004 17:56:33 -0700 Received: (qmail 34979 invoked by uid 65534); 13 Oct 2004 00:56:32 -0000 Date: 13 Oct 2004 00:56:32 -0000 Message-ID: <20041013005632.34977.qmail@minotaur.apache.org> From: djencks@apache.org To: scm@geronimo.apache.org Subject: svn commit: rev 54717 - geronimo/trunk/modules/naming/src/java/org/apache/geronimo/naming/jmx X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Author: djencks Date: Tue Oct 12 17:56:32 2004 New Revision: 54717 Modified: geronimo/trunk/modules/naming/src/java/org/apache/geronimo/naming/jmx/JMXObjectFactory.java Log: throw ClassCastException if the proxy is not the expected type Modified: geronimo/trunk/modules/naming/src/java/org/apache/geronimo/naming/jmx/JMXObjectFactory.java ============================================================================== --- geronimo/trunk/modules/naming/src/java/org/apache/geronimo/naming/jmx/JMXObjectFactory.java (original) +++ geronimo/trunk/modules/naming/src/java/org/apache/geronimo/naming/jmx/JMXObjectFactory.java Tue Oct 12 17:56:32 2004 @@ -55,7 +55,7 @@ throw new IllegalStateException("Proxy not returned. Target " + jmxRefAddr.getTargetName() + " not started"); } if (!jmxRefAddr.getInterface().isAssignableFrom(proxy.getClass())) { - throw new IllegalStateException("Proxy does not implement expected interface " + jmxRefAddr.getInterface()); + throw new ClassCastException("Proxy does not implement expected interface " + jmxRefAddr.getInterface()); } return proxy; }