I have two questions 😉
-
Is the “web.xml” in a WAR-File intended to contain project/customer-specific informations
- Example: For customerX we want Filters for Bandwith and Compression for customerY we dont want those Filters
-
How does the Maven-Build-Process allow us to make different Builds for such project/customer-specific WAR-Files.
- Should it be done with maven profiles
- Should it be done with separate build-processes that integrate the release-project into individual WAR-Builds
To first one i would recommend to say No. You should solve that by using property files to handle such things.
you can handle that with profiles, but with the draw-back that you need to rebuild for every customer you have. Lets say dev, test, prod. This can be solved by properties but that means to build three times..I have described a better solution here which handles the different locations with a single build. That will solve the problem for release as well.
It is also a solution to use a separate maven project (lets call it configuration module) which depends on the WAR file). But this would mean to three different projects like dev, test and production which i find not very handy.