Hello,

Would it help you understand the problem if I said that, the last time I 
checked, the AR System webservice consumption code does not implement a 
'standardised' approach to consuming webservices? Let me expand. There are 
three ways a Java developer would normally consume a WS:

1. Generating Java source from the WSDL using Axis or CXF, and integrating the 
'stubs' with their code.
2. Using a compiled Java interface and feeding it into JAX-WS (the Java WS 
API), which is terribly clever and knows how to build SOAP messages from the 
(annotated) interface.
3. Dynamically building the SOAP message, which involves building an XML 
document using the JAX-WS API and making a SOAP call.

I prefer approach (2), because the consumer of a WS only needs to care about 
interfaces and can manipulate Java objects that are dynamically creates by 
JAX-WS. Approach (1) is a little old school, and approach (3) is for those who 
don't want to do (1) but have no interfaces (2).

The last time I checked, AR System didn't do any of the above. There's a jar 
file, websvcXX.jar, and if you look inside it with your favourite Java 
decompiler, you will see that it creates SOAP messages using an ancient version 
of Axis and some string hacking. The problem with this approach is that it's 
never going to work for all WSDLs, because it isn't following a strategy that a 
good developer would follow now-a-days. I suspect this is because it was 
written many years ago.

Webservices are tricky and there's no simple answer, but unless one follows a 
popular and accepted method, you can expect odd errors. And if the webservice 
code isn't wrapped in a scalable solution, you can expect scalability problems.

Therefore, if you can make the WSDL very simple, AR System will handle it. If 
it's complicated, you need a different approach. Sadly. most WSDLs are 
complicated.

The answer to this problem is to not use webservices and use XML over HTTP. 
Which is all a webservice really is, minus the hassle.


John Baker
-- 
SSO Plugin: Brinigng BMC products together
http://www.remedysso.com

_______________________________________________________________________________
UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
attend wwrug11 www.wwrug.com ARSList: "Where the Answers Are"

Reply via email to