Java clients calling Delphi soap services

<div id="jive-html-wrapper-div">
<br />
<DIV><FONT size="2" face="Arial">We have major problems using java clients with <br />
Delphi servers. Problems with wsdls, problems with validating services etc. We <br />
can solve a lot of issues by modifiying the wsdl by hand, but are we unique in <br />
this or are there more problems out there. We are running D2007.</FONT></DIV>
<DIV><FONT size="2" face="Arial"></FONT>&nbsp;</DIV>
<DIV><FONT size="2" face="Arial">albert</FONT></DIV>
</div>
0
Albert
4/26/2010 9:48:45 AM
embarcadero.delphi.webservices 976 articles. 0 followers. Follow

6 Replies
1229 Views

Similar Articles

[PageSpeed] 14

Am 26.04.2010 11:48, Albert Drent wrote:
>
> We have major problems using java clients with
> Delphi servers. Problems with wsdls, problems with validating services etc. We
> can solve a lot of issues by modifiying the wsdl by hand, but are we unique in
> this or are there more problems out there. We are running D2007.
> albert

Which Soap framework for Java are you using on the client side (Axis, 
CXF, Metro, JAX-WS, ...)? Maybe you can post an example (WSDL, Java and 
Delphi Soap request)?

Regards,
-- 
Michael Justin
SCJP, SCJA
betasoft - Software for Delphi™ and for the Java™ platform
http://www.mikejustin.com - http://www.betabeans.de
0
Michael
4/26/2010 4:27:55 PM
Hi Albert,

> We have major problems using java clients with
> Delphi servers. Problems with wsdls, problems with validating services 
> etc. We can solve a lot of issues by modifiying the wsdl by hand, but 
> are we unique in this or are there more problems out there. 

I also have similar problems in several projects connecting to Java 
(Axis) servers - using Delphi 2007 and 2010. Manual modifications of 
SOAP requests (and sometimes responses) is the only way we could solve 
it... Not a lot of fun, but AFAICS the only option...

> albert

Groetjes,
           Bob Swart

-- 
Bob Swart Training & Consultancy (eBob42.com) Forever Loyal to Delphi
Chairman Delphi Development Network (DDN) powered by SDN - www.sdn.nl
Embarcadero Technology Partner - Delphi & RAD Studio Reseller BeNeLux
http://twitter.com/eBob42 LinkedIn: http://nl.linkedin.com/in/drbob42
Delphi Win32 & .NET books on Lulu.com: http://stores.lulu.com/drbob42
Personal courseware + e-mail support http://www.ebob42.com/courseware
Blog: http://www.drbob42.com/blog - RSS: http://eBob42.com/weblog.xml
0
Bob
4/27/2010 7:02:00 AM
Am 27.04.2010 09:02, Bob Swart wrote:

> I also have similar problems in several projects connecting to Java
> (Axis) servers

Ok, but here it seems to be Java Client -> Delphi Server.

Maybe it is an option to create the WSDL in a Java toolkit (Eclipse and 
NetBeans offer support for WSDL design) and use this WSDL then to build 
the Delphi server? - The result should be more compatible with the Java 
side this way.

Cheers,
-- 
Michael Justin
SCJP, SCJA
betasoft - Software for Delphi™ and for the Java™ platform
http://www.mikejustin.com - http://www.betabeans.de
0
Michael
4/27/2010 7:13:28 AM
Hi Michael,

> Ok, but here it seems to be Java Client -> Delphi Server.

Ah, I stand corrected. I must admit I'm seldom found in that situation. 
When we need to make Delphi clients for web services, we're often "left 
by ourselves" to solve any interoperability issues, and I've never been 
contacted about interoperability issues between a Delphi server and Java 
or .NET clients (well, apart from the soRootRefNodesToBody option for 
..NET clients, but we figured that one out by ourselves ;-)).

> Maybe it is an option to create the WSDL in a Java toolkit (Eclipse and 
> NetBeans offer support for WSDL design) and use this WSDL then to build 
> the Delphi server? - The result should be more compatible with the Java 
> side this way.

