Netty 4.0在具有多个协议的多个端口上? [英] Netty 4.0 on multiple ports with multiple protocols?

查看:893
本文介绍了Netty 4.0在具有多个协议的多个端口上?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在寻找一个服务器示例,该示例将在端口80中组合一个http处理程序和在同一jar中另一个端口上的protobuf处理程序. 谢谢!

I'm looking for a server example that would combine a http handler on port 80 and a protobuf handler on another port in the same jar. Thanks!

推荐答案

我不知道您到底在寻找什么.只需创建两个不同的ServerBootstrap实例,对其进行配置并调用bind(..)就可以了.

I don't know what exactly you are looking for. Its just about creating two different ServerBootstrap instances, configure them and call bind(..) thats it.

这篇关于Netty 4.0在具有多个协议的多个端口上?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