re[2]: Issues running service client on AIX 5L

2008-12-11 Thread Dominic Smith
 Hi, 

 Thank you very much for sharing this information. It was very useful. It
 would be great help if you could provide a patch? 

Patch as follows (I notice in the current source the libaxis2_http_receiver 
module has already been addressed):

Index: src/core/transport/http/sender/Makefile.am
===
--- src/core/transport/http/sender/Makefile.am (revision 725683)
+++ src/core/transport/http/sender/Makefile.am (working copy)
@@ -32,6 +32,7 @@
$(top_builddir)/src/core/transport/http/util/libaxis2_http_util.la\
$(top_builddir)/axiom/src/om/libaxis2_axiom.la\
$(top_builddir)/util/src/libaxutil.la\
+ $(top_builddir)/src/core/engine/libaxis2_engine.la\
$(LIBCURL_LIBS)\
$(SSL_LIBS)
Index: axiom/src/parser/guththila/Makefile.am
===
--- axiom/src/parser/guththila/Makefile.am (revision 725683)
+++ axiom/src/parser/guththila/Makefile.am (working copy)
@@ -1,6 +1,7 @@
lib_LTLIBRARIES = libaxis2_parser.la
-libaxis2_parser_la_LIBADD = ../../../../guththila/src/libguththila.la
+libaxis2_parser_la_LIBADD = ../../../../guththila/src/libguththila.la \
+ ../../../../util/src/libaxutil.la
libaxis2_parser_la_SOURCES = ../xml_reader.c ../xml_writer.c 
guththila_xml_writer_wrapper.c \
guththila_xml_reader_wrapper.c 
Index: axiom/src/parser/libxml2/Makefile.am
===
--- axiom/src/parser/libxml2/Makefile.am (revision 725683)
+++ axiom/src/parser/libxml2/Makefile.am (working copy)
@@ -4,7 +4,8 @@
libaxis2_parser_la_SOURCES = ../xml_reader.c ../xml_writer.c \
libxml2_reader_wrapper.c libxml2_writer_wrapper.c
-libaxis2_parser_la_LIBADD = @LIBXML2_LIBS@
+libaxis2_parser_la_LIBADD = @LIBXML2_LIBS@ \
+ ../../../../util/src/libaxutil.la
libaxis2_parser_la_LDFLAGS = -version-info $(VERSION_NO)
libaxis2_libxml2_la_LDFLAGS = -version-info $(VERSION_NO)



Re: IncompatibleClassChangeError with WSDL2Java XMLBean Generated Client

2008-12-11 Thread Timothy R J Langford

Hello,

Ok. It is the morning after and things are easier with a fresh head. I 
stopped using my build file and went through the build process 
separately and the issue vanished.  I tracked down a problem in the 
build process where the target wsdl was not being downloaded 
successfully when I thought it was. So I guess the issue must have been 
a minor change in the service not being reflected in the client.


Thanks for all who took time to look at my issue.


Tim




Timothy R J Langford wrote:

Hello,

I am using axis2 wsdl2java to generate an XML Beans binding client 
from a customers WSDL schema. This mostly seems to be working fine; 
the request I am testing returns the correct response and I can 
navigate most of the returned structure using the java object model. 
However my tests revealed that invoking one of the 'getter methods' 
causes a 'java.lang.IncompatibleClassChangeError' error, whilst others 
are fine:



java.lang.IncompatibleClassChangeError: Implementing class
   at java.lang.ClassLoader.defineClass1(Native Method)
   at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
   at 
java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)

   at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
   at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
   at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
   at java.security.AccessController.doPrivileged(Native Method)
   at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
   at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
   at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268)
   at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
   at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
   at java.lang.ClassLoader.defineClass1(Native Method)
   at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
   at 
java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)

   at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
   at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
   at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
   at java.security.AccessController.doPrivileged(Native Method)
   at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
   at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
   at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268)
   at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
   at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
   at java.lang.Class.forName0(Native Method)
   at java.lang.Class.forName(Class.java:242)
   at 
org.apache.xmlbeans.impl.schema.SchemaTypeImpl.getJavaImplClass(SchemaTypeImpl.java:1709) 

   at 
org.apache.xmlbeans.impl.schema.SchemaTypeImpl.getJavaImplConstructor(SchemaTypeImpl.java:1725) 

   at 
org.apache.xmlbeans.impl.schema.SchemaTypeImpl.createUnattachedNode(SchemaTypeImpl.java:1853) 

   at 
org.apache.xmlbeans.impl.schema.SchemaTypeImpl.createElementType(SchemaTypeImpl.java:1021) 

   at 
org.apache.xmlbeans.impl.values.XmlObjectBase.create_element_user(XmlObjectBase.java:893) 


   at org.apache.xmlbeans.impl.store.Xobj.getUser(Xobj.java:1657)
   at 
org.apache.xmlbeans.impl.store.Xobj.find_element_user(Xobj.java:2062)
   at 
com.travel.core.response.impl.ResponseHeaderImpl.getTrackingInfo(Unknown 
Source)
   at 
com.travel.client.travelapp.CoreAssertions.checkTripsResponseHeader(CoreAssertions.java:83) 




So in other words; I can programatically access all of the objects in 
the following unmarshall XML except for 'getTrackingInfo()' which 
cause the exception above.



 header xsi:type=ns3:ResponseHeader xmlns=http://X; 
xmlns:ns3=http://response.core.fab.xmltravel.com;

   localisation xmlns=http://X;
 languageen/language
   /localisation
   target xmlns=http://X;TEST/target
   timingInfo xmlns=http://X;
 millisSpentIn4643/millisSpentIn
 
requestReceivedTimestamp2008-12-10T17:01:37.382Z/requestReceivedTimestamp 

 
responseSentTimestamp2008-12-10T17:01:42.025Z/responseSentTimestamp

   /timingInfo
   trackingInfo xmlns=http://X;
 requestIdyi3VWLhA_Hel9iHUYp_Db4xF/requestId
   /trackingInfo
   userInfo xsi:type=UserInfo xmlns=http://X;
 agentX/agent
 usernameX/username
   /userInfo
 /header


I have searched the forum for the exception but they don't seem 
relevant. I am new to these tools. Under what situations can a single 
element fail in such a way and how to fix it? Hoping some can help.



Thank you for your time.


Tim







--
Timothy R J Langford - MEng. (Hons)
Senior Software Engineer 
Multicom Products Ltd.


Tel: +44 (0)117 9081250



Re: following tags were not closed: soapenv:Envelope...

2008-12-11 Thread asheikh
Hello,

Could any one please give me some guidance of how to  handle this?

Thanks in advance

On Thu, Dec 11, 2008 at 9:08 AM, asheikh [EMAIL PROTECTED] wrote:

 Hi,

 I have a service that receives that from another system  and sometimes my
 service generates the following message. How can I make sure the
 response/SOAP message (Axis 1.3) from my service is not malformed...

 *Error Messsage: *

 org.apache.axiom.om.OMException: com.ctc.wstx.exc.WstxEOFException:
 Unexpected EOF; was expecting a close tag for element addressLine


 *Opening the response xml in the browser:*

 following tags were not closed: soapenv:Envelope, soapenv:Body,
 ns1:GAResponse, Data, Book, Author, addressLine. ...



Re: Axis2 Client get Premature end of file. from server

2008-12-11 Thread Tsvetelin Saykov
Hi all,

I find that the error Premature end of file. which I received from Lotus
Domino over MS Windows server is something happening in HTTP level.
To solve this problem I configure the Axis2 HTTP Transport Sender not to use
Transfer-Encoding : Chunked

stub._getServiceClient().getOptions().setProperty(org.apache.axis2.transport.http.HTTPConstants.CHUNKED,
Boolean.FALSE);

Hope this could be useful for someone else

Best regards
Tsvetelin


