How To: Call a Java EE Web Service from a .Net Client

Hi,

I have to call a Java Web Service from a .Net Client .I'm using VS2008 (.net 3.5)

Did you face the same situation ?

The web service offers some methods. Each method returns a xml file and a xml attachment.

I found this article.http://blogs.msdn.com/bursteg/archive/2008/07/19/how-to-call-a-java-ee-web-service-from-a-net-client.aspx .

Do you think that this is a good resource ?  I watched something about WCF. Have I to use WCF ?

How can I manage xml attachment ?

thank you for your attention .

 

 

0
antoabc
1/21/2009 1:08:12 PM
asp.net.xml-web-services 7071 articles. 0 followers. Follow

6 Replies
1383 Views

Similar Articles

[PageSpeed] 37
Get it on Google Play
Get it on Apple App Store

It's a good resource and there are also other ways to do it. 

Basically you need to understand which standards whe Java service uses (e.g. which security protocols and versions, which attachment format).

One you have this information you can decide the best way to access it.
http://webservices20.blogspot.com/
Web Services Performance, Interoperability And Testing Blog
0
yaronn01
1/21/2009 4:18:32 PM

Thank You for your answer  .

In this moment I know that web service was developed with Java. It is installed on a Tomcat server.

A method must return a xml string and a DIME attachment. Attachments are encoded .

I tested article's code. It seems that is no way to manage attachment ...

When I invoked a method I saw this error . "The content type application/dime of the response message does not match the content type of the binding (text/xml; charset=utf-8). If using a custom encoder, be sure that the IsContentTypeSupported method is implemented properly.".

My custom code ( more or less)

WebApp.MyReference.WSMethodClient myMethod = newWebApp.MyReference.WSMethodClient();

// return a xml string and a attachment to soap message. I get xml string , but how can get attachment  ?
string l_var = myMethod.service( p_CodApplication,   p_UserName,   p_Password ); 

How can I manage the attachment ? 

 

 


 

 

0
antoabc
1/21/2009 4:53:26 PM
The only way to use DIME with .Net is by using .Net 2.0 proxies + Web Services Enhancements 2 (WSE2). 
You should read about WSE2 and download it.
The article uses WCF which is .Net 3.5 and cannot consume DIME (unless you will implement it yourself).
http://webservices20.blogspot.com/
Web Services Performance, Interoperability And Testing Blog
0
yaronn01
1/21/2009 8:34:02 PM

Yaron, WSE 2.0 is very obsolete. Would WSE 3.0 work? It is somewhat less obsolete.

BTW, is DIME also "obsolete"? Should we be asking Microsoft to support it in WCF?


John Saunders | MVP – Connected System Developer
0
johnwsaunders3
1/21/2009 8:39:13 PM

I found this :

http://blogs.imeta.co.uk/jyoung/archive/2008/08/29/345.aspx

I'm going to test it soon ..

0
antoabc
1/21/2009 9:51:25 PM
John

WSE3 does not support DIME. And, yes, DIME is obsolete and should only be used with legacy services.
http://webservices20.blogspot.com/
Web Services Performance, Interoperability And Testing Blog
0
yaronn01
1/22/2009 2:25:05 PM
Reply:

Similar Artilces:

