INNER CODE UNIT · Java

main

TencentFemas/femas · femas-admin/src/main/java/com/tencent/tsf/femas/FemasApplication.java:27

    public static void main(String[] args) {
        SpringApplication.run(FemasApplication.class, args);
        try {
            startRpcServer();
        } catch (IOException e) {
            log.error("start grpc fail",e);
        }
    }

    private static void startRpcServer() throws IOException {
        int grpcPort = GrpcHepler.getGrpcListenPort();
        NettyServerBuilder.forPort(grpcPort)
                .addService(new GrpcLongPollingEndpoint())
                .build()
                .start();
        log.info("start grpc on port:{}",grpcPort);
    }
}

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…