• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Write to server outside web application?

 
joseph corner
Ranch Hand
Posts: 50
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
Is there a way to write to a file on the server outside the JSP's web application folder?
Thanks!
J
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65123
91
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes, you can use normal Java I/O to write a file anywhere you have permissions to. Is there a bigger issue you didn't mention?
 
joseph corner
Ranch Hand
Posts: 50
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
the permissions thing is what concerned me. In a web app. that end users will be hosting on their own servers, how do I know that I will have the required permissions outside the web app. folder?
Thanks, J
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65123
91
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Of course your code should handle any permission failures gracefully, but beyond that it's sort of out of your control. As part of the installation of your application, you should ensure that the appropriate file structures have the required permissions.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic