Class NodeStateCheckerService
java.lang.Object
com.atlassian.jira.service.AbstractService
com.atlassian.jira.service.services.cluster.NodeStateCheckerService
- All Implemented Interfaces:
ObjectConfigurable
,JiraService
,Runnable
Scheduled task that checks the state of this node in the cluster.
If the node's state in the database is changed to PASSIVE
, it is interpreted
as a request for the node to passivate itself.
- Since:
- v6.2
-
Field Summary
Fields inherited from class com.atlassian.jira.service.AbstractService
log, name, SERVICE_EVENT
Fields inherited from interface com.atlassian.jira.service.JiraService
NAME_COMPARATOR
-
Constructor Summary
ConstructorDescriptionNodeStateCheckerService
(NodeStateManager nodeStateManager, OfBizClusterNodeStore clusterNodeStore, ClusterNodes clusterNodes) -
Method Summary
Modifier and TypeMethodDescriptionRetrieves an object configuration object with properties that can be setvoid
init
(com.opensymphony.module.propertyset.PropertySet properties) Initialise the service.void
run()
This method must be implemented in a subclass, and performs the functionality that the service performs.Methods inherited from class com.atlassian.jira.service.AbstractService
destroy, getDefaultProperty, getDescription, getKey, getLongProperty, getName, getObjectConfiguration, getProperties, getProperty, getTextProperty, hasProperty, isInternal, isUnique, setName
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.atlassian.jira.service.JiraService
init
-
Constructor Details
-
NodeStateCheckerService
public NodeStateCheckerService(NodeStateManager nodeStateManager, OfBizClusterNodeStore clusterNodeStore, ClusterNodes clusterNodes)
-
-
Method Details
-
init
public void init(com.opensymphony.module.propertyset.PropertySet properties) throws ObjectConfigurationException Description copied from interface:JiraService
Initialise the service. This method is guaranteed to be called before the first call to run().As the parameters are gained from the user's interaction with the website, it is not guaranteed to be called with the correct, or indeed with any parameters.
init() may be called multiple times during the services lifetime.
- Specified by:
init
in interfaceJiraService
- Overrides:
init
in classAbstractService
- Parameters:
properties
- initialisation parameters- Throws:
ObjectConfigurationException
- in case of an error with initialisation parameters- See Also:
-
run
public void run()Description copied from class:AbstractService
This method must be implemented in a subclass, and performs the functionality that the service performs. This method is called after the duration specified through the administration web interface.- Specified by:
run
in interfaceJiraService
- Specified by:
run
in interfaceRunnable
- Specified by:
run
in classAbstractService
- See Also:
-
getObjectConfiguration
Description copied from interface:ObjectConfigurable
Retrieves an object configuration object with properties that can be set- Returns:
- ObjectConfiguration object
- Throws:
ObjectConfigurationException
-