Move to aem as a cloud service - Code smells
All,
We are using the deployment manager and trying to resolve the code smells
While i could resolve most the following are the ones i need kinda second opinion
1.Use of legacy components- how could this be resolved without majorly breaking anything?
The component /apps/XXX/components/structure/pages/base (transitively) extends the legacy foundation component wcm/foundation/components/page.
2. What is the best approach to resolve this? What would be the best approach for the JS and other site design/component specific files now? knowing that apps and etc cannot reside in the same package ? Should i just move it to under ui.content package?
Inclusion of both /etc/designs and /apps/XXX in the same package violates the separation of immutable and mutable paths in the same package.
3. How does one resolve the migration to editable templates, i see modernizer tool as an option , but is that the only option? If yes are there explicit steps?
/apps/XXX/templates/landing-page is a Static Template under /apps. The use of Editable Templates is recommended.
4. I understand there are predefined run modes allowed but if one wants to use say "build" as run mode , how does that happen, should they put it within the generic config like config.author config.pub etc?
The OSGi installer path /apps/XXX/config.publish.build uses a runmode build that is not supported on AEM as a Cloud Service.
5. What is the best way to resolve createAsset issue
The method com.day.cq.dam.api.AssetManager#createAsset(Ljava/lang/String;Ljava/io/InputStream;Ljava/lang/String;Z)Lcom/day/cq/dam/api/Asset; has been deprecated and is not recommended to be used on AEM.