I played with adding Groovy event listener to SyncFinishedEvent. This event fires when product catalog is being fully synchronized or when you have synchronized a single product from HMC/Backoffice.
I have created Script, saved it to DB, created instance of listener, registered it by such command
scriptingEventService.registerScriptingEventListener('model://myEventListenerScript')
It worked as it should, it catched event as well
Than I unregistered event by such command
scriptingEventService.unregisterScriptingEventListener('model://myEventListenerScript')
It stopped work. Than after system update and after actions of other developer on server I found that Script event listener is running.
I unregistered it as I did it before
I removed Script from DB (from backoffice)
I checked that scriptingEventService.getRegisteredWrappers() returned empty result
I checked that in this result my custom event listener is also not present eventService.eventListeners
After all of this it is still running.
Question: 1. Where my groovy event listener can remain? 2. Or how to stop it?
Thanks in advance