Search in sources :

Example 1 with ClusterId

use of org.graylog2.plugin.cluster.ClusterId in project graylog2-server by Graylog2.

the class ClusterIdGeneratorPeriodical method doRun.

@Override
public void doRun() {
    if (clusterConfigService.get(ClusterId.class) == null) {
        ClusterId clusterId = ClusterId.create(UUID.randomUUID().toString());
        clusterConfigService.write(clusterId);
        LOG.debug("Generated cluster ID {}", clusterId.clusterId());
    }
}
Also used : ClusterId(org.graylog2.plugin.cluster.ClusterId)

Aggregations

ClusterId (org.graylog2.plugin.cluster.ClusterId)1