I have an enum that I inject into the application scope such as
public void contextInitialized(ServletContextEvent sce) {
sce.getServletContext().setAttribute("app", ApplicationProperty.INSTANCE);
}
My question, is I have to deploy this web application twice with different property files. Would that cause a problem since I am using an enum, would they share the same values? Thanks.
Application is deployed twice with different context paths and property files (think of as secretKey=12923 and the other one has secretKey=48984 in the property file). First instance deploys it as /ForInternalUse and the other deployment /ForExternalUse. Both deployments are under the same web app server (glassfish).
PS. I have done a small test on glassfish 3.1 but it seems properties are not shared. Second deployment does not impact the first deployment.