Skip to content

Commit

Permalink
update by review
Browse files Browse the repository at this point in the history
  • Loading branch information
hycdong committed Apr 7, 2020
1 parent 2de9d3b commit bdaf2b5
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/server/pegasus_server_impl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -975,7 +975,6 @@ void pegasus_server_impl::on_multi_get(const ::dsn::apps::multi_get_request &req
} else { // condition: !request.sort_keys.empty()
bool error_occurred = false;
rocksdb::Status final_status;
int32_t multiget_count = 0;
bool exceed_limit = false;
std::vector<::dsn::blob> keys_holder;
std::vector<rocksdb::Slice> keys;
Expand Down Expand Up @@ -1012,7 +1011,6 @@ void pegasus_server_impl::on_multi_get(const ::dsn::apps::multi_get_request &req
}
// check ttl
if (status.ok()) {
multiget_count++;
uint32_t expire_ts = pegasus_extract_expire_ts(_pegasus_data_version, value);
if (expire_ts > 0 && expire_ts <= epoch_now) {
expire_count++;
Expand All @@ -1027,7 +1025,7 @@ void pegasus_server_impl::on_multi_get(const ::dsn::apps::multi_get_request &req
// extract value
if (status.ok()) {
// check if exceed limit
if (multiget_count > max_iteration_count || size > max_iteration_size) {
if (count >= max_kv_count || size >= max_kv_size) {
exceed_limit = true;
break;
}
Expand Down

0 comments on commit bdaf2b5

Please sign in to comment.