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

Hello,

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,
Carsten

1 answer

did you restart jira?

you can try to do similar with this

https://confluence.atlassian.com/display/JIRA/Customising+Email+Content

From <jira-install>/atlassian-jira/WEB-INF/classes/velocity.properties:
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
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Published May 14, 2018 in Agile

Marketplace Technical Collection Pages

You might have noticed something new on Marketplace in the last several months which was the addition of our new collection pages. We heard feedback that it can be hard to browse apps in Marketplace ...

75 views 0 4
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you