Problem loading class: org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed: /var/atlassian/application-data/jira/scripts/com/icg/UpdateSummary.groovy: 9: Invalid duplicate class definition of class UpdateSummary : The sources /var/atlassian/application-data/jira/scripts/com/icg/UpdateSummary.groovy and file:/var/atlassian/application-data/jira/scripts/com/icg/UpdateSummary.groovy each contain a class with the name UpdateSummary. @ line 9, column 1. class UpdateSummary extends AbstractIssueEventListener
Rename the file to some other name, dont keep class name and file name same ! will solve the problem.
It's generally because you have a class with code outside the class, so the compiler generates a class for the class in the file, and a script class with the same name, eg this will cause it if a file called Foo.groovy.
class Foo {} new Foo()
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I don't have anything new Class_Name() in the file. This is working without any issue on 6.2 & script listner 2.1.17 When I did upgrade on staging, this issue started. I have copied my groovy files from /opt/... to /var/... I was able to update those successfully if I do Jira restart. However if i try to do update script runner files next day, it throws same error.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I'm using below line- Logger log = Logger.getLogger(AddReporterAsWatcher.class) I hope this will not cause any issue. Do i need to delete files from old path?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
also if i keep those files under /var/atlassian/applicaiton-data/jira/scripts it does not throw mentioned. as of not those i are kept in /var/atalassian/applicaiton-data/jira/scripts/com/icg/
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
It depends what the package name in the class is... what is it? They should only be there once in the script root.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
more details>> restart jira >> add/update custom listner files >> no duplicate class error create a jira issue which meets condition in the class file now again >> add/update custom listner files >> duplicate class name error if i do restart then it does not throw error conditionally ticket has not been created after restart
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
> Do i need to delete files from old path? Probably, yes.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Do you have any links on the file or is it duplicated in some way? Has the file got the same class named twice?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.