Axis throws always RemoteException

2007-08-06 Thread Daniel . Kuschow
I have a webservice running under Axis 1.4. One Operation can throw an 
exception created by my own (MyOwnException):

operation ... 
fault name=MyOwnException ...

But if server side throws this exception (can see this exception is 
bundled fine into one soap fault), not a MyOwnException is thrown.
Instead of this a RemoteException (AxisFault) is thrown, which has 
MyOwnException as faultDetail field. But i dont want to parse
this field with a XMLParser. But at the moment i had to :((

Can anyone help me with this ? Its making me crazy ...

thx

Daniel Kuschow

Problem with Values

2007-04-05 Thread Daniel . Kuschow
I have the problem by Axis2, to differentiate between:
a) Client has called request.setLogin()
-- sends login /
b) Client DID NOT call request.setLogin()
-- sends login xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; 
xsi:nil=true /

In both cases Axis2 give me null for request.getLogin(). Why i get no 
empty String in case a) ???
Please help me with that problem, i had to differentiate between both 
cases. Without
this Axis2 is senseless for me, or i had to hack Axis2 sourcecode :((

With best regards,

Daniel Kuschow

[Axis2] War file from nightly build

2007-03-28 Thread Daniel . Kuschow
Is the generated axis2.war file not intend to work as standalone 
application in an application container ?
In current state it cannot be used, because many libraries are missing. If 
i am wrong, i would be grateful, if
someone could say me, which libraries are mandatory in axis2.war, without 
having to refer to an outstanding
axis2 folder.

thanks for answers,

Daniel Kuschow

Antwort: Re: Help Read in Properties File

2007-03-14 Thread Daniel . Kuschow
If you want to read in a file in your classpath (without exactly knowing 
where to find) you have to do following:

your.package.YourClass.class.getResourceAsStream(/yourconfig.cfg)

Note: The SLASH before configuration file name is important. Without it, 
java won't search for this file into your classpath.
It will then only look if this file is in the same folder, where your 
class lies:

YourClass.class.getResourceAsStream(yourconfig.cfg)
--Config had to lie here /your/package/yourconfig.cfg

wbr,

Daniel Kuschow

[Axis2] Still a problem with optional parameters

2007-02-23 Thread Daniel . Kuschow
Hello,

i have problems using Axis2 (1.1.1 and Snapshot from 23.Feb) and i hope 
someone can help me.

If in client code request.setAmount(0) will be called, this value will be 
set to 0. But if client do not set
this value (in xml request -- nil=true):
- server get an initialized Integer with a 0 value (I cannot find out if 
client called this setter with 0 or not set this value : )

This is regarding to this JIRA-Entry 
(http://issues.apache.org/jira/browse/AXIS2-1272). But the workaround to 
set MIN_VALUE
is not really what i want. Is it possible to return null for nil, and 
initialized Integer otherwise ?

With Strings it is the same thing. But there was a change from 1.1.1 
Release to SNAPSHOT (mentioned above). If client set
a string to an empty string ( request.setRequestString() ):
- server receives an empty string (Axis2 1.1.1)
- server receives null (SNAPSHOT)

If my client do not call this mehtod:
- server receives an empty string (Axis2 1.1.1)
- server recieves null (SNAPSHOT)  HOORAY

My hope was, that:
- request.setRequestString() returns an empty initialized string
- if nothing is called server receives null

Please help me with that, it's really annoying, that there is no 
possibility to check if a setter was called or not.
Fixes in SNAPSHOT-Version do not solve my problem with optional parameters 
:(

wtr,

Daniel Kuschow

Fyi:
- Apache Tomcat 5.5.20 running under Java 1.5
- Used Axis2 1.1.1 and SNAPSHOT (23.02.2007)
- Using ADB at client side
- At server side i create MyOwn.war (with axis2 jar files included)
- service is POJO-Based (Java2WSDL)

[Axis2] Problems with optional parameters

2007-02-21 Thread Daniel . Kuschow
Hello,

i hope someone can help me, with my problem. I am using Axis2 1.1.1 with 
Java6. My current Problem:
I use Java2WSDL and in one of my POJO's i have a field with datatype 
Integer:
private Integer amount;
If i create an .aar file with and let me generate one wsdl file for that 
class, not xs:integer will be used. Only the native datatype int (xs:int) 
is defined in WSDL.
So my client i create out of this WSDL has only the possibility to set 
amount as int value. But how can if find out - at server side - if in 
client code someone called:
object.setAmount(0);
or do not call this setter ? In both cases i got 0 at server side. I 
cannot check if amount was explicitly set by client, or can i ?
Same problem i have with Strings. If someone called:
object.setSomeString();
or do not call this setter, i alway got one empty initialized String at 
server side :(

Now my main questions:
1) Is there a possibility to have in WSDL for Integer -- xs:integer, so 
that in client code will be used Integer instead of int ?
2) Is it possible, that if someone do not call a setter at client side i 
get null at server side for this object ?

with best regards,

Daniel Kuschow

[Axis2] Problem with endpoint in wsdl

2007-01-04 Thread Daniel . Kuschow
Moin moin,

can someone help me by following problem:

I have two Linux systems. On the first one is an apache-1.3x 
installed as proxy to forward some requests to another computer with a 
webservice installed.
My Webservice is a Java2WSDL implementation and runs under Tomcat 
5.0.2.8 with Axis2-1.1. First i have tried to use my Webservice.aar on 
only one computer (client/Server)
without a proxy - all fine. But if i use configuration described 
above, my endpoint (soap:address and soap12:address) have wrong URLs. 

Request from Client will try to connect to endpoint 
http://127.0.0.1/part/Webservice; but it should be 
http://anotherurl/anotherpart/Webservice;. Is it possible to change this 
URL
in generated WSDL ? And if it is possible can you explain how ?

I also tried to copy one generated WSDL file into META-INF folder 
of my Webservice.aar file. Than i set parameter name=useOriginalwsdl
true/parameter in service.xml.
But when i look at WSDL by entering page 
http://anotherurl/anotherpart/Webservice?wsdl;, i receive:
soap12:address 
location=http://anotherurl/anotherpart/Webservice/
but
soap:address location=http://127.0.0.1/par/Webservice/

Although in generated WSDL by my own are following lines:
soap12:address 
location=http://anotherurl/anotherpart/Webservice/ 
soap:address 
location=http://anotherurl/anotherpart/Webservice/

My dream would be, when it is possible to set - perhaps in 
Axis2Context - one locationURI that will be used instead of other url's 
for all parts in generated WSDL. Or is it already possible ?

Thanks for reading and with best regards,

Daniel Kuschow

Antwort: Re: [Axis2] Problem with endpoint in wsdl

2007-01-04 Thread Daniel . Kuschow
I am a little bit confused about log a bug for the ip address in 
soap:address. Can you explain in detail what you mean exactly.
Is it possible in Version 1.1.1 to set endpoint url for generation of WSDL 
(at runtime)?

wbr,

Daniel Kuschow

Problem with Endpoint

2007-01-03 Thread Daniel . Kuschow
I have following Problem. My Webservice is running on Machine A by using 
generated wsdl file. But the problem is the endpoint url.
Because of security matters clients should not access webservice directly. 
Clients have to call another machine B (proxy) to use this webservice.
And that is my problem. I had to override the endpoint url in generated 
wsdl. But i have not found a way how to do this !?
Also i do not want, that EPR had to be changed in client code, because URL 
in wsdl is wrong.

Or is the problem that endpoint is set to 127.0.0.1 if client has called 
it over proxy (https://machineA/part/webservice?wsdl)

Yours sincerely,

Daniel Kuschow