On Wed, Dec 10, 2008 at 2:23 PM, Tsvetelin Saykov [EMAIL PROTECTED]wrote:

 Hi,

 I am new in Axis2 web services application development and I am experience
 a problem with Axis2

 I am writing a Client application and I get Premature end of file. from
 server.
 The client application is running under Linux/Java6.
 The web services server is IBM Lotus Domino under MS Windows

 I am using WSDL2Java tool to generate stub. I tried both mappings ADB and
 JiBX
 When I take the request xml (from debug log colored in red) and post it to
 the server via post request using URLConnection I was able to receive server
 reply.
 When I downloaded the latest release of Axis1, this problem disappear and I
 was able to receive server reply(using again WSDL2Java tool).

 It seems that Axis2 send request which cannot be parsed by server
 Does someone experience the same problem? Any idea why this happen and what
 can I do to fix this issue

 Thank you in advance
 Tsvetelin

 PS. Here is the debug log

 REQUEST
 [DEBUG] ==
 [DEBUG] HttpConnectionManager.getConnection:  config =
 HostConfiguration[host=https://host.com], timeout = 0
 [DEBUG] Allocating new connection, hostConfig=HostConfiguration[host=
 https://host.com]
 [DEBUG] Open connection to host.com:443
 [DEBUG]  POST //partyInterface?OpenWebService HTTP/1.1[\r][\n]
 [DEBUG] Adding Host request header
 [DEBUG]  Content-Type: text/xml; charset=UTF-8[\r][\n]
 [DEBUG]  SOAPAction: [\r][\n]
 [DEBUG]  User-Agent: Axis2[\r][\n]
 [DEBUG]  Host: host.com[\r][\n]
 [DEBUG]  Transfer-Encoding: chunked[\r][\n]
 [DEBUG]  [\r][\n]
 [DEBUG] start writeTo()
 [DEBUG]   preserve=false
 [DEBUG]   isOptimized=false
 [DEBUG]   isDoingSWA=false
 [DEBUG] MTOM optimized Threshold value =0
 [DEBUG] Created XMLOutputFactory = class
 com.ctc.wstx.stax.WstxOutputFactory for
 [EMAIL PROTECTED]
 [DEBUG] Size of XMLOutputFactory map =1
 [DEBUG] XMLStreamWriter is com.ctc.wstx.sw.SimpleNsStreamWriter
 [DEBUG] end writeTo()
 [DEBUG]  ca[\r][\n]
 [DEBUG]  ?xml version='1.0' encoding='UTF-8'?soapenv:Envelope
 xmlns:soapenv=http://schemas.xmlsoap.org/soap/envelope/;soapenv:BodyCHECKWS
 xmlns=urn:DefaultNamespace //soapenv:Body/soapenv:Envelope
 [DEBUG]  [\r][\n]
 [DEBUG]  0
 [DEBUG]  [\r][\n]
 [DEBUG]  [\r][\n]
 [DEBUG] Request body sent
 [DEBUG]  HTTP/1.1 200 OK[\r][\n]
 [DEBUG]  HTTP/1.1 200 OK[\r][\n]
 [DEBUG]  Server: Lotus-Domino[\r][\n]
 [DEBUG]  Date: Wed, 10 Dec 2008 11:44:57 GMT[\r][\n]
 [DEBUG]  Content-Type: text/xml; charset=utf-8[\r][\n]
 [DEBUG]  Content-Length: 459[\r][\n]
 [DEBUG]  [\r][\n]
 [DEBUG] ==
 [DEBUG]  Property set on object
 [EMAIL PROTECTED]
 [DEBUG]   Key =TRANSPORT_HEADERS
 [DEBUG]   Value Class =
 org.apache.axis2.transport.http.CommonsTransportHeaders
 [DEBUG]   Value Classloader = [EMAIL PROTECTED]
 [DEBUG] Call Stack = DEBUG_FRAME =
 org.apache.axis2.util.JavaUtils.callStackToString(JavaUtils.java:564)
 DEBUG_FRAME =
 org.apache.axis2.context.AbstractContext.debugPropertySet(AbstractContext.java:416)
 DEBUG_FRAME =
 org.apache.axis2.context.AbstractContext.setProperty(AbstractContext.java:182)
 DEBUG_FRAME =
 org.apache.axis2.transport.http.AbstractHTTPSender.obtainHTTPHeaderInformation(AbstractHTTPSender.java:120)
 DEBUG_FRAME =
 org.apache.axis2.transport.http.AbstractHTTPSender.processResponse(AbstractHTTPSender.java:210)
 DEBUG_FRAME =
 org.apache.axis2.transport.http.HTTPSender.handleResponse(HTTPSender.java:265)
 DEBUG_FRAME =
 org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:190)
 DEBUG_FRAME =
 org.apache.axis2.transport.http.HTTPSender.send(HTTPSender.java:75)
 DEBUG_FRAME =
 org.apache.axis2.transport.http.CommonsHTTPTransportSender.writeMessageWithCommons(CommonsHTTPTransportSender.java:371)
 DEBUG_FRAME =
 org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:209)
 DEBUG_FRAME =
 org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:448)
 DEBUG_FRAME =
 org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:401)
 DEBUG_FRAME =
 org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:228)
 DEBUG_FRAME =
 org.apache.axis2.client.OperationClient.execute(OperationClient.java:163)
 DEBUG_FRAME =
 com.rushmore.advancedevents.gmp.ws.jibx.PartyInterfaceServiceStub.CHECKWS(PartyInterfaceServiceStub.java:309)
 DEBUG_FRAME =
 

access files inside AAR - File Path! not Resource / URL

2008-12-11 Thread Seem

I have an unsolved problem accessing a file which is inside my aar-folder.
Unfortunately I need a file Path for a 3rd Party function and not a Resource
or an URL. Do you have any advices how to get the right path to the file?

My folder structure is like this

/META-INF
/bin (Service classes)
/conf/config.xml



-- 
View this message in context: 
http://www.nabble.com/access-files-inside-AAR---File-Path%21-not-Resource---URL-tp20958031p20958031.html
Sent from the Axis - User mailing list archive at Nabble.com.



Re: access files inside AAR - File Path! not Resource / URL

2008-12-11 Thread Deepal Jayasinghe
Have a look at following article, which provides a way to access your
resources inside the service archive file.

http://wso2.org/library/259

Deepal
 I have an unsolved problem accessing a file which is inside my aar-folder.
 Unfortunately I need a file Path for a 3rd Party function and not a Resource
 or an URL. Do you have any advices how to get the right path to the file?

 My folder structure is like this

 /META-INF
 /bin (Service classes)
 /conf/config.xml



   

-- 
Thank you!


http://blogs.deepal.org



Re: access files inside AAR - File Path! not Resource / URL

2008-12-11 Thread Seem

Yes, I tried this, but there is still the problem, that I need a file Path
and not a resource/URL to invoke File file = new File(file Path) for further
operations.

and this was not a solution to get the correct Path:
getClass().getClassLoader().getResource(conf/config.xml).getPath();