How to call a .net web service from another .net web service?
Hi all,I have developed two asp .net web services using visual studio .net 2003.I wish to call one web service from another web service.I tried adding a web reference of the web service in another web service and was able to do so.but i m not able to access the web methods provided by the web servicecould you please suggest a way to go about itExpecting quick replyThanxCharmy try to make sure that you reference it in the web reference and call it properly this is sample  [WebMethod()] public double CalcDistance(int x1, int y1, int x2, int y2) { Calculator.Service1 calc = new...

Web service in .NET from Java Web Service
Hi there,I'm pretty new to .net (although i have years of experience with the old vb 6, access 2k, as well as java)... and need some with perhaps either some syntax or something.Here is the wsdl.<wsdl:definitions targetNamespace="http://www.dynix.com/schema/book">−<wsdl:types>−<schema targetNamespace="GetBookInfoByISBN">−<complexType name="BookInfoType">−<sequence><element maxOccurs="1" minOccurs="0" name="Title" nillable="true" type="xsd:string"/><element maxOccurs=&quo...

.NET web services Vs Java Web Services
Hello, does anyone know of a book or good source of information that compares .NET and Java Web Services? (I would like soemthing neutral if possible). I am thinking of approaching this subject for my dissertation? Many Thanks Rob Hi Rob, Last year I had to give a powepoint presentation on Web Services. I noticed some good books at barnes and noble that discussed the subject. These books were specific to Java and discussed Web Services in a very clear fashion. They gave some elementary examples that were easy to understand. I have not yet had the pleasure of creatin .NET Web Servi...

Call a SECURED (with glassfish) Java EE Web Service from a .Net Client
Hi, Im trying to call a java web service in visual studio 2008 using a simple forms application. The problem that I'm running into is with the security. Can someone point me in the right direction as far as calling a secured java EE web service using .Net? Thanks. Adam Im unfamiliar with glassfish, however if the web service's security is WS-Security compliant, then you'll have to use WSE 3.0 (addon by Microsoft to make web services more useful) or Windows Communication Foundation. Thanks for the reply. Can you point me in the direction of using WSE to call a java...

How to call .net web service from Java web application?
Hi all,  I have a vb .net web service.How do i call .net web service from Java web application?What all resources I need?Can you please provide a sample application where a java application is invoking methods of .net web service? Thank you Hi, First I am not familiar with java language, but web services are universal operating system and language independent. It doesn't matter where the services is or in what language is written you just invoke it  and it gives you "replay".  Probably you must reffer to java consuming web services.   Regard...

Cannot call a web service from java script using ajax in .net 3.5 web applications
As like 2005 .net websites i tried to consume a web service from client side java script  using Ajax script manager in  .net 3.5 (2008) version web application it was not working, Event it works with 3.5 web sites, What i have to do to solve the issue. Thanks in advance Hi, can you create the least amount of code to reproduce it and post it? This gives us the ability to check out your code and better guide you. Also please check out this article: Create a Simple WCF Web Service and Use In JavaScript With Visual Studio 2008 and .Net 3.5.  Grz, Kris.Read my blog. Handy Fire...

null parameter problem while calling .net web service from java client
Hello, I have a C# .NET web service and a Java client . My java client is able to call the C# method , but when the client calls methods containing complex type parameters , they are ending up being null on the .net side eventhough I am sending the parameters with valid values. I traced also the SOAP messages and they are also semms OK. But why are they arriving null to .net side. What goes wrong? Did anybody whom faced this problem could solve it and how. As I see this is a very common problem as I searched similar forums. So any acceptable answer will be useful t...

Java Call to .Net Web Service
Hi, I have a web service that needs a dataset as in parameter in my .net application. A Java application is going to call this web service. There seems some problem which the Java app can not pass in a parameter as dataset. xml serialized string. The .net application can not translate the string back to dataset. Can someone help?Dave Dave That's one of the most asked questions about web services.  You will have real difficulties trying to use DataSets in an interop environment.  You can improve the situation a little by using strongly typed DataSets, but ideally y...

Client .NET Web Service Java
 Hi, I am reading some docs about Web Services and I have some questions,  1) If I have a Web service wrote in Java, Can I use it from a asp or a Windows form??2) If It's not possible, and the webservice only have to recive 2 parameters (for instance add(int a, int b)) can I write myself the SOAP message and pass it to the Java WebService?? I'm not sure about all of this, because to make a client for a webservice you only have to know what parameters are needed. Thanx for your help! Please remember to click “Mark as Answer” on the post that helps you, and to click...

Calling a Web Service from a Web Service
Hello,I was looking for some feedback on calling a web service from within a web service. I've heard that it's not good practice (or not possible). I have a scenario where I think it might make some sense.Within our infrastructure, we've created a web service that handles incoming updates on the statuses of all processes. This has proven to be a good thing since it allows applications to communicate across server to make status updates. It's also used by third party developers and applications to communicate with our infrastructure.Along these lines ... we are planning to create a new compon...

