Hi, Good Day!
We have developed a “custom Jira plugin” in which we encapsulate all the groovy scripts code, listeners, behaviours, scripted fields etc and deployed that our “custom internal Jira plugin” in our Jira instances. And we are calling the custom listeners created inside internal plugin from the The “Adaptavist ScriptRunner Plugin”.
For example: “scripts/listeners/MasterListener.groovy”(attached the screenshot ScriptrunnerTicketPc1.jpg for reference).
In our custom Jira plugin, we have created a MasterListener.groovy script. Below is our Master Listener execution architecture:
1. Master Listener is associated with 6 events Issue Created, Issue Updated, Issue Resolved, Issue Closed, IssueLinkCreatedEvent, IssueLinkDeletedEvent
2. Once the listener is triggered on any of the events, it checks if issue status is updated and to which status issue is moved to → call FireEventUtils to trigger TriggerCalculationEvent
3. FireEventUtils - Create a new Thread - on that thread it publishes the TriggerCalculationEvent
4. TriggerCalculationListener(deployed on scriptrunner listener section with TriggerCalculationEvent) - calls CalculationUtil
5. CalculationUtil - calculates the custom date field value and populates the respective custom field
From few weeks back, after we updated Jira to 10.3.8 version, we intermittently started observing below error in the logs and MasterListener was failing to execute:
2025-06-20T01:08:15,543 ERROR [events.AbstractScriptListener]: ************************************************************************************* 2025-06-20T01:08:15,543 ERROR [events.AbstractScriptListener]: Script function failed on event: com.atlassian.jira.event.issue.IssueEvent, file: null java.lang.NoClassDefFoundError: org/apache/log4j/Logger at scripts.listeners.MasterListener.run(MasterListener.groovy:43) ~[?:?] Caused by: java.lang.ClassNotFoundException: org.apache.log4j.Logger not found by com.cgi.proaction.scriptrunner.proaction-scriptrunner-plugin [227] … 1 more
We have raised a support ticket with “Adaptavist ScriptRunner Plugin” vendor, they have suggested to:
- Upgrade “Adaptavist ScriptRunner Plugin” version compatible with our Jira instance version - We did this, but it didn’t fix our issue.
- Clear plugin cache - We did this, but it didn’t fix our issue.
- Comment fireEventUtils.fireEvent method which is invoked from MasterListener - We did this, but it didn’t fix our issue.
Initially, we thought it would be issue with logger class and we tried:
- To add log4j dependency - We did this, but it didn’t fix our issue.
- To comment all the log imports and log statements associated with MasterListener and associated util classes - Which is starting to give new errors in the logs that is the plugin is not able to resolve “Atlassian classes” as shown below:
2025-08-12T04:17:11,212 ERROR [events.AbstractScriptListener]: *************************************************************************************
2025-08-12T04:17:11,212 ERROR [events.AbstractScriptListener]: Script function failed on event: com.atlassian.jira.event.issue.IssueEvent, file: null
java.lang.NoClassDefFoundError: com/atlassian/jira/event/type/EventTypeManager
at com.onresolve.scriptrunner.runner.classloading.MultiParentClassLoader.findClass(MultiParentClassLoader.groovy:26) ~[?:?]
at scripts.listeners.MasterListener.run(MasterListener.groovy:43) ~[?:?]
Caused by: java.lang.ClassNotFoundException: com.atlassian.jira.event.type.EventTypeManager not found by com.cgi.proaction.scriptrunner.proaction-scriptrunner-plugin [323]
at org.apache.felix.framework.BundleWiringImpl.findClassOrResourceByDelegation(BundleWiringImpl.java:1591) ~[org.apache.felix.framework-7.0.5.jar:?]
at org.apache.felix.framework.BundleWiringImpl.access$300(BundleWiringImpl.java:79) ~[org.apache.felix.framework-7.0.5.jar:?]
at org.apache.felix.framework.BundleWiringImpl$BundleClassLoader.loadClass(BundleWiringImpl.java:1976) ~[org.apache.felix.framework-7.0.5.jar:?]
… 2 more
Can anyone please help us understand why custom plugin is not able to resolve the Atlassian classes and any suggestions which would help us fix this issue.
Thanks & regards,
Preethi H R