if(!file.exists()) {...system.out

brought me this:
cannot find file
file:/C:/Programme/Tomcat/work/Catalina/localhost/axis2/_axis2/axis230466Service.aar!/conf/config.xml





Deepal Jayasinghe wrote:
 
 Have a look at following article, which provides a way to access your
 resources inside the service archive file.
 
 http://wso2.org/library/259
 
 Deepal
 I have an unsolved problem accessing a file which is inside my
 aar-folder.
 Unfortunately I need a file Path for a 3rd Party function and not a
 Resource
 or an URL. Do you have any advices how to get the right path to the file?

 My folder structure is like this

 /META-INF
 /bin (Service classes)
 /conf/config.xml



   
 
 -- 
 Thank you!
 
 
 http://blogs.deepal.org
 
 
 

-- 
View this message in context: 
http://www.nabble.com/access-files-inside-AAR---File-Path%21-not-Resource---URL-tp20958031p20958833.html
Sent from the Axis - User mailing list archive at Nabble.com.



Re: access files inside AAR - File Path! not Resource / URL

2008-12-11 Thread Deepal Jayasinghe

 Yes, I tried this, but there is still the problem, that I need a file Path
 and not a resource/URL to invoke File file = new File(file Path) for further
 operations.

 and this was not a solution to get the correct Path:
 getClass().getClassLoader().getResource(conf/config.xml).getPath();


 if(!file.exists()) {...system.out
   
I do not think you can do something like this,
What you can do is get the input stream and read it and do your job.

If you get not-null value for getResource(), then that is mean you can
access your resource.

Thank you!
Deepal
 brought me this:
 cannot find file
 file:/C:/Programme/Tomcat/work/Catalina/localhost/axis2/_axis2/axis230466Service.aar!/conf/config.xml





 Deepal Jayasinghe wrote:
   
 Have a look at following article, which provides a way to access your
 resources inside the service archive file.

 http://wso2.org/library/259

 Deepal
 
 I have an unsolved problem accessing a file which is inside my
 aar-folder.
 Unfortunately I need a file Path for a 3rd Party function and not a
 Resource
 or an URL. Do you have any advices how to get the right path to the file?

 My folder structure is like this

 /META-INF
 /bin (Service classes)
 /conf/config.xml



   
   
 -- 
 Thank you!


 http://blogs.deepal.org



 

   

-- 
Thank you!


http://blogs.deepal.org



Re: Problem with a simple Object[] in RPCServiceClient

2008-12-11 Thread Rodrigo Asensio
Finally It was solved. how ?

the ws was done in coldfusion 7 who uses axis1 and there are some
problems with doc-literal and soap encoding. Server side changed the
wsdl and now I can retrieve arrays[] with the same code. Thanks for
helping.
R


Rodrigo Asensio
[EMAIL PROTECTED]
http://www.rodrigoasensio.com
To err is human, but to really screw up requires the root password.



On Wed, Dec 10, 2008 at 2:55 PM, Rodrigo Asensio [EMAIL PROTECTED] wrote:
 Here is the code. Also I'm trying to generate the clients with adb or
 xmlbeans and I'm getting
 [ERROR] Part 'fault' of fault message
 '{http://icu_test.dev}CFCInvocationException' must be defined with
 'element=QName' and not 'type=QName'

 this is a coldfusion axis1 ws. I found that according to the
 specification, fault and header message parts must be defined as
 document/literal, even if the body is defined as RPC style.


 Struct_cards
 --

 public class struct_cards {
protected java.lang.String card_delegate;
protected java.lang.String card_expire_date;
protected java.lang.String card_id;
protected java.lang.String card_lfd;
protected java.lang.String card_name;
protected java.lang.String card_type;
protected java.lang.String usrfld1;

public struct_cards() {}

public struct_cards(String card_delegate, String card_expire_date,
 String card_id, String card_lfd, String card_name,
String card_type, String usrfld1) {
this.card_delegate = card_delegate;
this.card_expire_date = card_expire_date;
this.card_id = card_id;
this.card_lfd = card_lfd;
this.card_name = card_name;
this.card_type = card_type;
this.usrfld1 = usrfld1;
}

public String getCard_delegate() {
return card_delegate;
}

public void setCard_delegate(String card_delegate) {
this.card_delegate = card_delegate;
}

public String getCard_expire_date() {
return card_expire_date;
}

public void setCard_expire_date(String card_expire_date) {
this.card_expire_date = card_expire_date;
}

public String getCard_id() {
return card_id;
}

public void setCard_id(String card_id) {
this.card_id = card_id;
}

public String getCard_lfd() {
return card_lfd;
}

public void setCard_lfd(String card_lfd) {
this.card_lfd = card_lfd;
}

public String getCard_name() {
return card_name;
}

public void setCard_name(String card_name) {
this.card_name = card_name;
}

public String getCard_type() {
return card_type;
}

public void setCard_type(String card_type) {
this.card_type = card_type;
}

public String getUsrfld1() {
return usrfld1;
}

public void setUsrfld1(String usrfld1) {
this.usrfld1 = usrfld1;
}
 }


 invoke method
 --

public Object[] invoke() throws Exception {
Object[] params = new Object() {someid};

RPCServiceClient serviceClient = new RPCServiceClient();
Options options = serviceClient.getOptions();
EndpointReference targetEPR = new EndpointReference(URL);
options.setTo(targetEPR);
options.setTimeOutInMilliSeconds(TIMEOUT);

QName actionQ = new QName(NAMESPACE, get_cards);
 //  Class[] returnTypes = new Class[] { returnTypeClass };

ArrayList resobj = new ArrayList();
resobj.add(struct_cards[].class);
Class[] ax = (Class[])resobj.toArray(new Class[resobj.size()]);
// Class[] returnTypes = new Class[]{struct_cards.class};
Object[] results = serviceClient.invokeBlocking(actionQ, 
 params, ax);
return results;
}





 Rodrigo Asensio
 [EMAIL PROTECTED]
 http://www.rodrigoasensio.com
 To err is human, but to really screw up requires the root password.



 On Wed, Dec 10, 2008 at 2:47 PM, Deepal Jayasinghe [EMAIL PROTECTED] wrote:
 Can you please send me your service code, then I will give you the exact
 solution.

 Deepal

 Rodrigo Asensio wrote:
 the most accurate test for my case should be the testCompanyArray()
 where it converts doing something like this

 ArrayList resobj = new ArrayList();
 resobj.add(Struct_cards[].class);
 (Class[])resobj.toArray(new Class[resobj.size()])

 but the result is the same...  below I'm posting the wsdl and extra
 info that might help (me  :))

 results   Object[1]  (id=83)
   [0] Struct_cards  (id=84)
   card_delegate   null
 

Re: access files inside AAR - File Path! not Resource / URL

2008-12-11 Thread Seem

Just to clarify, I have a similar problem like this:
http://www.nabble.com/Accessing-a-file-in-AAR-to16787898.html#a16898376

but I do not understand his mentioned solution.

Should I use the getResourceAsStream(), create a temporary file from the
inputstream, get the file path und use it with my 3rd party methods?





Deepal Jayasinghe wrote:
 
 
 Yes, I tried this, but there is still the problem, that I need a file
 Path
 and not a resource/URL to invoke File file = new File(file Path) for
 further
 operations.

 and this was not a solution to get the correct Path:
 getClass().getClassLoader().getResource(conf/config.xml).getPath();


 if(!file.exists()) {...system.out
   
 I do not think you can do something like this,
 What you can do is get the input stream and read it and do your job.
 
 If you get not-null value for getResource(), then that is mean you can
 access your resource.
 
 Thank you!
 Deepal
 brought me this:
 cannot find file
 file:/C:/Programme/Tomcat/work/Catalina/localhost/axis2/_axis2/axis230466Service.aar!/conf/config.xml





 Deepal Jayasinghe wrote:
   
 Have a look at following article, which provides a way to access your
 resources inside the service archive file.

 http://wso2.org/library/259

 Deepal
 
 I have an unsolved problem accessing a file which is inside my
 aar-folder.
 Unfortunately I need a file Path for a 3rd Party function and not a
 Resource
 or an URL. Do you have any advices how to get the right path to the
 file?

 My folder structure is like this

 /META-INF
 /bin (Service classes)
 /conf/config.xml



   
   
 -- 
 Thank you!


 http://blogs.deepal.org



 

   
 
 -- 
 Thank you!
 
 
 http://blogs.deepal.org
 
 
 

-- 
View this message in context: 
http://www.nabble.com/access-files-inside-AAR---File-Path%21-not-Resource---URL-tp20958031p20959233.html
Sent from the Axis - User mailing list archive at Nabble.com.



Re: Problem with a simple Object[] in RPCServiceClient

2008-12-11 Thread Deepal Jayasinghe
Oh, good. I though you were using Axis2 at the server side too .
 Finally It was solved. how ?

 the ws was done in coldfusion 7 who uses axis1 and there are some
 problems with doc-literal and soap encoding. Server side changed the
 wsdl and now I can retrieve arrays[] with the same code. Thanks for
 helping.
 R


 Rodrigo Asensio
 [EMAIL PROTECTED]
 http://www.rodrigoasensio.com
 To err is human, but to really screw up requires the root password.



 On Wed, Dec 10, 2008 at 2:55 PM, Rodrigo Asensio [EMAIL PROTECTED] wrote:
   
 Here is the code. Also I'm trying to generate the clients with adb or
 xmlbeans and I'm getting
 [ERROR] Part 'fault' of fault message
 '{http://icu_test.dev}CFCInvocationException' must be defined with
 'element=QName' and not 'type=QName'

 this is a coldfusion axis1 ws. I found that according to the
 specification, fault and header message parts must be defined as
 document/literal, even if the body is defined as RPC style.


 Struct_cards
 --

 public class struct_cards {
protected java.lang.String card_delegate;
protected java.lang.String card_expire_date;
protected java.lang.String card_id;
protected java.lang.String card_lfd;
protected java.lang.String card_name;
protected java.lang.String card_type;
protected java.lang.String usrfld1;

public struct_cards() {}

public struct_cards(String card_delegate, String card_expire_date,
 String card_id, String card_lfd, String card_name,
String card_type, String usrfld1) {
this.card_delegate = card_delegate;
this.card_expire_date = card_expire_date;
this.card_id = card_id;
this.card_lfd = card_lfd;
this.card_name = card_name;
this.card_type = card_type;
this.usrfld1 = usrfld1;
}

public String getCard_delegate() {
return card_delegate;
}

public void setCard_delegate(String card_delegate) {
this.card_delegate = card_delegate;
}

public String getCard_expire_date() {
return card_expire_date;
}

public void setCard_expire_date(String card_expire_date) {
this.card_expire_date = card_expire_date;
}

public String getCard_id() {
return card_id;
}

public void setCard_id(String card_id) {
this.card_id = card_id;
}

public String getCard_lfd() {
return card_lfd;
}

public void setCard_lfd(String card_lfd) {
this.card_lfd = card_lfd;
}

public String getCard_name() {
return card_name;
}

public void setCard_name(String card_name) {
this.card_name = card_name;
}

public String getCard_type() {
return card_type;
}

public void setCard_type(String card_type) {
this.card_type = card_type;
}

public String getUsrfld1() {
return usrfld1;
}

public void setUsrfld1(String usrfld1) {
this.usrfld1 = usrfld1;
}
 }


 invoke method
 --

public Object[] invoke() throws Exception {
Object[] params = new Object() {someid};

RPCServiceClient serviceClient = new RPCServiceClient();
Options options = serviceClient.getOptions();
EndpointReference targetEPR = new EndpointReference(URL);
options.setTo(targetEPR);
options.setTimeOutInMilliSeconds(TIMEOUT);

QName actionQ = new QName(NAMESPACE, get_cards);
 //  Class[] returnTypes = new Class[] { returnTypeClass };

ArrayList resobj = new ArrayList();
resobj.add(struct_cards[].class);
Class[] ax = (Class[])resobj.toArray(new 
 Class[resobj.size()]);
// Class[] returnTypes = new Class[]{struct_cards.class};
Object[] results = serviceClient.invokeBlocking(actionQ, 
 params, ax);
return results;
}





 Rodrigo Asensio
 [EMAIL PROTECTED]
 http://www.rodrigoasensio.com
 To err is human, but to really screw up requires the root password.



 On Wed, Dec 10, 2008 at 2:47 PM, Deepal Jayasinghe [EMAIL PROTECTED] wrote:
 
 Can you please send me your service code, then I will give you the exact
 solution.

 Deepal

 Rodrigo Asensio wrote:
   
 the most accurate test for my case should be the testCompanyArray()
 where it converts doing something like this

 ArrayList resobj = new ArrayList();
 resobj.add(Struct_cards[].class);
 (Class[])resobj.toArray(new Class[resobj.size()])

 but the result is the same...  below I'm posting the wsdl and extra
 info that might help (me  :))

 results   

Re: Problem with a simple Object[] in RPCServiceClient

2008-12-11 Thread Rodrigo Asensio
nop, I said

this is a coldfusion axis1 ws. I found that according to the
specification, fault and header message parts must be defined as
document/literal, even if the body is defined as RPC style.

regards and thanks


Rodrigo Asensio
[EMAIL PROTECTED]
http://www.rodrigoasensio.com
To err is human, but to really screw up requires the root password.



On Wed, Dec 10, 2008 at 2:55 PM, Rodrigo Asensio [EMAIL PROTECTED] wrote:
 Here is the code. Also I'm trying to generate the clients with adb or
 xmlbeans and I'm getting
 [ERROR] Part 'fault' of fault message
 '{http://icu_test.dev}CFCInvocationException' must be defined with
 'element=QName' and not 'type=QName'

 this is a coldfusion axis1 ws. I found that according to the
 specification, fault and header message parts must be defined as
 document/literal, even if the body is defined as RPC style.


 Struct_cards
 --

 public class struct_cards {
protected java.lang.String card_delegate;
protected java.lang.String card_expire_date;
protected java.lang.String card_id;
protected java.lang.String card_lfd;
protected java.lang.String card_name;
protected java.lang.String card_type;
protected java.lang.String usrfld1;

public struct_cards() {}

public struct_cards(String card_delegate, String card_expire_date,
 String card_id, String card_lfd, String card_name,
String card_type, String usrfld1) {
this.card_delegate = card_delegate;
this.card_expire_date = card_expire_date;
this.card_id = card_id;
this.card_lfd = card_lfd;
this.card_name = card_name;
this.card_type = card_type;
this.usrfld1 = usrfld1;
}

public String getCard_delegate() {
return card_delegate;
}

public void setCard_delegate(String card_delegate) {
this.card_delegate = card_delegate;
}

public String getCard_expire_date() {
return card_expire_date;
}

public void setCard_expire_date(String card_expire_date) {
this.card_expire_date = card_expire_date;
}

public String getCard_id() {
return card_id;
}

public void setCard_id(String card_id) {
this.card_id = card_id;
}

public String getCard_lfd() {
return card_lfd;
}

public void setCard_lfd(String card_lfd) {
this.card_lfd = card_lfd;
}

public String getCard_name() {
return card_name;
}

public void setCard_name(String card_name) {
this.card_name = card_name;
}

public String getCard_type() {
return card_type;
}

public void setCard_type(String card_type) {
this.card_type = card_type;
}

public String getUsrfld1() {
return usrfld1;
}

public void setUsrfld1(String usrfld1) {
this.usrfld1 = usrfld1;
}
 }


 invoke method
 --

public Object[] invoke() throws Exception {
Object[] params = new Object() {someid};

RPCServiceClient serviceClient = new RPCServiceClient();
Options options = serviceClient.getOptions();
EndpointReference targetEPR = new EndpointReference(URL);
options.setTo(targetEPR);
options.setTimeOutInMilliSeconds(TIMEOUT);

QName actionQ = new QName(NAMESPACE, get_cards);
 //  Class[] returnTypes = new Class[] { returnTypeClass };

ArrayList resobj = new ArrayList();
resobj.add(struct_cards[].class);
Class[] ax = (Class[])resobj.toArray(new Class[resobj.size()]);
// Class[] returnTypes = new Class[]{struct_cards.class};
Object[] results = serviceClient.invokeBlocking(actionQ, 
 params, ax);
return results;
}





 Rodrigo Asensio
 [EMAIL PROTECTED]
 http://www.rodrigoasensio.com
 To err is human, but to really screw up requires the root password.



 On Wed, Dec 10, 2008 at 2:47 PM, Deepal Jayasinghe [EMAIL PROTECTED] wrote:
 Can you please send me your service code, then I will give you the exact
 solution.

 Deepal

 Rodrigo Asensio wrote:
 the most accurate test for my case should be the testCompanyArray()
 where it converts doing something like this

 ArrayList resobj = new ArrayList();
 resobj.add(Struct_cards[].class);
 (Class[])resobj.toArray(new Class[resobj.size()])

 but the result is the same...  below I'm posting the wsdl and extra
 info that might help (me  :))

 results   Object[1]  (id=83)
   [0] Struct_cards  (id=84)
   card_delegate   null
   card_expire_date   