Hmm, could be. I'm not sure if the resulting WSDL would be 100% 
compatible, and if .NET clients would like it, but it surely is an idea 
to pursuit!

> Cheers,

Groetjes,
           Bob Swart

-- 
Bob Swart Training & Consultancy (eBob42.com) Forever Loyal to Delphi
Chairman Delphi Development Network (DDN) powered by SDN - www.sdn.nl
Embarcadero Technology Partner - Delphi & RAD Studio Reseller BeNeLux
http://twitter.com/eBob42 LinkedIn: http://nl.linkedin.com/in/drbob42
Delphi Win32 & .NET books on Lulu.com: http://stores.lulu.com/drbob42
Personal courseware + e-mail support http://www.ebob42.com/courseware
Blog: http://www.drbob42.com/blog - RSS: http://eBob42.com/weblog.xml
0
Bob
4/27/2010 7:18:16 AM
We are using the JAX-RPC import. I've attached the wsdl. In 2001 we created 
an applicationserver in Delphi which is used to impement a webapplication 
for self-service on our salary system. People can buy/sell hollidays for 
money etc. After they have chosen something a salary specification is shown 
to specifiy the consequences of their choice.

Now in the soa-age the university likes to have the functions available as a 
webservice. Since all is there in the application server I modified it to 
reply to ordinary http(s) requests and soap envelopes. The latter is 
transfered to the pascalinvoker and the anser is given as xml, the regular 
messages are treated as the standard http request and reply with an html 
message. It works well, but unfortunately there are some difficult wsdl/soap 
issues.

As middleware Oracle fusion is used which is java (with bpel engine). But we 
also use .Net. The power of services is that it can be used by all kind of 
clients? Well unfortunately it's not that simple.

With Java the reported error is generated.
With .Net we get:

albert




  <?xml version="1.0" encoding="utf-8" ?>
- <definitions xmlns="http://schemas.xmlsoap.org/wsdl/" 
xmlns:xs="http://www.w3.org/2001/XMLSchema" name="IPerSalSoaservice" 
targetNamespace="http://tempuri.org/" xmlns:tns="http://tempuri.org/" 
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" 
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" 
xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" 
xmlns:ns1="urn:PerSalIntf">
- <types>
- <xs:schema targetNamespace="urn:PerSalIntf" xmlns="urn:PerSalIntf">
- <xs:complexType name="TSalarisSlip">
- <xs:sequence>
  <xs:element name="SalDetailRegels" type="ns1:TSalDetailRegels" />
  </xs:sequence>
  </xs:complexType>
- <xs:complexType name="TSalDetailRegels">
- <xs:complexContent>
- <xs:restriction base="soapenc:Array">
  <xs:sequence />
  <xs:attribute ref="soapenc:arrayType" n1:arrayType="xs:string[]" 
xmlns:n1="http://schemas.xmlsoap.org/wsdl/" />
  </xs:restriction>
  </xs:complexContent>
  </xs:complexType>
- <xs:complexType name="TAuthorisation">
- <xs:sequence>
  <xs:element name="context" type="xs:string" />
  <xs:element name="contextId" type="xs:string" />
  <xs:element name="contextPsw" type="xs:string" />
  <xs:element name="RegNr" type="xs:string" />
  <xs:element name="IArNr" type="xs:string" />
  <xs:element name="RegPwd" type="xs:string" />
  </xs:sequence>
  </xs:complexType>
- <xs:complexType name="EPerSoaFault">
- <xs:sequence>
  <xs:element name="Reason" type="xs:string" />
  <xs:element name="FaultActor" type="xs:string" />
  <xs:element name="FaultCode" type="xs:string" />
  <xs:element name="FaultDetail" type="xs:string" />
  </xs:sequence>
  </xs:complexType>
  </xs:schema>
  </types>
- <message name="SalarisSlip0Request">
  <part name="Jaar" type="xs:int" />
  <part name="Maand" type="xs:int" />
  </message>
- <message name="SalarisSlip0Response">
  <part name="return" type="ns1:TSalarisSlip" />
  </message>
