Wednesday, April 27, 2011

sling:OsgiConfig for multiple run modes

You can have multiple run modes and have CQ (or Sling.. I don't know) select proper sling:OsgiConfigs.

For example,  if your run modes are a,b config.a.b are applied:

  • author,production
    • /apps/<foo>/config.author.production/*
  • author,staging
    • /apps/<foo>/config.author.staging/*
  • publish,production
    • /apps/<foo>/config.publish.production/*

Probably order of run modes are important. And I'm not sure if more than two run modes will work.

TODO:

  • author,production,foo,bar
    • /apps/<foo>/config.author.production.foo.bar/*
    • /apps/<bar>/config.author.production.foo.bar/*
    • /apps/<foo>/config/config.author.production.foo.bar/*
    • /apps/<foo>/config.production.bar.foo.author/*

test what configuration is selected...

No comments:

Post a Comment