-
Notifications
You must be signed in to change notification settings - Fork 8.1k
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
Fixes #9: Use named thread factory for identification #10
Conversation
Signed-off-by: Eric Zhao <[email protected]>
Codecov Report
@@ Coverage Diff @@
## master #10 +/- ##
===========================================
+ Coverage 46.32% 46.4% +0.08%
- Complexity 540 542 +2
===========================================
Files 105 105
Lines 3655 3655
Branches 517 517
===========================================
+ Hits 1693 1696 +3
+ Misses 1756 1754 -2
+ Partials 206 205 -1
Continue to review full report at Codecov.
|
@@ -54,7 +55,8 @@ | |||
public class FlowRuleManager { | |||
|
|||
private static final Map<String, List<FlowRule>> flowRules = new ConcurrentHashMap<String, List<FlowRule>>(); | |||
private final static ScheduledExecutorService scheduler = Executors.newScheduledThreadPool(1); | |||
private final static ScheduledExecutorService scheduler = Executors.newScheduledThreadPool(1, | |||
new NamedThreadFactory("sentinel-flow-metrics-record-task", true)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should change "sentinel-flow-metrics-record-task" to "sentinel-metrics-record-task"
Signed-off-by: Eric Zhao <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
* Use named thread factory with all thread pools for identification Signed-off-by: Eric Zhao <[email protected]>
) * Use named thread factory with all thread pools for identification Signed-off-by: Eric Zhao <[email protected]>
Signed-off-by: Eric Zhao [email protected]
Describe what this PR does / why we need it
Use named thread factory with all thread pools for identification.
Does this pull request fix one issue?
Fixes #9