axis2 - creating a customer exception

2008-12-11 Thread SPARAGA
I have created a custom exception and it is being throw by the web 
service. The exception has two fields and getter and setter methods for 
those fields. Those fields are being set by the service before it throws 
the customer exception.  On the client side, the only exception I am able 
to catch is  AxisFault exception. In that class, I cannot seem to find the 
custom exception I threw, or the fields I set on the custom exception. 

Background: 
I am creating the web service from POJO's and a services.xml file. The 
WSDL is auto generated when I deploy the web service to axis2 inside of 
Tomcat.  Therefore, I have no control over the content of the WSDL. 
I am also using Axis2 to create the client. I am using the wsdl2java 
utility the auto generates the Stub class from the WSDL.  I have googled 
this issue and by all accounts it seems that catching an AxisFault 
exception is what the client should do if using Axis2 to autogenerate the 
stubs from the WSDL. But how do i access the custom exception I threw and 
access the fields I set on the custom exception?   

Infinite Loop

2008-12-11 Thread Pathuri, Hanu

Hi,

We have a web service (say A) deployed in Tomcat/Axis-2 environment. It nee= ds 
to access another web service (B) for which we have java api based jaxws=  
framework.
The developers of B publishes a java jar file for clients to use the B web = 
service. This API makes use of JAXWS API.


When A is deployed on Tomcat using eclipse, A can access B with out any iss= 
ues.


However, When A calls B we seem to getting into infinte loop.

Can some one guide us how to troubleshoot or offer advice on what to look f= or?

Best Regards
Hanu
-Original Message-
From: Rodrigo Asensio [mailto:[EMAIL PROTECTED] 
Sent: Thursday, December 11, 2008 8:46 AM
To: axis-user@ws.apache.org
Subject: Re: Problem with a simple Object[] in RPCServiceClient

nop, I said

this is a coldfusion axis1 ws. I found that according to the
specification, fault and header message parts must be defined as
document/literal, even if the body is defined as RPC style.

regards and thanks


Rodrigo Asensio
[EMAIL PROTECTED]
http://www.rodrigoasensio.com
To err is human, but to really screw up requires the root password.



On Wed, Dec 10, 2008 at 2:55 PM, Rodrigo Asensio [EMAIL PROTECTED] wrote:
 Here is the code. Also I'm trying to generate the clients with adb or
 xmlbeans and I'm getting
 [ERROR] Part 'fault' of fault message
 '{http://icu_test.dev}CFCInvocationException' must be defined with
 'element=QName' and not 'type=QName'

 this is a coldfusion axis1 ws. I found that according to the
 specification, fault and header message parts must be defined as
 document/literal, even if the body is defined as RPC style.


 Struct_cards
 --

 public class struct_cards {
protected java.lang.String card_delegate;
protected java.lang.String card_expire_date;
protected java.lang.String card_id;
protected java.lang.String card_lfd;
protected java.lang.String card_name;
protected java.lang.String card_type;
protected java.lang.String usrfld1;

public struct_cards() {}

public struct_cards(String card_delegate, String card_expire_date,
 String card_id, String card_lfd, String card_name,
String card_type, String usrfld1) {
this.card_delegate = card_delegate;
this.card_expire_date = card_expire_date;
this.card_id = card_id;
this.card_lfd = card_lfd;
this.card_name = card_name;
this.card_type = card_type;
this.usrfld1 = usrfld1;
}

public String getCard_delegate() {
return card_delegate;
}

public void setCard_delegate(String card_delegate) {
this.card_delegate = card_delegate;
}

public String getCard_expire_date() {
return card_expire_date;
}

public void setCard_expire_date(String card_expire_date) {
this.card_expire_date = card_expire_date;
}

public String getCard_id() {
return card_id;
}

public void setCard_id(String card_id) {
this.card_id = card_id;
}

public String getCard_lfd() {
return card_lfd;
}

public void setCard_lfd(String card_lfd) {
this.card_lfd = card_lfd;
}

public String getCard_name() {
return card_name;
}

public void setCard_name(String card_name) {
this.card_name = card_name;
}

public String getCard_type() {
return card_type;
}

public void setCard_type(String card_type) {
this.card_type = card_type;
}

public String getUsrfld1() {
return usrfld1;
}

public void setUsrfld1(String usrfld1) {
this.usrfld1 = usrfld1;
}
 }


 invoke method
 --

public Object[] invoke() throws Exception {
Object[] params = new Object() {someid};

RPCServiceClient serviceClient = new RPCServiceClient();
Options options = serviceClient.getOptions();
EndpointReference targetEPR = new EndpointReference(URL);
options.setTo(targetEPR);
options.setTimeOutInMilliSeconds(TIMEOUT);

QName actionQ = new QName(NAMESPACE, get_cards);
 //  Class[] returnTypes = new Class[] { returnTypeClass };

ArrayList resobj = new ArrayList();
resobj.add(struct_cards[].class);
Class[] ax = (Class[])resobj.toArray(new Class[resobj.size()]);
// Class[] returnTypes = new Class[]{struct_cards.class};
Object[] results = serviceClient.invokeBlocking(actionQ, 
 params, ax);
return results;
}





 Rodrigo Asensio
 [EMAIL PROTECTED]
 

compatibility issues

2008-12-11 Thread Rodrigo Asensio
I'm axis2 and I'm generating ws for other consumers, some of them are
ms crappy biztalk. They are getting some conflicts if they find in the
wsdl something like this:

xs:element maxOccurs=unbounded minOccurs=0 name=persons
nillable=true type=ax21:Person/

the minOccurs=0 and the nillable=true

is there any way to intersect the wget of the wsdl ?? or should I
change it manually and point to a custom file ?? any property to set
in the java2wsdl ant task ???

regards
R


Rodrigo Asensio
rasen...@gmail.com
http://www.rodrigoasensio.com
To err is human, but to really screw up requires the root password.


Response a Custom XSD

2008-12-11 Thread Rodrigo Asensio
Axis2 141
we are developing a ws based on our customer spec. He gave me a XSD
and the response XML (inner the soap msg) should be in a specific way.
I made it 100% using AXIOM OMElements because I didnt found a way to
do the XS:ATTRIBUTES as is shown below.


xs:element name=BigObject
xs:complexType
xs:sequence
xs:element ref=SmallObject1/
xs:element ref=SmallObject2 minOccurs=0/
xs:element ref=SmallObject3 minOccurs=0 
maxOccurs=unbounded/
xs:element ref=SmallObject4 minOccurs=0 
maxOccurs=unbounded/
/xs:sequence
xs:attribute name=Version type=xs:string 
use=optional default=3.3/
xs:attribute name=UnitsOfMeasure 
type=UnitsOfMeasure
use=optional default=metric/
xs:attribute name=TrainingModeFlag type=xs:boolean
use=optional default=false/
/xs:complexType
/xs:element


If I deploy a WS returning objects, how can I do that some attributes
of the BigObject are shown like xs:attribute and not in the
xs:sequence, is this possible or they are crazy asking me this ? is
this standard ???


Rodrigo Asensio
rasen...@gmail.com
http://www.rodrigoasensio.com
To err is human, but to really screw up requires the root password.


Re: Response a Custom XSD

2008-12-11 Thread Rodrigo Asensio
I'm seeing the wikipedia article (
http://en.wikipedia.org/wiki/Web_Services_Description_Language#Example_WSDL_file
) and I saw something like I want, that means is not that crazy, now
my question is , how can I represent in the XML the attributes of an
object
having this obj for example

class Request {
  private Header header;   would be the complex type
  private String method;  is represented as an xs:attribute.. HOW
can I make this 
}


 xs:element name=request
