Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public GreeterServer(int port) throws IOException {
- this(ServerBuilder.forPort(port), port);
- }
- public GreeterServer(ServerBuilder<?> serverBuilder, int port) {
- this.port = port;
- server = serverBuilder.addService(new GreeterImpl()).build();
- }
- public void start() throws IOException {
- server.start();
- logger.info("Server started, listening on " + port);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement