Dear community
I need to set a cron job service that would send heartbeats to opsgenie to ensure that every node is healthy.
We have a Jira Data Center setup with multiple node.
Based on my analysis of scheduling groovy scripts via the scriptrunner jobs I see that the scriprunner service runs only one node per schedule. Is it possible to configure it e.q for all nodes or pin it to a specific one.reading through the developer documentation of Atlassian I've found a way doing it with an custom plugin (https://developer.atlassian.com/server/jira/platform/developing-for-high-availability-and-clustering),but the effort would be far too great for this use case.
Hi,
Looks better to check from outside healthy of nodes. Instead from platform
https://developer.atlassian.com/server/jira/platform/developing-for-high-availability-and-clustering/
@eli.cohen
I would like to ask if you have scriptrunner script that can check the nodes status. Can you share with me.
Thanks
Hi @Rodolfo So
The following code snippet can give you node status and other details as well.
import com.atlassian.jira.cluster.ClusterManagerimport com.atlassian.jira.component.ComponentAccessordef componentAccessor = ComponentAccessor.newInstance()def clusterManager = componentAccessor.getOSGiComponentInstanceOfType(ClusterManager.class)Set clusterInfo = clusterManager.getAllNodes()clusterInfo.each { it -> log. info it.getState().getI18nKey()}
You can run this script as a job and send output to a file or send this information using email as well.
Rahul
It looks like you're new here. Sign in or register to get started.