Search in sources :

Example 1 with RpcServer

use of com.alipay.remoting.rpc.RpcServer in project mmqtt by MrHKing.

the class RpcService method init.

@PostConstruct
public void init() {
    rpcServer = new RpcServer(this.memberManager.getSelf().getPort() + 10);
    rpcServer.registerUserProcessor(new PublishRequestProcessor(this.memberManager.getSelf(), subscribeStoreService, sessionStoreService, dupPublishMessageStoreService));
    rpcServer.registerUserProcessor(new RejectClientProcessor(sessionStoreService));
    rpcServer.startup();
}
Also used : RpcServer(com.alipay.remoting.rpc.RpcServer) PostConstruct(javax.annotation.PostConstruct)

Example 2 with RpcServer

use of com.alipay.remoting.rpc.RpcServer in project sofa-rpc by sofastack.

the class BoltServer method initRemotingServer.

protected RemotingServer initRemotingServer() {
    // 绑定到端口
    RemotingServer remotingServer = new RpcServer(serverConfig.getBoundHost(), serverConfig.getPort());
    remotingServer.registerUserProcessor(boltServerProcessor);
    return remotingServer;
}
Also used : RpcServer(com.alipay.remoting.rpc.RpcServer) RemotingServer(com.alipay.remoting.RemotingServer)

Aggregations

RpcServer (com.alipay.remoting.rpc.RpcServer)2 RemotingServer (com.alipay.remoting.RemotingServer)1 PostConstruct (javax.annotation.PostConstruct)1