- <message name="SalarisSlip0headerRequest">
  <part name="TAuthorisation" type="ns1:TAuthorisation" />
  </message>
- <message name="SalarisSlip0headerResponse">
  <part name="TAuthorisation" type="ns1:TAuthorisation" />
  </message>
- <message name="SalarisSlip0fault0">
  <part name="EPerSoaFault" type="ns1:EPerSoaFault" />
  </message>
- <message name="LaatsteVerwerkingsDatum1Request">
  <part name="dummy" type="xs:string" />
  </message>
- <message name="LaatsteVerwerkingsDatum1Response">
  <part name="return" type="xs:date" />
  </message>
- <message name="LaatsteVerwerkingsDatum1headerRequest">
  <part name="TAuthorisation" type="ns1:TAuthorisation" />
  </message>
- <message name="LaatsteVerwerkingsDatum1headerResponse">
  <part name="TAuthorisation" type="ns1:TAuthorisation" />
  </message>
- <message name="LaatsteVerwerkingsDatum1fault0">
  <part name="EPerSoaFault" type="ns1:EPerSoaFault" />
  </message>
- <portType name="IPerSalSoa">
- <operation name="SalarisSlip">
  <input message="tns:SalarisSlip0Request" />
  <output message="tns:SalarisSlip0Response" />
  <fault name="EPerSoaFault" message="tns:SalarisSlip0fault0" />
  </operation>
- <operation name="LaatsteVerwerkingsDatum">
  <input message="tns:LaatsteVerwerkingsDatum1Request" />
  <output message="tns:LaatsteVerwerkingsDatum1Response" />
  <fault name="EPerSoaFault" message="tns:LaatsteVerwerkingsDatum1fault0" />
  </operation>
  </portType>
- <binding name="IPerSalSoabinding" type="tns:IPerSalSoa">
  <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http" 
/>
- <operation name="SalarisSlip">
  <soap:operation soapAction="urn:PerSalIntf-IPerSalSoa#SalarisSlip" 
style="rpc" />
- <input>
  <soap:body use="encoded" 
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" 
namespace="urn:PerSalIntf-IPerSalSoa" />
  <soap:header use="encoded" message="tns:SalarisSlip0headerRequest" 
part="TAuthorisation" 
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" 
namespace="urn:PerSalIntf" />
  </input>
- <output>
  <soap:body use="encoded" 
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" 
namespace="urn:PerSalIntf-IPerSalSoa" />
  <soap:header use="encoded" message="tns:SalarisSlip0headerResponse" 
part="TAuthorisation" 
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" 
namespace="urn:PerSalIntf" />
  </output>
- <fault name="EPerSoaFault">
  <soap:fault name="EPerSoaFault" use="encoded" 
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" 
namespace="urn:PerSalIntf-IPerSalSoa" />
  </fault>
  </operation>
- <operation name="LaatsteVerwerkingsDatum">
  <soap:operation 
soapAction="urn:PerSalIntf-IPerSalSoa#LaatsteVerwerkingsDatum" style="rpc" 
/>
- <input>
  <soap:body use="encoded" 
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" 
namespace="urn:PerSalIntf-IPerSalSoa" />
  <soap:header use="encoded" 
message="tns:LaatsteVerwerkingsDatum1headerRequest" part="TAuthorisation" 
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" 
namespace="urn:PerSalIntf" />
  </input>
- <output>
  <soap:body use="encoded" 
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" 
namespace="urn:PerSalIntf-IPerSalSoa" />
  <soap:header use="encoded" 
message="tns:LaatsteVerwerkingsDatum1headerResponse" part="TAuthorisation" 
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" 
namespace="urn:PerSalIntf" />
  </output>
- <fault name="EPerSoaFault">
  <soap:fault name="EPerSoaFault" use="encoded" 
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" 
namespace="urn:PerSalIntf-IPerSalSoa" />
  </fault>
  </operation>
  </binding>
- <service name="IPerSalSoaservice">
- <port name="IPerSalSoaPort" binding="tns:IPerSalSoabinding">
  <soap:address 
