I have servlet deployed in JBoss. I want to read/write data into a text file based on the client input. Where should this text file be put in the JBoss directory structure?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
There the
/datadirectory is for.Its absolute path is available by the
jboss.server.data.dirsystem property.See also:
Note that you’re this way tight-coupling the web application code to a specific server. If you ever want to change servers, keep in mind to change the above code as well to whatever the new server supports (or not).