Details
-
Bug
-
Status: Closed
-
Normal
-
Resolution: Fixed
-
2.24.07, 2.26.00
-
None
Description
When a Groovy script that is created in the updater editor calls an unknown method, it cannot be removed from the queue anymore after is has been executed. Such a stuck script can only be removed manually from the queue using the console.
Steps to reproduce:
1. login as admin
2. navigate to the Updater Editor
3. create a new Groovy script
4. above the 'doUpdate' method, add the following line (note there is no space between 'new' and 'Random()'):
def random = newRandom()
5. Click 'Execute'
Expected behavior: an error is logged in the script output area and the script moves to the History
Actual behavior: the error below is logged only in the console, and not in the script output field. The script also stays in the 'Queue'. The CMS user has therefore no clue what goes wrong, he has to look in the logs.
Error logged:
[INFO] [talledLocalContainer] Exception in thread "pool-3-thread-2" groovy.lang.MissingMethodException: No signature of method: org.hippoecm.frontend.plugins.cms.dev.updater.UpdaterTemplate.newRandom() is applicable for argument types: () values: []
[INFO] [talledLocalContainer] Possible solutions: getRandom(), setRandom(java.lang.Object)
[INFO] [talledLocalContainer] at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.unwrap(ScriptBytecodeAdapter.java:55)
[INFO] [talledLocalContainer] at org.codehaus.groovy.runtime.callsite.PogoMetaClassSite.callCurrent(PogoMetaClassSite.java:78)
[INFO] [talledLocalContainer] at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:49)
[INFO] [talledLocalContainer] at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:133)
[INFO] [talledLocalContainer] at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:137)
[INFO] [talledLocalContainer] at org.hippoecm.frontend.plugins.cms.dev.updater.UpdaterTemplate.<init>(updater:10)
[INFO] [talledLocalContainer] at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
[INFO] [talledLocalContainer] at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
[INFO] [talledLocalContainer] at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
[INFO] [talledLocalContainer] at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
[INFO] [talledLocalContainer] at java.lang.Class.newInstance(Class.java:374)
[INFO] [talledLocalContainer] at org.onehippo.repository.update.UpdaterInfo.<init>(UpdaterInfo.java:112)
[INFO] [talledLocalContainer] at org.onehippo.repository.update.UpdaterExecutor.<init>(UpdaterExecutor.java:76)
[INFO] [talledLocalContainer] at org.onehippo.repository.update.UpdaterExecutionModule$ExecuteUpdatersTask.executeUpdater(UpdaterExecutionModule.java:138)
[INFO] [talledLocalContainer] at org.onehippo.repository.update.UpdaterExecutionModule$ExecuteUpdatersTask.executeUpdatersInQueue(UpdaterExecutionModule.java:128)
[INFO] [talledLocalContainer] at org.onehippo.repository.update.UpdaterExecutionModule$ExecuteUpdatersTask.run(UpdaterExecutionModule.java:96)
[INFO] [talledLocalContainer] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
[INFO] [talledLocalContainer] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
[INFO] [talledLocalContainer] at java.lang.Thread.run(Thread.java:744)