I have to read the property file. Could suggest me the best way to handle the property file.
My code is deployed on the server as a jar file.
I have to totally avoid the hardcoding.
Currently I am reading the properties using.
Properties prop = readProperties("C:\\PPMCustomCode\\DemandService.properties");
String endpoint = (String)prop.getProperty("ENDPOINT_URL");
It is not convincing & not a best way.
I tried using the resource bundle also still some hard coding remains. Can I keep my properties file in the same folder as the jar file & it will take the relative path? In RAD we could configure it in the admin console. I don’t have that liberty to use server configuration settings here, as I am working on
JBoss.