Capturing plugin installation/uninstallation events

We have seen plugins, which are great in terms of functionality but come with a big list of configuration steps. Much like a treadmill—great asset but very hard to assemble!

Is there a way we can handle these configurations—like creating custom fields, adding options, creating listeners, services and so on—automatically, when the plugin is installed? The answer is Yes.

Getting ready

Atlassian Spring Scanner is a set of libraries that make plugins faster to load and easier to develop. In this recipe, we will use Spring Scanner to write a listener class that also makes use of some Spring interfaces for lifecycle management.

Following are the steps to set up the environment:

  1. Create a skeleton plugin, ...

Get JIRA Development Cookbook - Third Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.