xs:complexType
   xs:sequence
  xs:element name=header maxOccurs=unbounded
 xs:complexType
xs:simpleContent
   xs:extension base=xs:string
  xs:attribute name=name
type=xs:string use=required/
   /xs:extension
/xs:simpleContent
 /xs:complexType
  /xs:element
  xs:element name=body type=xs:anyType minOccurs=0/
   /xs:sequence
   xs:attribute name=method type=xs:string use=required/
   xs:attribute name=uri type=xs:anyURI use=required/
/xs:complexType
 /xs:element





Rodrigo Asensio
rasen...@gmail.com
http://www.rodrigoasensio.com
To err is human, but to really screw up requires the root password.



On Thu, Dec 11, 2008 at 3:35 PM, Rodrigo Asensio rasen...@gmail.com wrote:
 Axis2 141
 we are developing a ws based on our customer spec. He gave me a XSD
 and the response XML (inner the soap msg) should be in a specific way.
 I made it 100% using AXIOM OMElements because I didnt found a way to
 do the XS:ATTRIBUTES as is shown below.


xs:element name=BigObject
xs:complexType
xs:sequence
xs:element ref=SmallObject1/
xs:element ref=SmallObject2 minOccurs=0/
xs:element ref=SmallObject3 minOccurs=0 
 maxOccurs=unbounded/
xs:element ref=SmallObject4 minOccurs=0 
 maxOccurs=unbounded/
/xs:sequence
xs:attribute name=Version type=xs:string 
 use=optional default=3.3/
xs:attribute name=UnitsOfMeasure 
 type=UnitsOfMeasure
 use=optional default=metric/
xs:attribute name=TrainingModeFlag type=xs:boolean
 use=optional default=false/
/xs:complexType
/xs:element


 If I deploy a WS returning objects, how can I do that some attributes
 of the BigObject are shown like xs:attribute and not in the
 xs:sequence, is this possible or they are crazy asking me this ? is
 this standard ???


 Rodrigo Asensio
 rasen...@gmail.com
 http://www.rodrigoasensio.com
 To err is human, but to really screw up requires the root password.



Re: [Axis2] Custom Soap Header

2008-12-11 Thread Prasuna Lanka
I tried in the suggested way, but still the object contains null values.
when i looked into the parse method of that class, i found the statement
reader.getAttributeValue(*null*,entityID); returning null. The entity
id is of Stirng type.
xmlstgreamreader docs say, If the namespaceURI is null the namespace is not
checked for equality. what does it mean?

Regards
Ps

On Thu, Dec 11, 2008 at 12:54 AM, Amila Suriarachchi 
amilasuriarach...@gmail.com wrote:



  On Thu, Dec 11, 2008 at 3:51 AM, Prasuna Lanka 
 prasuna.la...@gmail.comwrote:

 Amila

 Thanks much for the response. I tried BeanUtil.deserialize method(with 4
 parameters: classname, OMelem, defaultobjsupplier, null)  to get an instance
 of the custom header, the object is returned but all with null member
 values..I have the xml string in hand, but why am i not able to get the
 complete object? am i wrong in the method call?  am using ADB..


 if you use generated ADB classes you can call the Factory.parse method
 giving the xml stream reader which can be obtain from the OMElement.

 thanks,
 Amila.


 Regards
 Ps.



 On Tue, Dec 9, 2008 at 10:57 PM, Amila Suriarachchi 
 amilasuriarach...@gmail.com wrote:



  On Wed, Dec 10, 2008 at 3:36 AM, Prasuna Lanka prasuna.la...@gmail.com
  wrote:

 Hello,

 Using Axis2-1.3. , I generated server side stuff from a 3rd party wsdl
 which contains definitions for custom SOAP Header. That is comprised of 
 more
 than 3 User defined types. But in the generated source, i couldnt find any
 way to receive or send that custom SOAP header object except the
 request ojbject coming in which is in SOAP Body. I read some where to use
 wsdl2java -exsh true, to get the support for SOAP headers,  but when i 
 tried
 on command prompt, it shows only help options. Other than OM methods, is
 there any way that i can read/ the header object from the incoming request?


 there is no direct method for this. you can get the Soap Envelop at your
 skelton method. Please see here[1].

 from the soap envelop you can get the headers.

 thanks,
 Amila.

 [1] http://wso2.org/library/2935
 [2]
 http://amilachinthaka.blogspot.com/2008/11/accessing-axis2-information-at-client.html


 Thanks in advance.
 Prasoona.






 --
 Amila Suriarachchi
 WSO2 Inc.
 blog: http://amilachinthaka.blogspot.com/





 --
 Amila Suriarachchi
 WSO2 Inc.
 blog: http://amilachinthaka.blogspot.com/



[AXIS2 v1.4] Logging module not logging message reply receipt

2008-12-11 Thread searl
Hi,

I have a modified version of the Logging module MAR for logging the xml
of sent and received messages in my services. The service side
is logging the messages without problems. The client side
is logging the outbound request but not the inbound replay.

I have two services, A and B. A is acting as a client
to B. A sends a request to B and B returns a replay.
The A outbound request is logged by the logging MAR OK.
The B inbound request is logged OK.
The B outbound response is logged OK.
The A inbound response is never logged.

Messaging is synchronous. Transport is HTTP.

I would assume that since the B service logs for both
inbound and outbound that the phases setup in the axis.xml
file is correct.

Can anyone tell me if this is known/expected behavior? or
what to look at.

I would be happy to supply code and config files if that would help.

Thanks!

leon

-- 
Leon S. Searl, Software Research Engineer
Information and Telecommunication Technology Center, University of Kansas
Nichols Hall, 2335 Irving Hill Road, Lawrence, KS 66045-7612
Ph: 785-864-7820 Fax: 785-864-0387
http://www.ittc.ku.edu


Re: [AXIS2 v1.4] Logging module not logging message reply receipt

2008-12-11 Thread Deepal Jayasinghe

 Hi,

 I have a modified version of the Logging module MAR for logging the xml
 of sent and received messages in my services. The service side
 is logging the messages without problems. The client side
 is logging the outbound request but not the inbound replay.
   
Did you engage the logging module to both the client side and the server
side ?

As I can see you have client server communication, so you need to engage
the same module for both the side.

Thank you!
Deepal
 I have two services, A and B. A is acting as a client
 to B. A sends a request to B and B returns a replay.
 The A outbound request is logged by the logging MAR OK.
 The B inbound request is logged OK.
 The B outbound response is logged OK.
 The A inbound response is never logged.

 Messaging is synchronous. Transport is HTTP.

 I would assume that since the B service logs for both
 inbound and outbound that the phases setup in the axis.xml
 file is correct.

 Can anyone tell me if this is known/expected behavior? or
 what to look at.

 I would be happy to supply code and config files if that would help.

 Thanks!

 leon

   

-- 
Thank you!


http://blogs.deepal.org



Re: [AXIS2 v1.4] Logging module not logging message reply receipt

2008-12-11 Thread searl
Hi Deepal,

Yes, I believe that the module is engaged for both services.
Particularly since I'm seeing the message logged for the outbound
request from the client side. I'm just not seeing the message logged
for the inbound reply on the client side.

leon

On Thu, 11 Dec 2008 15:37:23 -0500, Deepal Jayasinghe
dee...@opensource.lk wrote:
 Hi,

 I have a modified version of the Logging module MAR for logging the xml
 of sent and received messages in my services. The service side
 is logging the messages without problems. The client side
 is logging the outbound request but not the inbound replay.
   
 Did you engage the logging module to both the client side and the server
 side ?
 
 As I can see you have client server communication, so you need to engage
 the same module for both the side.
 
 Thank you!
 Deepal
 I have two services, A and B. A is acting as a client
 to B. A sends a request to B and B returns a replay.
 The A outbound request is logged by the logging MAR OK.
 The B inbound request is logged OK.
 The B outbound response is logged OK.
 The A inbound response is never logged.

 Messaging is synchronous. Transport is HTTP.

 I would assume that since the B service logs for both
 inbound and outbound that the phases setup in the axis.xml
 file is correct.

 Can anyone tell me if this is known/expected behavior? or
 what to look at.

 I would be happy to supply code and config files if that would help.

 Thanks!

 leon

   
 