.NET CLIENT TO ACCESS a non. NET WEB SERVICE
I develop in .net and need to create a web client to connect to a web service built in Java. http://xchainj.com:8080/axis/services/ScsEnvirodatWaterQualityIndexServiceSoap Its pretty easy when the web service was also built in .net. You can just create a web reference with the gui and automatically can see its functions and stuff. when i put this url in the box and hit go i dont get to see its functions. maybe this shouldnt be the url of the WSDL?? I Have no idea. Im very new to all of this. If there are any examples of .net clients connecting to non .net web clients it woul...

Can you return .net web controls in a .net page from a web service?
I've got a problem with a project. I've got to compile an entire .net page and return it as part of a Web Service for display. The problem I have is that I need to add WebControls and functionality to the page so that not only the html content and images are displayed (which I've managed) but that textboxes, labels, buttons and datasets can be displayed also. Essentially I need to make a call from one site for a page, populate the page and return it in a state as though it resided on the same server/webspace as the calling page. Code is currently built as follows into a string: strOpenHT...

xml web service --uploading the file to the xml web service
how can we upload the file in the xml web service 1.i mean what will be the return value in the proxy class 2.and how am i going to send the file to the xml web service----regards Bipul Kumar Here are some links to articles that helped us get this done: http://msdn.microsoft.com/webservices http://www.microsoft.com/downloads/details.aspx?familyid=06255a94-2635-4d29-a90c-28b282993a41&displaylang=en https://www.sys-con.com/dotnet/article.cfm?id=458 Hope this helps....

credentials for .net calling java web services
Hi, I have a Java web service which i need to call in an ASP.NET application. This Java web service requires authentication against LDAP server. Apache Axis is used and it will retrieve the username and password from the message context. Is there any way i can set the username and password in the message context in ASP.NET? ...

Web resources about - How To: Call a Java EE Web Service from a .Net Client - asp.net.xml-web-services

United States Department of Health and Human Services - Wikipedia, the free encyclopedia
The United States Department of Health and Human Services ( HHS ) is a Cabinet department of the United States government with the goal of protecting ...

ATM stolen from Fyshwick service station dragged down Barrier Street by thieves
Two men caught on camera stealing ATM from Fyshwick petrol station and dragging it down the road.

V/Line trains forced out of service by mysterious wheel fault
Regional rail operator V/Line has been forced to pull many of its newest trains out of service because of a sudden and mysterious spate of wheel ...

Avvo Bares Fixed-Fee Legal Services
Like fixed-fee bar referral programs, Avvo Legal Services sounds like a winner for the right lawyers, that is.

Microsoft Updates Bing Logo as Search Service Grows Up
... green "is easier to see over yellow," a Microsoft spokeswoman said, and because the new look displays well "across Windows devices and services." ...

Al Jazeera to expand digital services in US
... Doha and New York: Al Jazeera Media Network on Wednesday announced from Doha its intention to expand its existing international digital services ...

Cock.li server seized again by German prosecutor, service moves to Iceland
(video link) The administrator of the cock.li e-mail hosting service told Ars on Friday that a second hard drive had been seized from his Bavarian ...

Producer Prices Decline More Than Expected, Services Disappoint; Oil Approaches $29
... did rise, but only 0.1 percent while the year-on-year rate is down 2 tenths in the month to only plus 0.3 percent. The ex-gas ex-food ex-services ...

L Train may not run between Williamsburg and Manhattan for "years" due to proposed service repairs
L Train stop with Craig Finn ad Well here's very bad news for anyone who lives on the L line and likes to travel between Brooklyn and Manhattan: ...

Microsoft has cut the price of its cloud services product — one month after Amazon did
Microsoft has cut the price of Azure, its cloud services product, after Amazon did a similar thing earlier in January, ZDNet reports . Amazon ...

Resources last updated: 1/15/2016 11:02:13 PM