I have implemented Hib search in our project. This project needs to be deployed in different environment.. i.e. production, development, testing etc..
I want to store the index in <tomcat_dir>/webapps/<app_name>/WEB-INF/index. This tomcat_dir is different in different environments. I want that value of "hibernate.search.default.indexBase" key be initialized dynamically at runtime.
How can i achieve this ? is there any way to set the index base dir programmatically at run-time ? because in hibernate configuration file i have to provide a static value of the dir path.
Thanks,
Bhavin
|