Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

How do I find out Tomcats home directory from inside a running servlet?

0
10 Posted

How do I find out Tomcats home directory from inside a running servlet?

0
10

Location: http://www.jguru.com/faq/view.jsp?EID=416016 Created: May 5, 2001 Author: Alessandro A. Garbagnati (http://www.jguru.com/guru/viewbio.jsp?EID=32727) Question originally posed by frederi barachant (http://www.jguru.com/guru/viewbio.jsp?EID=117062 When Tomcat is executed (and you can check both tomcat.sh and tomcat.bat in the tomcat’s bin directory) the property ‘tomcat.home’ is set using -D. This means that you should be able to access it using System.getProperty(“tomcat.home”).

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123