Currently WebModuleUtil.java will do the current task of moving webapp directory to Tomcat Servlet Container but we intend to take some part of the code i.e., the Open web app Part which will have a manifest.webapp file in it to a custom Folder(owa.apppathfolder-globalproperty).
Making changes to core is a direct way if doing it https://github.com/openmrs/openmrs-core/pull/1554 this is what we intend to do. But as per our conventions that core should not know about modules we intend to do that from OWA Module
What we have tried:
- Method Interceptor (WebModuleUtil.startmodule being a static method we cannot intercept that)
- Filter to intercept the request this was to some extent successful i.e, we were able to intercept but as we need mutlipartdata and we are inside a filter so we cannot cast HttpRequest to MultipartHttpRequest directly we are stuck.
Would be of help if anybody have some suggestions on how to do proceed or if any other way of doing it.