In my application I have beans annotated with @Profile(\"prod\") and @Profile(\"demo\").
The first one, as you can guess :), is used on beans that
You can setup your web.xml as filtered resource and have this value filled by maven from maven profile settings - that what we do.
in pom filter all resources (you can do taht if you have no ${} marking in them)
src/main/webapp
true
in web.xml put
spring.profiles.active
${spring.prfile}
in pom create maven profiles
DEFAULT
true
prod
DEMO
demo
Now you can use
mvn jetty:run -P DEMO
or simply -P DEMO with any maven command