fanliang11 / surging

Surging is a micro-service engine that provides a lightweight, high-performance, modular RPC request pipeline. support Event-based Asynchronous Pattern and reactive programming ,The service engine supports http, TCP, WS,Grpc, Thrift,Mqtt, UDP, and DNS protocols. It uses ZooKeeper and Consul as a registry, and integrates it. Hash, random, polling, Fair Polling as a load balancing algorithm, built-in service governance to ensure reliable RPC communication, the engine contains Diagnostic, link tracking for protocol and middleware calls, and integration SkyWalking Distributed APM
MIT License
3.24k stars 924 forks source link

请问有没有方法在surging网关集成swagger? #114

Open sd797994 opened 6 years ago

sd797994 commented 6 years ago

我想问一下在分布式的RPC这种结构下有没有办法集成一个统一的swagger接口管理器方便业务开发人员使用? 以往的webapi单体应用可以很方便的采用swagger。如果是基于restapi的微服务节点,也可以比较方便的通过网关获取各节点生成的swagger.json实现统一管理。 但是基于dotnetty这种TCP结构的微服务实例似乎不太方便接入swagger,请问有没有办法比如在服务注册时产生一个类似于swaggerjson的服务接口。这样在网关处就可以比较方便的根据接口生成json文件来集成swagger?

fanliang11 commented 6 years ago

现在只能通过手动去维护swagger的json文件,计划会做个工具指定目录加载所有模块,生成json

sd797994 commented 6 years ago

好的,谢谢解答

movingsam commented 6 years ago

期待作者的工具! 毕竟对于团队来说 swagger可以减少很多沟通成本