tomcat7 - How to check inside Java code if the server is running in localhost -


i have need check @ runtime if server running in http://localhost searching on net haven't found solution. advice?

thank

we have running setup following configuration being done:

  1. in catalina.properties, define active_profile=prod production, active_profile=stage stage or active_profile=dev developer machine
  2. have different connection properties files matching profile key - jdbc_prod.properties, jdbc_stage.properties, jdbc_dev.properties
  3. refer connection properties jdbc_${active_profile}.properties in configuration.

Comments

Popular posts from this blog

html - Outlook 2010 Anchor (url/address/link) -

javascript - Why does running this loop 9 times take 100x longer than running it 8 times? -

Getting gateway time-out Rails app with Nginx + Puma running on Digital Ocean -