location="http://localhost/cgi-bin/gateway.exe/soap/IPerSalSoa" />
  </port>
  </service>
  </definitions>


"Bob Swart" <Bob@eBob42.com> wrote in message 
news:237694@forums.embarcadero.com...
> Hi Michael,
>
>> Ok, but here it seems to be Java Client -> Delphi Server.
>
> Ah, I stand corrected. I must admit I'm seldom found in that situation.
> When we need to make Delphi clients for web services, we're often "left
> by ourselves" to solve any interoperability issues, and I've never been
> contacted about interoperability issues between a Delphi server and Java
> or .NET clients (well, apart from the soRootRefNodesToBody option for
> .NET clients, but we figured that one out by ourselves ;-)).
>
>> Maybe it is an option to create the WSDL in a Java toolkit (Eclipse and
>> NetBeans offer support for WSDL design) and use this WSDL then to build
>> the Delphi server? - The result should be more compatible with the Java
>> side this way.
>
> Hmm, could be. I'm not sure if the resulting WSDL would be 100%
> compatible, and if .NET clients would like it, but it surely is an idea
> to pursuit!
>
>> Cheers,
>
> Groetjes,
>           Bob Swart
>
> -- 
> Bob Swart Training & Consultancy (eBob42.com) Forever Loyal to Delphi
> Chairman Delphi Development Network (DDN) powered by SDN - www.sdn.nl
> Embarcadero Technology Partner - Delphi & RAD Studio Reseller BeNeLux
> http://twitter.com/eBob42 LinkedIn: http://nl.linkedin.com/in/drbob42
> Delphi Win32 & .NET books on Lulu.com: http://stores.lulu.com/drbob42
> Personal courseware + e-mail support http://www.ebob42.com/courseware
> Blog: http://www.drbob42.com/blog - RSS: http://eBob42.com/weblog.xml
0
Albert
4/27/2010 9:46:53 AM
Sorry, hit a wrong button so the previous message is not complete

With .Net we get

There was an error downloading
'http://xxx.xxx.xxx.xxx/cgi-bin/gateway/wsdl/IPerSalSoa?wsdl'.
The server committed a protocol violation. Section=ResponseHeader
Detail=CR must be followed by LF
There was an error downloading
'http://xxx.xxx.xxx.xxx/gateway/wsdl/IPerSalSoa?wsdl/$meta

albert
0
Albert
4/27/2010 9:48:45 AM
Reply:

Similar Artilces:

Problem upgrading web service client from Delphi 7 to Delphi XE
In trying to upgrade our web service client to Delphi XE we have now get a web service error of Invalid Format. When we examine the SOAP request we see the following differences from Delphi 7 vs Delphi XE In Delphi 7 we get <SomeStuff xmlns="" xsi:nil="true" /> In Delphi XE we get <SomeStuff xsi:nil="true" /> We have narrowed the failure down to these differences in the client request. Is there anyway to get Delphi XE to generate a SOAP request with the xmlns attribute set to blank as it used to be? Hello, > In trying to u...

Soap call from java to web server in delphi
Hi I've a web service write in delphi 2007 with THTTPSoapDispatcher and THTTPSoapPascalInvoker component and a java client who call my web server, but it doesn't responde in any way. I write in all responde event to see a response but it doesn't work. the source java (get from my customer) is SOAPConnection conn = SOAPConnectionFactory.newInstance().createConnection(); SOAPMessage soapRes = conn.call(smsg, url); smsg is a xml-soap message and url is my websservice url while other java client work fine, the source is URL u = new URL(url); URLConnection conn = u...

Calling Delphi 6 DLL from Delphi 2010
We have a Delphi 6 dll that has a PChar passed to it. The dll function then does a search and returns a PCHar. This works good using Delphi 6 to call and recieve the dll result. We have upgraded our calling program to Delphi 2010 and most of the time, the value is passed back just fine. However, we do have times when we get an access violation, when calling the dll. The dll does process the request. Below is the code. Has anyone had a similar issue using an older version Delphi Dll with Delphi 2010? I am sure that Unicode has something to do with it, but not sure how to fix th...

