use of io.dingodb.server.coordinator.handler.StoreHeartbeatHandler in project dingo by dingodb.
the class CoordinatorStateMachine method initRpcServer.
private RpcServer initRpcServer() {
ExtSerializerSupports.init();
boolean isAutoBalanceSplit = context.coordOpts().getSchedule().isAutoBalanceSplit();
log.info("coordOpt, isAutoBalanceSplit: {}", isAutoBalanceSplit);
RpcServer rpcServer = createRaftRpcServer(context.endpoint(), raftExecutor(), cliExecutor());
rpcServer.registerProcessor(new GetLocationHandler());
rpcServer.registerProcessor(new GetClusterInfoHandler(context.rowStoreMetaAdaptor()));
rpcServer.registerProcessor(new GetStoreInfoHandler(context.rowStoreMetaAdaptor()));
rpcServer.registerProcessor(new GetStoreIdHandler(context.rowStoreMetaAdaptor()));
rpcServer.registerProcessor(new RegionHeartbeatHandler(context.rowStoreMetaAdaptor(), isAutoBalanceSplit));
rpcServer.registerProcessor(new SetStoreHandler(context.rowStoreMetaAdaptor()));
rpcServer.registerProcessor(new StoreHeartbeatHandler(context.rowStoreMetaAdaptor()));
log.info("Start coordinator raft rpc server, result: {}.", rpcServer.init(null));
context.rpcServer(rpcServer);
return rpcServer;
}
Aggregations