Search in sources :

Example 11 with BBoxDBConfiguration

use of org.bboxdb.misc.BBoxDBConfiguration in project bboxdb by jnidzwetzki.

the class ZookeeperClientFactory method getLocalInstanceName.

/**
 * Get the name of the local instance
 * @param bboxdbConfiguration
 * @return
 */
public static synchronized BBoxDBInstance getLocalInstanceName() {
    if (localInstanceName == null) {
        final BBoxDBConfiguration configuration = BBoxDBConfigurationManager.getConfiguration();
        final String localIp = configuration.getLocalip();
        final int localPort = configuration.getNetworkListenPort();
        localInstanceName = new BBoxDBInstance(localIp, localPort, Const.VERSION);
    }
    return localInstanceName;
}
Also used : BBoxDBConfiguration(org.bboxdb.misc.BBoxDBConfiguration) BBoxDBInstance(org.bboxdb.distribution.membership.BBoxDBInstance)

Aggregations

BBoxDBConfiguration (org.bboxdb.misc.BBoxDBConfiguration)11 File (java.io.File)3 BBoxDBInstance (org.bboxdb.distribution.membership.BBoxDBInstance)2 ZookeeperClient (org.bboxdb.distribution.zookeeper.ZookeeperClient)2 Test (org.junit.Test)2 HTTPServer (io.prometheus.client.exporter.HTTPServer)1 IOException (java.io.IOException)1 ZookeeperInstanceRegisterer (org.bboxdb.distribution.zookeeper.ZookeeperInstanceRegisterer)1 Tuple (org.bboxdb.storage.entity.Tuple)1 TupleStoreConfiguration (org.bboxdb.storage.entity.TupleStoreConfiguration)1 SSTableCheckpointRunnable (org.bboxdb.storage.sstable.SSTableCheckpointRunnable)1 SSTableWriter (org.bboxdb.storage.sstable.SSTableWriter)1 SSTableFacade (org.bboxdb.storage.sstable.reader.SSTableFacade)1 TupleStoreManager (org.bboxdb.storage.tuplestore.manager.TupleStoreManager)1 TupleStoreManagerRegistry (org.bboxdb.storage.tuplestore.manager.TupleStoreManagerRegistry)1