Calling .NET 2.0 WebService with Delphi (first call fails)
Hello, i have a simple .NET 2.0 Webservice created with VS2008. The webservice contains a method "HelloWorld" that simply returns "Hello world" as string. The method does not need headers to be sent (no authentication and so on) The client is written in D2007 with all updates applied. When i call the service for the FIRST time i get the following exception: Class EDOMParseError with message 'End tag 'ul' does not match the start tag 'p'. Line: 124 '</ul>'. It seems that this comes from an error message tha...

Delphi XE7 call Java Class, JAR, such as the example of Zxing call
Delphi XE7 call Java Class, JAR, such as the example of Zxing call http://zarko-gajic.iz.hr/firemonkey-mobile-android-ios-qr-code-generation-using-delphi-xe-5-delphizxingqrcode/ Generate interface files with Java2pas: http://www.fmxexpress.com/utility-to-generate-java-android-class-and-jar-file-interfaces-for-delphi-xe5-firemonkey/ Am 14.09.2014 10:08, schrieb ww6 wuxu: > Delphi XE7 call Java Class, JAR, such as the example of Zxing call > Hello, I assume this is some Android related question? If that's the case and the other posted reply isn't yet what you want...

ANN: Habari SQS Client
Habari SQS Client for Delphi(tm) is a client library for the Amazon Simple Queue Service. It is easy to use and includes full source code and one year free upgrades. About Amazon Simple Queue Service: Amazon Simple Queue Service (Amazon SQS) offers a reliable, highly scalable, hosted queue for storing messages as they travel between computers. By using Amazon SQS, developers can simply move data between distributed components of their applications that perform different tasks, without losing messages or requiring each component to be always available. Amazon SQS makes it ...

.NET to Java Webservice Calls Slow, but Java test harness to Java Webservices is fast
Hi,I am currently working on a website that makes SOAP webservice calls to a java webservice that is powered by AXIS.  The website is running in .NET 2.0 and the library that calls the java webservice is a .NET 1.1 library.  When calling web methods of the java webservice, I am getting back calls in around the 400 ms range for a 27kb response when the .net site does the call to java; however, the java developers at my job have a test harness that makes a java soap call to the same java webservice using the same parameters as the .net call yet they have a call time of only 20 ms.&nb...

Any where to offer services as Delphi/Delphi for PHP freelance developer?
Hi, I'm a freelance Software Engineer. One of many that in current difficult days, is pushing for self-employment... offering services as Business Analyst and Developer, using Delphi, Delphi for PHP, MySQL, PostgreSQL. Any where in this forum or other you might know where to offer these services to the world? Thank you, Guillermo Guillermo, The Delphi for PHP forum does have For Hire and Wanted For Hire sections if you haven't seen those yet: http://forums.delphi-php.net/ Thanks. -Phil > {quote:title=Guillermo Najar wrote:}{quote} > Hi, > > I&#...

Has anyone successfully used a Delphi web service client against an ENCRYPTED WCF web service server?
Has anyone successfully used a Delphi web service client against an ENCRYPTED WCF web service server? Which is to say, of course, that the URL would be starting with https. Anyone? ...

Delphi and Delphi for .Net
It seems that Delphi for .Net is slower than Delphi Win32 native applicaiton. I would like to know is it true all .Net application is slower than Win32 native applicaiton or it is Delphi for .Net only. Your information is great appreciated, Inung On 2011-06-21 18:20:17 +0100, Inung Huang said: > It seems that Delphi for .Net is slower than Delphi Win32 native applicaiton. > I would like to know is it true all .Net application is slower than > Win32 native applicaiton or it is Delphi for .Net only. If you are only running the code in the application once then, yes, yo...

