Return-Path: Delivered-To: apmail-ws-axis-c-user-archive@www.apache.org Received: (qmail 12575 invoked from network); 6 Oct 2005 01:55:51 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 6 Oct 2005 01:55:51 -0000 Received: (qmail 80566 invoked by uid 500); 6 Oct 2005 01:55:51 -0000 Delivered-To: apmail-ws-axis-c-user-archive@ws.apache.org Received: (qmail 80378 invoked by uid 500); 6 Oct 2005 01:55:50 -0000 Mailing-List: contact axis-c-user-help@ws.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: List-Id: "Apache AXIS C User List" Reply-To: "Apache AXIS C User List" Delivered-To: mailing list axis-c-user@ws.apache.org Received: (qmail 80367 invoked by uid 99); 6 Oct 2005 01:55:50 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 05 Oct 2005 18:55:50 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=RCVD_BY_IP,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: domain of samisa.abeysinghe@gmail.com designates 64.233.184.207 as permitted sender) Received: from [64.233.184.207] (HELO wproxy.gmail.com) (64.233.184.207) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 05 Oct 2005 18:55:54 -0700 Received: by wproxy.gmail.com with SMTP id 69so124956wra for ; Wed, 05 Oct 2005 18:55:29 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:user-agent:x-accept-language:mime-version:to:subject:references:in-reply-to:content-type:content-transfer-encoding; b=qRviHkraHhGRuWPlCY9wClEpzCvZrJVaoXY9Qs3xnRQVR9MMXCu/FbH3wOLGdVjRWfnmdwwcrzu8L0r9aHE1ir7jLK8/FWklQAU1ucc2AKhZs0+8pTlm6oLfzVz7YmItFSO8vx+oOZFcaDUtlMeCvHpNRR23vTQEkIqr2baBBn4= Received: by 10.54.93.15 with SMTP id q15mr762563wrb; Wed, 05 Oct 2005 18:55:29 -0700 (PDT) Received: from ?192.168.1.151? ( [220.247.241.201]) by mx.gmail.com with ESMTP id d8sm641716wra.2005.10.05.18.55.26; Wed, 05 Oct 2005 18:55:27 -0700 (PDT) Message-ID: <434483ED.3000900@gmail.com> Date: Thu, 06 Oct 2005 07:54:53 +0600 From: Samisa Abeysinghe User-Agent: Mozilla Thunderbird 1.0.6-1.1.fc4 (X11/20050720) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Apache AXIS C User List Subject: Re: Safe threading - Client side References: <002901c5c9e4$a1be58e0$390308a4@gandalf> In-Reply-To: <002901c5c9e4$a1be58e0$390308a4@gandalf> Content-Type: text/plain; charset=ISO-8859-2; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N We have some tests with threads in the test forlder, some of which were passing. (I did not run the test framework lately, could someone please mention what threded tests are passing/running) Please have a look at tests with the name suffix 'TTest' (run `ls tests/auto_build/testcases/client/cpp/*TTest*` in source extract folder) This will give you an idea on how to use clients in threads. Thanks, Samisa... Tomaz Rotovnik wrote: > > Hello > > I'm looking for some information's about running multiple calls in > client side of axis. I'm using axis version 1.5. The problem is that > when I call function again before it returns (in different thread) > it returns exception when calling invoke method. > > In main loop there is call to create new object > > pBLP = new Soap(s.strURL.c_str(), APTHTTP1_1); > > and this instance is used each time when function > "setConfirmTransaction" is called for example > > pCT = pBLP->ConfirmTransaction(sTr.szAuthReference); > > This calling part is implemented in callback function, which can be > called many times (before we get receive from the server it can be > called again (multiple threads)). > > I hope someone could give me some possible solution. > > Thanks in advance > > Tomaz > > > > Here is example of "setConfirmTransaction" function > > ################################################################## > setConfirmTransaction* Soap::ConfirmTransaction(xsd__string Value0) > { > setConfirmTransaction* pReturn = NULL; > const char* pcCmplxFaultName; > pcCmplxFaultName = NULL; > try{ > > if (AXIS_SUCCESS != m_pCall->initialize(CPP_DOC_PROVIDER)) return > pReturn; > m_pCall->setTransportProperty(SOAPACTION_HEADER , > "http://tempuri.org/ConfirmTransaction"); > m_pCall->setSOAPVersion(SOAP_VER_1_1); > m_pCall->setOperation("ConfirmTransaction", > "http://tempuri.org/WebService"); > includeSecure(); > applyUserPreferences(); > m_pCall->addParameter((void*)Value0, "lTransactionID", XSD_STRING); > > if (AXIS_SUCCESS == m_pCall->invoke()) > { > if(AXIS_SUCCESS == > m_pCall->checkMessage("ConfirmTransactionResponse", > "http://tempuri.org/WebService")) > { > pReturn = > (setConfirmTransaction*)m_pCall->getCmplxObject((void*) > Axis_DeSerialize_setConfirmTransaction, > (void*) Axis_Create_setConfirmTransaction, (void*) > Axis_Delete_setConfirmTransaction,"ConfirmTransactionResult", 0); > } > } > m_pCall->unInitialize(); > return pReturn; > } > catch(AxisException& e) > {...... > ###############################################################################