Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
Community Members
Community Events
Community Groups

Jira seems to use a old (cached?) velocity template of my plugin


I am a jira plugin developer in our company. I wrote a new web panel viewable on the issue details page.
Btw the jar file of the plugin is created via buildforge, which adds a unique incremental build number to each release version in the pom and to the filename. (Just to let you know that I am sure I used the correct and same plugin version.)

Two builds ago I fixed an error in which I renamed/changed a single velocity parameter: "$urlPath" --> "${contextPath}". This parameter is used to provide correct image urls regardless of Jira build/install/environment paths.
On my local development instance everything works as expected - the urls are correctly resolved - the images are correctly shown.
We have a "playground", which is (kind of) a mirror of our production jira, where we can test everything under actual conditions. There the panel works as expected - the images are shown.

After confirming the functionality on our "playground", the plugin was installed on our production Jira. And there the panel was not shown correctly. I don't know why, but the old velocity parameter ("$urlPath") is still used (I know that because this variable is written as string to the image path, which can be viewed using firebug). So the images are not shown at all.

All plugins on playground- and production-jira are the same version. There is at least one difference:
Our production jiras version is 5.0.2 whereas on playground we already have 5.2.7 (because we plan upgrading jira and do compatiblity verification on playground first). (My local dev jira is 5.0.2 as well.)

Is there some kind of plugin cache or anything else which can cause this?

Thanks in advance.

Best regards,

1 answer

0 votes

did you restart jira?

you can try to do similar with this

From <jira-install>/atlassian-jira/WEB-INF/classes/
Change class.resource.loader.cache from true to false
Remove the comment sign (#) from #velocimacro.library.autoreload=true

As a result we cleared .osgi-plugins folder and restarted jira. That removed this issue for now - but does not prevent it from happening again. Also restarting our live production jira, each time there occurs an error with a plugin, is not a solution.
Is this a known issue for Jira 5.0.2 (or less), which was maybe fixed on a later release? (Just asking to maybe make our planned upgrade more urgent.)

I will talk with our server administration about your suggested properties. I will inform you on any progress of this. Does this properties cause any performance issues in large jira environments (50+ users, 11000+ issues in total, 2400+ issues not yet released)? I mean it is emphasized at your linked page, that this applies to development instances:

In a development instance, you can play with picking up velocity file changes without a restart. [...] Making this change in production will eventually lead to JIRA not serving pages along with the ran out of parsers error in the log file.

I'm just asking if you (or someone else) have personal experience with this.

Hi Carsten,

I had serveral issues while developing plugins. But it only happens to custom field types I created. Even restart (local instance, luckily it never happens to the live system) the local developer instance did not get it to work. Only after atlas-clean all worked fine again.

Suggest an answer

Log in or Sign up to answer

Atlassian Community Events