valtech / aem-easy-content-upgrade

AEM Easy Content Upgrade simplifies content migrations in AEM projects
Other
61 stars 25 forks source link

AEM as a cloud - author instance - missing bindings #192

Closed michal-tobiasz-wttech closed 2 years ago

michal-tobiasz-wttech commented 2 years ago

Unfortunately, today after the fifth execution of the deployment on Cloud Manager, the issue occurred.

21.06.2022 11:44:47.064 [cm-p29439-e93903-aem-author-7ddd5dccff-xr5zx] *ERROR* [Thread-100] com.icfolson.aem.groovy.console.impl.DefaultGroovyConsoleService error running script
groovy.lang.MissingPropertyException: No such property: aecu for class: Script1
21.06.2022 11:44:47.891 [cm-p29439-e93903-aem-author-7ddd5dccff-xr5zx] *INFO* [Thread-100] de.valtech.aecu.core.service.AecuServiceImpl Executing script /apps/aecu-scripts/test/five-thousand-pages-test/1-pages-modification-long-script.groovy
groovy.lang.MissingMethodException: No signature of method: Script1.getResource() is applicable for argument types: (org.codehaus.groovy.runtime.GStringImpl) values: [/var/aecu-installhook/1-pages-modification-long-script]
    at de.valtech.aecu.core.service.AecuServiceImpl.executeScript(AecuServiceImpl.java:209) [de.valtech.aecu.core:6.0.3]

Attaching logs from today's deployment author_aemerror_2022-06-21.zip

gruberrolandvaltech commented 2 years ago

I guess this is caused by the Sling pipes actions you have before. Looks like this delays the startup and therefore causes the issue. Can you run the Sling pipes actions after startup? E.g. AECU starts a separate thread for the migration to not block the "activate" method.

michal-tobiasz-wttech commented 2 years ago

Ok, I will turn off the execution of Sling pipes and do more deployments to be sure that everything works fine in case of groovy execution. I will keep you updated

michal-tobiasz-wttech commented 2 years ago

I can confirm that Sling pipes could cause issues with bindings for the latest version of AECU. I have turned off the Sling pipes and executed about 10 deployments and non of them had an issue. Thank you for your help!