File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Distributed Java and the fly likes pdf file trasfer , from server to client. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Distributed Java
Bookmark "pdf file trasfer , from server to client." Watch "pdf file trasfer , from server to client." New topic

pdf file trasfer , from server to client.

edi kapllani

Joined: May 09, 2001
Posts: 14
Hi all,
I am going to write an application,
which will transfer pdf files from a server and saves them to a client.
This application will be scheduled to start periodically.
At the begining I thought to use a client application using URL calling a servlet to the server, but I'm not so happy for that kind of solution.
Does anybody has any advice as to do using RMI , or any other solution client server ?
thanks in advance,

edi<br />SCJP, SCWCD, SCBCD,(SCEA... project to submit)
Ranch Hand

Joined: Jul 06, 2001
Posts: 54
Hi Edi,
Possible scenarios and protocols :
1- Samba Protocol
If the client and the server belong to the same IP broadcast domain, then the simplest solution would be this one :
----> Server side
Run a Samba server on one machine, and share/advertise the folder that contains the PDF files
----> Client side
mount/map this folder on the client filesystem.
The mounted folder, would appear to the client as any other folder on the local machine, and can be accessed using APIs.
2- HTTP protocol
---->Server Side : run a HTTP server where you would put your pdf files
---->Client Side : use the + streams to download the files by specifying there URLs
The advantage of these 2 solutions with respect to RMI, is that you have to implement only the client side.
The HTTP client that you would write for the HTTP server, would be the same as the one that you would write for the servlet. However, I don't see any need for servlets here, since a basic HTTP server is able to identify and upload files.

Omar IRAQI Houssaini
I agree. Here's the link:
subject: pdf file trasfer , from server to client.
jQuery in Action, 3rd edition