-- 
Leon S. Searl, Software Research Engineer
Information and Telecommunication Technology Center, University of Kansas
Nichols Hall, 2335 Irving Hill Road, Lawrence, KS 66045-7612
Ph: 785-864-7820 Fax: 785-864-0387
http://www.ittc.ku.edu


Re: [AXIS2 v1.4] Logging module not logging message reply receipt

2008-12-11 Thread searl
On Thu, 11 Dec 2008 15:04:57 -0600, searl se...@ittc.ku.edu wrote:
 Hi Deepal,
 
 Yes, I believe that the module is engaged for both services.
 Particularly since I'm seeing the message logged for the outbound
 request from the client side. I'm just not seeing the message logged
 for the inbound reply on the client side.
 
 leon
 
 On Thu, 11 Dec 2008 15:37:23 -0500, Deepal Jayasinghe
 dee...@opensource.lk wrote:
 Hi,

 I have a modified version of the Logging module MAR for logging the xml
 of sent and received messages in my services. The service side
 is logging the messages without problems. The client side
 is logging the outbound request but not the inbound replay.
   
 Did you engage the logging module to both the client side and the server
 side ?
 
 As I can see you have client server communication, so you need to engage
 the same module for both the side.
 
 Thank you!
 Deepal
 I have two services, A and B. A is acting as a client
 to B. A sends a request to B and B returns a replay.
 The A outbound request is logged by the logging MAR OK.
 The B inbound request is logged OK.
 The B outbound response is logged OK.
 The A inbound response is never logged.

 Messaging is synchronous. Transport is HTTP.

 I would assume that since the B service logs for both
 inbound and outbound that the phases setup in the axis.xml
 file is correct.

 Can anyone tell me if this is known/expected behavior? or
 what to look at.

 I would be happy to supply code and config files if that would help.

 Thanks!

 leon

   
 


-- 
Leon S. Searl, Software Research Engineer
Information and Telecommunication Technology Center, University of Kansas
Nichols Hall, 2335 Irving Hill Road, Lawrence, KS 66045-7612
Ph: 785-864-7820 Fax: 785-864-0387
http://www.ittc.ku.edu


Re: [AXIS2 v1.4] Logging module not logging message reply receipt

2008-12-11 Thread Deepal Jayasinghe
Hmm, I think I can not give an exact answer without looking at the code,
so if you can please create a JIRA[1] and attach all the stuff need to
regenerate the issue.

[1] : http://issues.apache.org/jira

Thank you!
Deepal
 Hi Deepal,

 Yes, I believe that the module is engaged for both services.
 Particularly since I'm seeing the message logged for the outbound
 request from the client side. I'm just not seeing the message logged
 for the inbound reply on the client side.

 leon

 On Thu, 11 Dec 2008 15:37:23 -0500, Deepal Jayasinghe
 dee...@opensource.lk wrote:
   
 Hi,

 I have a modified version of the Logging module MAR for logging the xml
 of sent and received messages in my services. The service side
 is logging the messages without problems. The client side
 is logging the outbound request but not the inbound replay.
   
   
 Did you engage the logging module to both the client side and the server
 side ?

 As I can see you have client server communication, so you need to engage
 the same module for both the side.

 Thank you!
 Deepal
 
 I have two services, A and B. A is acting as a client
 to B. A sends a request to B and B returns a replay.
 The A outbound request is logged by the logging MAR OK.
 The B inbound request is logged OK.
 The B outbound response is logged OK.
 The A inbound response is never logged.

 Messaging is synchronous. Transport is HTTP.

 I would assume that since the B service logs for both
 inbound and outbound that the phases setup in the axis.xml
 file is correct.

 Can anyone tell me if this is known/expected behavior? or
 what to look at.

 I would be happy to supply code and config files if that would help.

 Thanks!

 leon

   
   
 

-- 
Thank you!


http://blogs.deepal.org



Re: [AXIS2 v1.4] Logging module not logging message reply receipt

2008-12-11 Thread searl
Hi Deepal,

I will create the JIRA.

Since I'm seeing the logging on the service side for both
inbound request and outbound response BUT
on the client side seeing the log for ONLY outbound request,
I'm thinking that the InFlow phases must not be getting handled
the same for clients and services.

leon

On Thu, 11 Dec 2008 16:11:13 -0500, Deepal Jayasinghe
dee...@opensource.lk wrote:
 Hmm, I think I can not give an exact answer without looking at the code,
 so if you can please create a JIRA[1] and attach all the stuff need to
 regenerate the issue.
 
 [1] : http://issues.apache.org/jira
 
 Thank you!
 Deepal
 Hi Deepal,

 Yes, I believe that the module is engaged for both services.
 Particularly since I'm seeing the message logged for the outbound
 request from the client side. I'm just not seeing the message logged
 for the inbound reply on the client side.

 leon

 On Thu, 11 Dec 2008 15:37:23 -0500, Deepal Jayasinghe
 dee...@opensource.lk wrote:
   
 Hi,

 I have a modified version of the Logging module MAR for logging the
xml
 of sent and received messages in my services. The service side
 is logging the messages without problems. The client side
 is logging the outbound request but not the inbound replay.
   
   
 Did you engage the logging module to both the client side and the
server
 side ?

 As I can see you have client server communication, so you need to
engage
 the same module for both the side.

 Thank you!
 Deepal
 
 I have two services, A and B. A is acting as a client
 to B. A sends a request to B and B returns a replay.
 The A outbound request is logged by the logging MAR OK.
 The B inbound request is logged OK.
 The B outbound response is logged OK.
 The A inbound response is never logged.

 Messaging is synchronous. Transport is HTTP.

 I would assume that since the B service logs for both
 inbound and outbound that the phases setup in the axis.xml
 file is correct.

 Can anyone tell me if this is known/expected behavior? or
 what to look at.

 I would be happy to supply code and config files if that would help.

 Thanks!

 leon

   
   
 
 

-- 
Leon S. Searl, Software Research Engineer
Information and Telecommunication Technology Center, University of Kansas
Nichols Hall, 2335 Irving Hill Road, Lawrence, KS 66045-7612
Ph: 785-864-7820 Fax: 785-864-0387
http://www.ittc.ku.edu


RE: [Axis2] excludeOperations in services.xml problem

2008-12-11 Thread Raghu Upadhyayula
Hi,

 

I have a webservices (written in Java) with several operations.  I want
to exclude couple of operations from that.  I've used the
excludeOperations tag in services.xml as shown below.  I'm using Axis2
1.4.

 

excludeOperations

operationcopy/operation

operationmove/operation

/excludeOperations

 

After restarting the app server when I see view the WSDL in the browser,
I still see these 2 operations  also I was able to access those
operations from the Java client.

 

Thanks

Raghu



Re: Accessing a file in AAR

2008-12-11 Thread Seem

I have the same problem.
Do I understand you right, that you pointed out a solution in this kind of
manner:

Should I use the getResourceAsStream() to get the file, create a temporary
file from the inputstream, get the file path und use it with my 3rd party
methods?




sowmi wrote:
 
 Since I did not hear anything, I had to get around the issue by creating
 the file in the java.io.tmpdir  pass the file path to 3rd party
 classes. Just in case somebody needs to know what I did.
 

-- 
View this message in context: 
http://www.nabble.com/Accessing-a-file-in-AAR-tp16787898p20964762.html
Sent from the Axis - User mailing list archive at Nabble.com.



Re: Accessing a file in AAR

2008-12-11 Thread Deepal jayasinghe
Seem wrote:
 I have the same problem.
 Do I understand you right, that you pointed out a solution in this kind of
 manner:

 Should I use the getResourceAsStream() to get the file, create a temporary
 file from the inputstream, get the file path und use it with my 3rd party
 methods?
   
