Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

More plentiful "snapshot" value in circuit breaker observer functions #183

Open
NineSunRD opened this issue Jul 13, 2020 · 4 comments
Open
Labels
area/circuit-breaking Issues or PRs related to circuit breaking

Comments

@NineSunRD
Copy link
Contributor

Issue Description

Type: feature request

Describe what feature you want

Snapshot is interface,I think it is for more plentiful data,but we only pass a simple param when we use it,I think we can pass more information,such as cur state,and we can get more information in the listener.
image

Additional context

Add any other context or screenshots about the feature request here.

@sczyh30
Copy link
Member

sczyh30 commented Jul 14, 2020

Hi, we've already carried previous state, triggered rule and "snapshot" value (if needed) in the observer functions. You may refer to the example: https://github.com/alibaba/sentinel-golang/blob/master/example/circuitbreaker/circuit_breaker_example.go

@sczyh30 sczyh30 added the area/circuit-breaking Issues or PRs related to circuit breaking label Jul 14, 2020
@NineSunRD
Copy link
Contributor Author

Thanks very much

the cur state that I mean is not the open state or half open state, I mean the cur metrics, such as cur request number or cur rt. because I want to do some alert with cur info when system is breaking

on the other hand,I have reviewed the code in core/log/metric , because we have our own monitor system,I suggest the metric need easier to access to other systems

@sczyh30
Copy link
Member

sczyh30 commented Jul 22, 2020

the cur state that I mean is not the open state or half open state, I mean the cur metrics, such as cur request number or cur rt. because I want to do some alert with cur info when system is breaking

Currently only the triggered ratio was provided. We may improve the "snapshot" value later so that it could provide more useful metrics.

on the other hand,I have reviewed the code in core/log/metric , because we have our own monitor system,I suggest the metric need easier to access to other systems

We're working on it. We may discuss it in #70

@sczyh30 sczyh30 changed the title suggest more plentiful snapshot More plentiful "snapshot" value in circuit breaker observer functions Jul 22, 2020
@NineSunRD
Copy link
Contributor Author

Thanks

@louyuting louyuting added this to the 1.0.0 milestone Sep 24, 2020
@sczyh30 sczyh30 removed this from the 1.0.0 milestone Nov 10, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/circuit-breaking Issues or PRs related to circuit breaking
Projects
None yet
Development

No branches or pull requests

3 participants