Passing data from Excel to a Web service - java

I have a excel file with testing data and am trying to send these parameters to a new web service (Testing) in java. These data will inturn be sent to another web service that is already in use now. After sending the request data, I will also need to get the response and update the excel file with the testing result ,say pass or fail. I haven't worked with web services(java) before , so am not sure how to go about this. Any tutorials or advice on this from people who have worked on this before will be great.
Thanks

Hope you have worked with Java before because this is not a straightforward assignment.
You will need an API to read the Excel spreadsheet ( look up JXL or Apache POI ), you will need to generate a web services client for your WS endpoint using JAX-WS ( wsimport ). Once you have that, you can call your web service via Java and the response will be a Java object that you can then use to update your Excel sheet ( via the api of your choice ).
Good luck.
http://jexcelapi.sourceforge.net/
http://download.oracle.com/javase/6/docs/technotes/tools/share/wsimport.html
http://poi.apache.org/spreadsheet/index.html

Related

Writing a simple java client which uses soap messages for bunch of provided WSDL and XSD files?

I want to write a java client to use some medical api. On there website they have uploaded a bunch of WSDL files and corresponding XSD files, along with documentation explaining the SOAP messages format to consume each service.
In past I have used REST API of Amazon and Azure to write java client but this seems to be different.
I have read about JAX-WS and also tried to create a dynamic web project in Eclipse using Tomcat but nothing working (https://wiki.eclipse.org/Creating_a_Java_Web_Service_Client).
Could some one explain me basic steps on how to write a simple java
client to **consume these WSDL and XSD files using SOAP messages** and
point me to really good tutorial where I can understand the underlying
concepts?
Till now:
I read about basic wsdl and xsd structure.
Tried to use Postman and SoapUI to make service call to these services.
But struggling to make first step towards making a simple java client project to interact with these services.
I would recommend you go check SAAJ API

Use C# or VBA to call Jersey JAX-RS REST Webservice

I have a Jersey REST webservice and it works fine with java client. Now I'm wondering is it possible to use C# or VBA to call this webservice? Sorry I am new to C#/VBA. I am trying to create a add-in for excel. As far as I know I can use these two to create add-in. So my questions are:
What's the best way to create add-in in excel for getting/uploading data? Is Java possible? Or should I use C#?
If I use C#, is it possible to call java webservice in C#? I want to upload data via this webservice.
Thanks in advance.
Anything that can build an HTTP request matching the input expected for your Jersey REST service will work. JAX-WS and JAX-RS services are going to be exposed as agnostic access points for anything which can send an XML/JMS or HTTP request. You can confirm this by simply opening the endpoint in your web browser and trying to submit some GET requests that way.
That is the beauty of web services, they SHOULD be language agnostic. Basically you are just calling a url to return you some xml/json data which c# can handle.

Modify SharePoint 2010 document library using Java

In my SharePoint site, there are several document libraries, each assigned to a different group of people. Users need to transfer files between them often, and my boss wants a faster way than copy/pasting the files into another library then deleting the original, and he doesn't want anyone having direct access to the document hierarchy.
Someone had the idea to run Java code that would automatically transfer documents from one library to another, using inputs from a pop-up for the source and destination. Can Java code be stored on a SharePoint server and be executed by a user action?
Java code can not be used SharePoint directly. What you can try is using C# or VB.Net through which actions can be executed on SharePoint using object model of SharePoint.
Another option is using web services
1、You can use then Copy.asmx web service to upload document:http://msdn.microsoft.com/en-us/library/copy(v=office.12).aspx
2、upload large file:http://www.codeproject.com/Articles/166763/WCF-Streaming-Upload-Download-Files-Over-HTTP
3、About authenication:http://msdn.microsoft.com/en-us/library/copy.copy.copyintoitems(v=office.12)
4、You can use these web services from java:
http://www.coderanch.com/t/478814/Web-Services/java/Microsoft-Sharepoint-web-service-Java
SharePoint Webservice from Java Webapp using CXF with Kerberos/NTLM authentication
Authentication failure calling SharePoint Web Service (JAX-WS client)
Regards
Hiren Gondhiya
You can create a WCF service in SharePoint and then consume it from your Java application.

How to query a SOAP Service in Java

I would like to connect and query Trip Advisor's SOAP service. I currently have a WSDL for the service, and have connected to it using SOAPUI. I have been doing a lot of research about SOAP, but still am not sure I fully understand what I need to code in order to query the service as I would like.
The service takes an input of a simple place-id(I Have a list of many place-ids that I would like to query) Then it returns with the SOAP reply, which I would like to save as a new file(named place-id.SOAPrequest).
I have been doing reading on AXIS2, how to generate API code using SOAPUI, and launching a SOAP service in Netbeans.
I am currently trying to launch a AXIS2 service on my server, and then I assume load into it the java code that SOAPUI generating for the wsdl. But I don't know how to do this or if this is even the correct approch to the problem. Any suggestions or advice would be great.
See this step by step guide to Generate Java Axis 2 WebService CLIENT/SERVER

how to use a webservice which created on c#t at java platform

Previous developers created a webproject which consumes a webservice in .net platform and they wanted me to use this webservice on jsp. I read netbeans tutorials and find out that webservice is irrelevant to platform. However the problem is at .net project I could not find a file whose extension is .wsdl or a werbservice.amsx.There is a service.cs which was implemented has webservice commands a lot.How i can consume or use this service on a jsp file? I would be appreciated if you can help me. Because it takes my hours to read documentations and I do not have any clue how to use it on .jsp.
Best Regards
Altaico
Read this detailed tutorial on C-sharpcorner.com on how to reference and use asmx web services in JSP
For Web Services in general to function correctly you need to have a WSDL. Most modern web service stacks can generate these automatically.
Have a closer look.
Try to call the asmx file from your browser with ?wsdl query string.

Categories