Forums Register Login

Web Services returning File help

+Pie Number of slices to send: Send
Hi,

I had hosted simpla java file as web services using AXIS and TomCat.
This web services recieves the client request and creates pdf/rtf file out it and saves it on server machine.

I am able to successfully make a call to web servies from client machine and it is creating file on server machine.

Further My requirements is that after the file being created, it should be returned to client machine. Please let me know how I can achieve this functionality in WebServices.

Regards,
Hitesh.
+Pie Number of slices to send: Send
Hi Hithesh,
Apache AXIS has support for "SOAP Attachment".
Please check "handling attachment in apache axis"
If you can look at apache axis samples directory, you can also find some workout examples for the same.
Regards
Balaji
+Pie Number of slices to send: Send
Hi BalaJi,

Thanks for the reply.

Actually the google results tell how to send file to server from client.

But i had file being created on server and need it to be send back to client. I am calling Web Service by simply calling its invoke method.
What return parameters I expect for same?

Please help..!!!

Regards,
Hitesh
+Pie Number of slices to send: Send
Hi Hithesh,
Please check the sample at http://svn.apache.org/viewvc/webservices/axis/trunk/java/samples/attachments/ It shows sending a file as an attachment then receives it as a return. The returned file is also compared to the source.
Regards
Balaji
+Pie Number of slices to send: Send
Attachments in JAX-RPC (and Axis 1.x) are handled through javax.activation.DataHandler from the JavaBeans Activation Framework and based on the media-type as supported by the JavaMail. So you will have to install both
JavaBeans Activation Framework (JAF)
JavaMail API
and verify the installation with http://localhost:8080/axis/happyaxis.jsp before attempting the example.

For some background see: SOAP attachments with JAX-RPC
Ew. You guys are ugly with a capital UG. Here, maybe this tiny ad can help:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com


reply
reply
This thread has been viewed 1396 times.
Similar Threads
File Permission error while calling java Stored Procedure
run .bat file from client machine of deployed web application on server machine
steps to run an applet
instaling application on client side
serial communication using applet
More...

All times above are in ranch (not your local) time.
The current ranch time is
Apr 16, 2024 08:28:40.