permaculture playing cards*
The moose likes Tomcat and the fly likes serving pdf files Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Tomcat
Bookmark "serving pdf files" Watch "serving pdf files" New topic
Author

serving pdf files

Matthew Phillips
Ranch Hand

Joined: Mar 09, 2001
Posts: 2676
I have an ftp server with several pdf files. I would like to create a servlet that will forward requests directly to these files. I am running Tomcat on a different server from the ftp server. Is this possible?


Matthew Phillips
Dale DeMott
Ranch Hand

Joined: Nov 02, 2000
Posts: 515
Hmm.. well what I did with PDF is stream my files to the user. I let the servlet control if the user had access to the file or not. You can forward them to the PDF files, however that would leave the directory open. If you control the streaming through the servlet, then you have a security controled by the servlet.
Something to think about.
-Dale


By failing to prepare, you are preparing to fail.<br />Benjamin Franklin (1706 - 1790)
Matthew Phillips
Ranch Hand

Joined: Mar 09, 2001
Posts: 2676
I am going to move this to the Tomcat forum because I like your idea and I am about to get Tomcat specific.
Matthew Phillips
Ranch Hand

Joined: Mar 09, 2001
Posts: 2676
I am going to hijack my own thread slightly. Is it possible to access files that are stored outside of CATALINA_HOME?
Matthew Phillips
Ranch Hand

Joined: Mar 09, 2001
Posts: 2676
Go ahead and delete this post. I was brain dead yesterday and didn't think before I posted.
Mike Curwen
Ranch Hand

Joined: Feb 20, 2001
Posts: 3695

I don't mind leaving evidence of brain-deadness around. I do it all the time in my code, so I don't see that you should get the magic treatment.

kidding!
Matthew Phillips
Ranch Hand

Joined: Mar 09, 2001
Posts: 2676
It certainly won't be the first evidence of me having a brain dead moment. Some would say that everyday is new evidence.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: serving pdf files
 
Similar Threads
Need script to copy file on FTP server from Windows
FTP server
FTP: Transfer is working but all TXT files have no content
Filetransfer (FTP or similar)
Commons Net Ftp how to perform checksum on file in the server