Package com.atlassian.confluence.cluster
Interface ClusterConfigurationHelper
-
- All Known Subinterfaces:
ClusterConfigurationHelperInternal
- All Known Implementing Classes:
DefaultClusterConfigurationHelper
,NonClusterConfigurationHelper
public interface ClusterConfigurationHelper
A facade for interacting with the clustering subsystem
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
bootstrapCluster(BootstrapDatabaseAccessor.BootstrapDatabaseData bootstrapDatabaseData)
Checks whether clustering is enabled, and bootstraps the cluster manager with an appropriate configurationvoid
createCluster(String clusterName, File clusterHome, String networkInterfaceName, ClusterJoinConfig joinConfig)
Creates a new cluster with the given name, on the specified network interface, as long as the given cluster does not exist.List<NetworkInterface>
getClusterableInterfaces()
Return a list of interfaces suitable for clustered communication.boolean
isClusteredInstance()
boolean
isClusterHomeConfigured()
Optional<ClusterJoinConfig>
joinConfig()
Returns the configured join config if setup has progressed that far.Optional<File>
sharedHome()
Return the shared home directory if one has been configured.
-
-
-
Method Detail
-
isClusteredInstance
boolean isClusteredInstance()
- Returns:
- true if the application is currently configured to be part of a cluster, otherwise false.
-
isClusterHomeConfigured
boolean isClusterHomeConfigured()
- Returns:
- true if the application has the confluence.cluster.home property set, otherwise false.
-
createCluster
void createCluster(String clusterName, File clusterHome, String networkInterfaceName, ClusterJoinConfig joinConfig) throws ClusterException
Creates a new cluster with the given name, on the specified network interface, as long as the given cluster does not exist.- Throws:
ClusterException
- if an error setting up the cluster.LicenseException
- if there is an error while checking the license
-
bootstrapCluster
void bootstrapCluster(BootstrapDatabaseAccessor.BootstrapDatabaseData bootstrapDatabaseData) throws ClusterException
Checks whether clustering is enabled, and bootstraps the cluster manager with an appropriate configuration- Parameters:
bootstrapDatabaseData
- contains the build number and cluster upgrade state information to decide whether this node can join- Throws:
ClusterException
- if there was an error configuring the cluster manager, or if the licensed nodes were exceeded by joining the cluster.
-
getClusterableInterfaces
List<NetworkInterface> getClusterableInterfaces()
Return a list of interfaces suitable for clustered communication. The list is ordered for suitable rendering in a UI.- Returns:
- List of
NetworkInterface
objects
-
sharedHome
Optional<File> sharedHome()
Return the shared home directory if one has been configured.- Returns:
- shared home directory
- Since:
- 7.0.1
-
joinConfig
Optional<ClusterJoinConfig> joinConfig()
Returns the configured join config if setup has progressed that far.- Returns:
- Join configuration
- Since:
- 7.0.1
-
-