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
@Profile(\"prod\")
@Profile(\"demo\")
My experience is that using
@Profile("default")
the bean will only be added to the context if no other profile is identified. If you pass in a different profile, e.g. -Dspring.profiles.active="demo", this profile is ignored.
-Dspring.profiles.active="demo"