One plugin enabled event per cluster in Jira Data Center

Plugin enabled event is getting fired in each node in the cluster, is there any similar event available to be fired only once in the cluster when the plugin gets installed?

I would like to prevent re-processing the same event on each node.

Please suggest any help or out of the box events available for Jira Data Center environment.

Not really… You’d need to listen for that event and then have to use something like the Cluster Locks located at to basically have the first one that receives the event to do stuff. Note: The plugin at that point might not be active everywhere…

If a node comes on later on - it too will trigger the PluginEnabled event so you’d have to be guard against that as well…

That said - can you go into what you’re trying to do? There might be a better way…

Thanks Daniel,
I would like to process the event only once and avoid processing in other nodes. I think Cluster Locks will help in processing events synchronously in all nodes, we have to take care of stop processing the event in other nodes after processing in the first node by maintaining the state somewhere in the database or any other persistent storage.
The actual requirement here, we would like to capture install event analytics when the plugin gets installed. In the Data Center, duplicate events get captured as the PluginEnabledEvent is getting captured in all nodes in the DC cluster, but it has to be captured only once per DC instance.