Revival
Revival

Reputation: 71

java.lang.NoClassDefFoundError: com/atlassian/templaterenderer/TemplateRenderer while updating JIRA maven plugin

When I try to update jira plugin, the problem java.lang.NoClassDefFoundError: com/atlassian/templaterenderer/TemplateRenderer is occured. This plugin uses service which I put to

/opt/jira/jira/atlassian-jira/WEB-INF/classes and
/opt/jira/jira/atlassian-jira/WEB-INF/lib

directories.

So, I do next steps: 1) Remove myOldPlugin from Add-ons 2) Remove myOldService from Services in JIRA console 3) Remove myOldService.jar file from

/opt/jira/jira/atlassian-jira/WEB-INF/classes and
/opt/jira/jira/atlassian-jira/WEB-INF/lib

4) Install myNewPlugin to Add-ons

and got this error:

 [atlassian.plugin.loaders.ScanningPluginLoader] Because of the following exception:
    java.lang.NoClassDefFoundError: com/atlassian/templaterenderer/TemplateRenderer
    at java.lang.Class.getDeclaredConstructors0(Native Method)
    at java.lang.Class.privateGetDeclaredConstructors(Unknown Source)
    at java.lang.Class.getConstructors(Unknown Source)
    ...
    Caused by: java.lang.ClassNotFoundException: com.atlassian.templaterenderer.TemplateRenderer
    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1711)
    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1556)
    ... 95 more

This error is absent if I restart JIRA before installing myNewPlugin but this impossible for working process. I suppose this problem occured because of myService.jar cause before we have it we could restart plugin without any problems. So I need to update plugin and service without restarting JIRA

Please, help.

Upvotes: 1

Views: 647

Answers (1)

Lam Le
Lam Le

Reputation: 829

If you would like update your Jira plugin without restart Jira application, please

  • First update your Atlassian Plugin SDK to latest version here https://marketplace.atlassian.com/search?q=sdk (please find appropriate package for your OS) .
  • The next step is read documentation of Atlassian QuickReload, it is a silver bullet to make magic happen

Upvotes: 2

Related Questions