Search in sources :

Example 1 with ConnectionManager

use of com.tencent.polaris.plugins.connector.grpc.ConnectionManager in project polaris-java by polarismesh.

the class PolarisConfigFileConnector method init.

@Override
public void init(InitContext ctx) throws PolarisException {
    CompletableFuture<String> readyFuture = new CompletableFuture<>();
    Map<ClusterType, CompletableFuture<String>> futures = new HashMap<>();
    futures.put(ClusterType.SERVICE_DISCOVER_CLUSTER, readyFuture);
    connectionManager = new ConnectionManager(ctx, null, futures);
}
Also used : CompletableFuture(java.util.concurrent.CompletableFuture) ConnectionManager(com.tencent.polaris.plugins.connector.grpc.ConnectionManager) HashMap(java.util.HashMap) ClusterType(com.tencent.polaris.api.config.global.ClusterType)

Aggregations

ClusterType (com.tencent.polaris.api.config.global.ClusterType)1 ConnectionManager (com.tencent.polaris.plugins.connector.grpc.ConnectionManager)1 HashMap (java.util.HashMap)1 CompletableFuture (java.util.concurrent.CompletableFuture)1