Return-Path: Delivered-To: apmail-axis-java-dev-archive@www.apache.org Received: (qmail 21189 invoked from network); 23 Jun 2010 07:16:18 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 23 Jun 2010 07:16:18 -0000 Received: (qmail 47098 invoked by uid 500); 23 Jun 2010 07:16:17 -0000 Delivered-To: apmail-axis-java-dev-archive@axis.apache.org Received: (qmail 46262 invoked by uid 500); 23 Jun 2010 07:16:13 -0000 Mailing-List: contact java-dev-help@axis.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: java-dev@axis.apache.org Delivered-To: mailing list java-dev@axis.apache.org Received: (qmail 46182 invoked by uid 99); 23 Jun 2010 07:16:12 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 23 Jun 2010 07:16:12 +0000 X-ASF-Spam-Status: No, hits=-1538.9 required=10.0 tests=ALL_TRUSTED,AWL X-Spam-Check-By: apache.org Received: from [140.211.11.22] (HELO thor.apache.org) (140.211.11.22) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 23 Jun 2010 07:16:11 +0000 Received: from thor (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id o5N7FosN028027 for ; Wed, 23 Jun 2010 07:15:51 GMT Message-ID: <26054446.11251277277350931.JavaMail.jira@thor> Date: Wed, 23 Jun 2010 03:15:50 -0400 (EDT) From: "gerhard presser (JIRA)" To: java-dev@axis.apache.org Subject: [jira] Commented: (AXIS2-566) Multiple ServiceClients using the same configurationContext causes NPE MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/AXIS2-566?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12881590#action_12881590 ] gerhard presser commented on AXIS2-566: --------------------------------------- I think this issue should be reopened. i can confirm this exact behavior on an axis2 1.5.1 installation. it seems to me, that the problem is, that when using the dynamic service client, both generated AxisServices have the same name. all other service-invocations (stub, anonservice) use unique ids. regards, gerhard > Multiple ServiceClients using the same configurationContext causes NPE > ---------------------------------------------------------------------- > > Key: AXIS2-566 > URL: https://issues.apache.org/jira/browse/AXIS2-566 > Project: Axis2 > Issue Type: Bug > Components: client-api > Affects Versions: 0.95 > Reporter: rnell > > This code causes an NPE. Am I using the API wrong? > public class MultiServiceClientTest extends TestCase { > public MultiServiceClientTest( String name ) { > super( name ); > } > public void test() throws Exception { > ConfigurationContext configurationContext = ConfigurationContextFactory.createConfigurationContextFromFileSystem( null, null ); > URL wsdlURL = new URL( "http://localhost:8080/axis2/services/MyService?wsdl" ); > QName serviceName = new QName( "http://org.apache.axis2/", "MyService" ); > String portName = "MyServicePortType0"; > ServiceClient sender1 = new ServiceClient( configurationContext, wsdlURL, serviceName, portName ); > ServiceClient sender2 = new ServiceClient( configurationContext, wsdlURL, serviceName, portName ); > } > public static void main( String[] args ) { > junit.textui.TestRunner.run( new TestSuite( MultiServiceClientTest.class ) ); > } > } -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: java-dev-unsubscribe@axis.apache.org For additional commands, e-mail: java-dev-help@axis.apache.org