Comments (4)
2022/10/21 17:58:27 [errot] send request to 127.0.0.1:28082 fail : Get "http://127.0.0.1:28082/echo": dial tcp 127.0.0.1:28082: connect: connection refused
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x60 pc=0xa53617]
goroutine 84 [running]:
github.com/polarismesh/polaris-go/plugin/statreporter/prometheus.(*PrometheusHandler).handleCircuitBreakGauge(0xc0000a2410, 0x4044e6?, 0xc000394330)
/root/workspace/go/src/polaris-go/plugin/statreporter/prometheus/prometheus_handler.go:228 +0x77
github.com/polarismesh/polaris-go/plugin/statreporter/prometheus.(*PrometheusHandler).ReportStat(0xa0?, 0xc?, {0xd00750?, 0xc000394330?})
/root/workspace/go/src/polaris-go/plugin/statreporter/prometheus/prometheus_handler.go:139 +0x5a
github.com/polarismesh/polaris-go/plugin/statreporter/prometheus.(*PrometheusReporter).ReportStat(0x750000c0000218b8?, 0x0?, {0xd00750?, 0xc000394330?})
/root/workspace/go/src/polaris-go/plugin/statreporter/prometheus/prometheus_reporter.go:84 +0x27
github.com/polarismesh/polaris-go/pkg/flow.(*Engine).SyncReportStat(0xc0000d2ea0, 0x4, {0xd00750, 0xc000394330})
/root/workspace/go/src/polaris-go/pkg/flow/impl.go:344 +0x171
github.com/polarismesh/polaris-go/plugin/localregistry/inmemory.(*LocalCache).UpdateInstances(0xc00040a000, 0xc000286040)
/root/workspace/go/src/polaris-go/plugin/localregistry/inmemory/inmemory.go:577 +0x7a2
github.com/polarismesh/polaris-go/pkg/plugin/localregistry.(*Proxy).UpdateInstances(0xc0003b6448?, 0xc000021c60?)
/root/workspace/go/src/polaris-go/pkg/plugin/localregistry/proxy.go:48 +0x24
github.com/polarismesh/polaris-go/pkg/flow/cbcheck.(*CircuitBreakCallBack).doCircuitBreakForService(0xc000438600, {{0xc0003b6448?, 0x40e6be?}, {0xc000036450?, 0xffffffffffffff04?}}, {0x0, 0x0}, {0xd02e88?, 0xc0001c4a80}, {0xbec320, ...})
/root/workspace/go/src/polaris-go/pkg/flow/cbcheck/ticker.go:135 +0x790
github.com/polarismesh/polaris-go/pkg/flow/cbcheck.(*CircuitBreakRealTimeCallBack).Process(0xc0005480a0)
/root/workspace/go/src/polaris-go/pkg/flow/cbcheck/realtime.go:68 +0x136
github.com/polarismesh/polaris-go/pkg/flow/schedule.(*taskRoutine).runTakePriority(0xc0000a28c0)
/root/workspace/go/src/polaris-go/pkg/flow/schedule/routines.go:139 +0x202
created by github.com/polarismesh/polaris-go/pkg/flow/schedule.(*taskRoutine).start
/root/workspace/go/src/polaris-go/pkg/flow/schedule/routines.go:106 +0x178
from polaris-go.
我修复下
from polaris-go.
handleCircuitBreakGauge
是什么原因导致panic?
from polaris-go.
err := g.engine.SyncReportStat(model.CircuitBreakStat,
&model.CircuitBreakGauge{ChangeInstance: updateInstance, CBStatus: nextCBStatus})
这里原先的逻辑,塞入的是 preCBStatus,会导致 nil panic
from polaris-go.
Related Issues (20)
- 一个应用只能有一个配置文件,polaris.NewConfigAPI()也无法重新连接一个实例
- 刚发布的1.5版本是不是有错误? HOT 2
- polaris-go 与 grpc-go-polaris 引用的 specification 版本不一致 HOT 6
- 拆分ratelimit相关pb到specification
- polaris.yaml的设计有点糟糕,线上环境多是通过统一配置文件或者环境变量来控制的参数,因为对接北极星硬加一个配置文件来使用,反而增加了不少成本 HOT 4
- 希望实现配置操作等API,对标Java的SDK
- 限流:支持自适应限流
- 就近路由功能未能跑通 HOT 1
- 1.5.3版本SDK在监听加密配置文件变更时,概率发生panic
- 1.5.3版本SDK在使用配置中心时,本地没有生成缓存文件。
- 关闭持久化功能后,还是会自动创建 polaris/backup 文件夹
- verifying github.com/polarismesh/[email protected]: checksum mismatch
- polaris.ConfigAPI 不能并行监听多个配置文件
- 限流方式需要增加“并发限流”的模式
- 新版本熔断器在开->半开时会panic
- GetOneInstance 方法不会返回半开路状态的实例
- 限流方法GetQuota,申请资源失败时,有可能存在已申请资源未释放。 HOT 1
- 熔断器由half-open变为close后,无法再变为open
- 服务端开启客户端严格鉴权后,客户端服务发现出错
- 如何设置路由
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from polaris-go.