Once you call getResourceAsStream , what you get is an input stream, and
I am not sure whether it creates a temporally file for that. But one
thing I can not understand is why do you want to access the file, if you
have the input stream you can do whatever you want with that.

Deepal 



 sowmi wrote:
   
 Since I did not hear anything, I had to get around the issue by creating
 the file in the java.io.tmpdir  pass the file path to 3rd party
 classes. Just in case somebody needs to know what I did.

 

   


-- 
Thank you!


http://blogs.deepal.org



Re: [Axis2] excludeOperations in services.xml problem

2008-12-11 Thread Deepal Jayasinghe

 Hi,

  

 I have a webservices (written in Java) with several operations.  I
 want to exclude couple of operations from that.  I’ve used the
 excludeOperations tag in services.xml as shown below.  I’m using
 Axis2 1.4.

  

 excludeOperations

 operationcopy/operation

 operationmove/operation

 /excludeOperations

  

 After restarting the app server when I see view the WSDL in the
 browser, I still see these 2 operations  also I was able to access
 those operations from the Java client.

Excluding operation mean, you do not display them in the WSDL but you
can invoke them. Anyway please create a JIRA and attach your service. I
will have a look at.

Deepal

  

 Thanks

 Raghu


-- 
Thank you!


http://blogs.deepal.org



Re: Accessing the in flow message context in out flow handler

2008-12-11 Thread Dave Meibusch
Thank you, Deepal.
This got me on the right track.

 
 actually I forgot, seems like I have even written an article about that
 
 http://wso2.org/library/2084
 




Re: [Axis2] excludeOperations in services.xml problem

2008-12-11 Thread Nadir Amra
hmmm, an excluded operation cannot be invoked, as far as I know from Axis 
1.3.   I will verify. 

Nadir Amra


Deepal Jayasinghe dee...@opensource.lk wrote on 12/11/2008 04:20:43 PM:

 [image removed] 
 
 Re: [Axis2] excludeOperations in services.xml problem
 
 Deepal Jayasinghe 
 
 to:
 
 axis-user
 
 12/11/2008 04:21 PM
 
 Please respond to axis-user
 
 
  Hi,
 
  
 
  I have a webservices (written in Java) with several operations.  I
  want to exclude couple of operations from that.  I?ve used the
  excludeOperations tag in services.xml as shown below.  I?m using
  Axis2 1.4.
 
  
 
  excludeOperations
 
  operationcopy/operation
 
  operationmove/operation
 
  /excludeOperations
 
  
 
  After restarting the app server when I see view the WSDL in the
  browser, I still see these 2 operations  also I was able to access
  those operations from the Java client.
 
 Excluding operation mean, you do not display them in the WSDL but you
 can invoke them. Anyway please create a JIRA and attach your service. I
 will have a look at.
 
 Deepal
 
  
 
  Thanks
 
  Raghu
 
 
 -- 
 Thank you!
 
 
 http://blogs.deepal.org
 



Axis2 client - counting bytes sent and received

2008-12-11 Thread Dave Meibusch
Hi,
I'm attempting to log statistics for my system, including the bytes
sent/received for the components using Axis2 client code.

Digging through the source of HttpClient, HttpMethod (latter is accessible from
Axis2 MessageContext) has not been successful. The Content-Length HTTP header is
not reliable (in particular with Chunking enabled).

I'm not that hopeful, but perhaps someone has been down a similar path before 
me?

thanks,
Dave



Re: [Axis2] excludeOperations in services.xml problem

2008-12-11 Thread Deepal jayasinghe

 hmmm, an excluded operation cannot be invoked, as far as I know from Axis 
 1.3.   I will verify. 
   
Nope exclude operations will only exclude from WSDL, if that is not the
case then something has broken.

Deepal
 Nadir Amra


 Deepal Jayasinghe dee...@opensource.lk wrote on 12/11/2008 04:20:43 PM:

   
 [image removed] 

 Re: [Axis2] excludeOperations in services.xml problem

 Deepal Jayasinghe 

 to:

 axis-user

 12/11/2008 04:21 PM

 Please respond to axis-user


 
 Hi,



 I have a webservices (written in Java) with several operations.  I
 want to exclude couple of operations from that.  I?ve used the
 excludeOperations tag in services.xml as shown below.  I?m using
 Axis2 1.4.



 excludeOperations

 operationcopy/operation

 operationmove/operation

 /excludeOperations



 After restarting the app server when I see view the WSDL in the
 browser, I still see these 2 operations  also I was able to access
 those operations from the Java client.

   
 Excluding operation mean, you do not display them in the WSDL but you
 can invoke them. Anyway please create a JIRA and attach your service. I
 will have a look at.

 Deepal
 

 Thanks

 Raghu

   
 -- 
 Thank you!


 http://blogs.deepal.org

 


   


-- 
Thank you!


http://blogs.deepal.org



Re: [Axis2] Custom Soap Header

2008-12-11 Thread Amila Suriarachchi
On Fri, Dec 12, 2008 at 1:41 AM, Prasuna Lanka prasuna.la...@gmail.comwrote:

 I tried in the suggested way, but still the object contains null values.
 when i looked into the parse method of that class, i found the statement
 reader.getAttributeValue(*null*,entityID); returning null. The entity
 id is of Stirng type.
 xmlstgreamreader docs say, If the namespaceURI is null the namespace is not
 checked for equality. what does it mean?


this means it gets the attribute by checking only the local name.

Can you  send your xml string?

This article[1] shows how serialize an parts xml strings with ADB code. Try
to parse your sting as given here.

thanks,
Amila

[1] http://wso2.org/library/2068


 Regards
 Ps

 On Thu, Dec 11, 2008 at 12:54 AM, Amila Suriarachchi 
 amilasuriarach...@gmail.com wrote:



  On Thu, Dec 11, 2008 at 3:51 AM, Prasuna Lanka 
 prasuna.la...@gmail.comwrote:

 Amila

 Thanks much for the response. I tried BeanUtil.deserialize method(with 4
 parameters: classname, OMelem, defaultobjsupplier, null)  to get an instance
 of the custom header, the object is returned but all with null member
 values..I have the xml string in hand, but why am i not able to get the
 complete object? am i wrong in the method call?  am using ADB..


 if you use generated ADB classes you can call the Factory.parse method
 giving the xml stream reader which can be obtain from the OMElement.

 thanks,
 Amila.


 Regards
 Ps.



 On Tue, Dec 9, 2008 at 10:57 PM, Amila Suriarachchi 
 amilasuriarach...@gmail.com wrote:



  On Wed, Dec 10, 2008 at 3:36 AM, Prasuna Lanka 
 prasuna.la...@gmail.com wrote:

 Hello,

 Using Axis2-1.3. , I generated server side stuff from a 3rd party wsdl
 which contains definitions for custom SOAP Header. That is comprised of 
 more
 than 3 User defined types. But in the generated source, i couldnt find any
 way to receive or send that custom SOAP header object except the
 request ojbject coming in which is in SOAP Body. I read some where to use
 wsdl2java -exsh true, to get the support for SOAP headers,  but when i 
 tried
 on command prompt, it shows only help options. Other than OM methods, is
 there any way that i can read/ the header object from the incoming 
 request?


 there is no direct method for this. you can get the Soap Envelop at your
 skelton method. Please see here[1].

 from the soap envelop you can get the headers.

 thanks,
 Amila.

 [1] http://wso2.org/library/2935
 [2]
 http://amilachinthaka.blogspot.com/2008/11/accessing-axis2-information-at-client.html


 Thanks in advance.
 Prasoona.






 --
 Amila Suriarachchi
 WSO2 Inc.
 blog: http://amilachinthaka.blogspot.com/





 --
 Amila Suriarachchi
 WSO2 Inc.
 blog: http://amilachinthaka.blogspot.com/





-- 
Amila Suriarachchi
WSO2 Inc.
blog: http://amilachinthaka.blogspot.com/