Calling Java 8 app from Delphi
Hi All: I have been using the procedure below to call a Java program for years. For some reason it no longer works after the machine is upgraded Java 8u25. If fails when it tries to create the process. Any idea of why it would not work with Java 8? Note if I paste the same command line I use in the Delapi XE6 application into a CMD prompt or downgrade to Java 7 it works just fine. Is there a modification to the WinExecAndWait procedure I need to make? Thanks Bob function WinExecAndWait32(CommandLine: string; ShowWindow: Word): DWORD; procedure WaitFor(Pr...

Java CFX Webservice and Delphi 2010
Hi, I'm struggling around with some problems calling my Java Webservice. As long as I use primitive datatypes, such as Strings, Integers etc. everything works fine. But when I try to use objects as parameters my java methods only receive null. So the mapping doesn't seem to work. I put up a simple example: Java Interface for Webservice {code} @WebService(name="TestService", targetNamespace=CNAPBackOffice.NAMESPACE_SERVICES) @SOAPBinding(style=SOAPBinding.Style.RPC, use=SOAPBinding.Use.LITERAL) public interface TestService { @WebMethod(operationName="sen...

Java Application calling Delphi DLL
Hi All, I have a DLL that doing some staff with a Form written in delphi 2006. This form have some events also. I prepared .NET application. While calling Delphi DLL, Im sending events also from .NET to Delphi DLL. When event occures in Delphi DLL, I can trigger same event from .NET application(written in VS) I think this is called callback functions. Now I have to do same thing in Java Application. Is there anybody know how can I do that? Is there any source to read? Regards. Gurcan YUCEL wrote: > I have a DLL that doing some staff with a Form written in delphi 2006. Th...

Java app calling a Delphi DLL
Hello I have a Java application that must call functions inside a large D7 dll. For that, I used JNI calls. That part is OK and the delphi dll is receiving the function parameters smoothly. The Delphi dll has a couple Forms in it. And these Forms are unresponsive. Timers don't work. Buttons will not invoke OnClick handlers. Most important, the assync sockets in the forms, which the dll uses to deliver its work, are not functioning either. It seems that the dll is not receiving Windows messages. I tried to simulate the application loop, but failed. The same DLL works fine i...

Web resources about - Java clients calling Delphi soap services - embarcadero.delphi.webservices

Public Broadcasting Service - Wikipedia, the free encyclopedia
... such as PBS NewsHour , Masterpiece , and Frontline . Since the mid-2000s, Roper polls commissioned by PBS have consistently placed the service ...

This Chinese Public Service Ad Brought to You By a Talking Fetus
The environment, especially air pollution, can be a sensitive topic in China. So it's interesting to see a public service message from the state-owned ...

Disney launches DisneyLife, a UK-exclusive online streaming service
Disney has entered the online streaming market with DisneyLife, a brand new service that launched in the United Kingdom on Tuesday (with a global ...

Researchers poke hole in custom crypto protecting Amazon Web Services
... cryptographic software, academic researchers recently uncovered a potentially game-over weakness in a code library protecting Amazon Web Services. ...

Volvo launches in-car package delivery service in Gothenburg
Filed under: Volvo , Europe , Technology This Christmas, Santa's reindeer will deliver presents to Volvo owners in Gothenburg, Sweden, as part ...

Amazon Reports of Air Freight Service Just the Start, Says Baird
... at $674.43, following an article this morning on Motherboard by Kari Paul stating the company has developed its own trial air cargo service, ...

Ultimate pirate TV streaming service returns with hundreds of channels and new features
This past May, we were among the first to tell the world about a pirate TV service called cCloud TV . The service made a name for itself by collecting ...

5 Services That'll Keep the Men in Your Life Looking Effortlessly Dapper
Use these services and you'll have the sharpest-looking man in the neighborhood. Whether it's for a business trip or the upcoming holidays, ...

I tried a $99 per month service that gave me unlimited access to luxury dresses and I'm obsessed
Over the past two months, I've fallen in love with a new retail service that gives me unfettered access to gorgeous clothes and jewelry from ...

Report: Juniper Is Eating Cisco's Lunch In U.S. Service Provider Routing Market
Report: Juniper Is Eating Cisco's Lunch In U.S. Service Provider Routing Market CRN Juniper Networks appears to be on a comeback in the U.S. ...

Resources last updated: 11/26/2015 5:31:54 PM