Handelbars EnsurePropertiesHelper do not support global properties

Description

During refactoring I meet the following problem.

This was the original configuration for aem dispatcher https://github.com/wcm-io-devops/conga-aem-definitions and it works.

since the variable dispatcher.cache.rootPath repeats in many environments, I moved it to the configuration of conga role my-aem-cms as default valee and remove the variable from environment :

Now maven complains that it can't find the required variable:

the error is raised by handelbar helper EnsurePropertiesHelper used in follow page:
https://github.com/wcm-io-devops/conga-aem-definitions/blob/develop/conga-aem-definitions/src/main/templates/aem-dispatcher/publish/dispatcher_publish.any.hbs

Activity

Show:
Stefan Seifert
June 28, 2019, 6:56 PM

this is no problem in CONGA in my pov.

i've had a look at the project you've tested with:

  • the referenced HBS template is part of the role aem-dispatcher

  • you defined the default value for the role aem-cms (or to be more precise on a role inheriting from aem-cms)

  • this does not work, as it's a completely different role

  • if you want define default values for aem-dispatcher wihtin your project, create a project specific role e.g. my-aem-dispatcher and inherit it from aem-dispatcher, and use this role the environments

  • please note: it's probably bad practice to define dispatcher cache paths within the project (although it's only a default value), as it's depending on the environment. you can define this "my-aem-dispatcher" also in the configuration environment project and use it in all environments there.

Guiquan Weng
January 15, 2020, 10:55 AM

thanks for for answer. you are right. I created a role my-aem-dispatcher and put the default value there. it works.

Fixed

Assignee

Unassigned

Reporter

Guiquan Weng

Labels

None

Components

Priority

Major
Configure