Expand my Community achievements bar.

SOLVED

Run Modes precedence in Cloud AEM

Avatar

Level 3

Hello, 

 

I am trying to understand the Run Modes precedence in Cloud AEM.

 

I read the Adobe doc here, which provides a list of run modes like below:

 

 

config (The default, applies to all AEM services)
config.author (Applies to all AEM Author service)
config.author.dev (Applies to AEM Dev Author service)
config.author.rde (Applies to AEM RDE Author service)
config.author.stage (Applies to AEM Staging Author service)
config.author.prod (Applies to AEM Production Author service)
config.publish (Applies to AEM Publish service)
config.publish.dev (Applies to AEM Dev Publish service)
config.publish.rde (Applies to AEM RDE Publish service)
config.publish.stage (Applies to AEM Staging Publish service)
config.publish.prod (Applies to AEM Production Publish service)
config.dev (Applies to AEM Dev services)
config.rde (Applies to RDE services)
config.stage (Applies to AEM Staging services)
config.prod (Applies to AEM Production services)

 

 

I understand that the more specific ones(eg. "config.author.dev") takes precedence over the lower ones(eg. "config.dev").

 

But what about between "config.author" and "config.dev", which one has more specificity? As you already know, I can be on the Author mode of a Dev environment, which satisfies both, so which one takes precedence here?

 

Thank you,

 

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hi @sean12341 
If you are targeting configs for :

Author : config.author

Publish : config.publish

Dev(Author): config.author.dev

Dev(Publish): config.publish.dev

Dev(Author & Publish): config.dev

 

You don't need to create more than one config for same runmode.

 

 

Order of Precedence:

  • Configuration settings are applied based on an order of precedence. The settings in the /apps directory take precedence over /libs settings.
  • Run mode-specific settings take precedence over common settings.
  • If there are multiple configurations under the same run mode, the order of the paths in the repository matters.
  • Configurations at deeper paths in the repository structure take precedence.


Arun Patidar

View solution in original post

2 Replies

Avatar

Correct answer by
Community Advisor

Hi @sean12341 
If you are targeting configs for :

Author : config.author

Publish : config.publish

Dev(Author): config.author.dev

Dev(Publish): config.publish.dev

Dev(Author & Publish): config.dev

 

You don't need to create more than one config for same runmode.

 

 

Order of Precedence:

  • Configuration settings are applied based on an order of precedence. The settings in the /apps directory take precedence over /libs settings.
  • Run mode-specific settings take precedence over common settings.
  • If there are multiple configurations under the same run mode, the order of the paths in the repository matters.
  • Configurations at deeper paths in the repository structure take precedence.


Arun Patidar

Avatar

Level 4

config.author or config.publish - gives you the ability to manage common configurations for all the authors and publishers

 

similarly, you can use environment specific configs to have common configs for the env like dev, stage and prod.

 

finally, instance specific configurations can be added to config.author.{env} or config.publish.{env}

 

its not required to keep the same config in all the combinations of run modes. just place it where needed and reduce the duplication.

 

Regards,

Vikram.