Kevin Wan

Results 336 comments of Kevin Wan
trafficstars

有接口,可以自行扩展哈

我们可以约个时间沟通一下?

> # 对接策略 > ## 服务注册 > 提供注册函数,实现go-zero的函数接口,自动将服务和节点注册到北极星 type ( // RegisterFn defines the method to register a server. RegisterFn func(*grpc.Server) ) > > ## 服务发现 > 提供resovler的实现,对接北极星polaris-go的getallinstances,获取服务下全部实例信息 > >...

> ## 限流 > 限流能力的对接比较麻烦,主要存在以下2个问题: > > * gozero当前封装了interceptor,无法传入外部的interceptor,所以没法再服务端进行拦截 > * gozero提供了Breaker接口,但是Breaker并没有开放定制能力,没法通过外部定制来插入 我是有计划暴露中间件定制能力的,但是polaris的限流有何优势呢?

现在的breaker只是自适应根据后面调用返回来熔断的,其实我觉得可以直接添加interceptor就好了,因为内置breaker可以充当外层保护,只有有问题时才会触发。 我们可以讨论讨论。

to `[]interface{}` and `map[interface{}]interface{}`?

支持不了,因为Go还不支持`template method`。