Load properties file in servlet?
java, jsp, servlets
Solution
Get rid of the "classpath" prefix.: `.getBundle("/properties/custom")`
The "classpath" prefix is not a standard, it is defined by some frameworks like spring.
Problem
I have a java maven project. i have placed a properties file in `src/main/resources` folder. ``` src/main/resources | |___properties | | |___custom_en_US.properties ``` I am loading properties file as below in servlet. ``` ResourceBundle bundle = ResourceBundle.getBundle("classpath:properties/custom", request.getLocale()); ``` but above line is throwing exception saying resource not found. How can i give path to properties file? Please help me. Thanks!