acelyc111 commented on a change in pull request #679:
URL: https://github.com/apache/incubator-pegasus/pull/679#discussion_r554769325
##########
File path: src/server/hotspot_partition_calculator.cpp
##########
@@ -41,17 +41,20 @@ DSN_DEFINE_bool("pegasus.collector",
enable_detect_hotkey,
false,
"auto detect hot key in the hot paritition");
+DSN_TAG_VARIABLE(enable_detect_hotkey, FT_MUTABLE);
DSN_DEFINE_int32("pegasus.collector",
hot_partition_threshold,
3,
"threshold of hotspot partition value, if app.stat.hotspots
>= "
"FLAGS_hotpartition_threshold, this partition is a hot
partition");
+DSN_TAG_VARIABLE(hot_partition_threshold, FT_MUTABLE);
Review comment:
```
for (int index = 0; index < _hot_points.size(); index++) {
if (_hot_points[index][data_type].get()->get_value() >=
FLAGS_hot_partition_threshold) {
if (++_hotpartition_counter[index][data_type] >=
FLAGS_occurrence_threshold) {
```
Better to move hot_partition_threshold and occurrence_threshold out of loop.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]