Skip to content

Commit

Permalink
revised
Browse files Browse the repository at this point in the history
  • Loading branch information
cheniujh committed Aug 2, 2024
1 parent c331242 commit 124e250
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/pika_command.cc
Original file line number Diff line number Diff line change
Expand Up @@ -888,14 +888,15 @@ void Cmd::InternalProcessCommand(const HintKeys& hint_keys) {
}

void Cmd::DoCommand(const HintKeys& hint_keys) {
if (!cache_missed_in_rtc_
&& IsNeedCacheDo()
if (IsNeedCacheDo()
&& PIKA_CACHE_NONE != g_pika_conf->cache_mode()
&& db_->cache()->CacheStatus() == PIKA_CACHE_STATUS_OK) {
if (IsNeedReadCache()) {
if (!cache_missed_in_rtc_
&& IsNeedReadCache()) {
ReadCache();
}
if (is_read() && res().CacheMiss()) {
if (is_read()
&& (res().CacheMiss() || cache_missed_in_rtc_)) {
pstd::lock::MultiScopeRecordLock record_lock(db_->LockMgr(), current_key());
DoThroughDB();
if (IsNeedUpdateCache()) {
Expand Down

0 comments on commit 124e250

Please sign in to comment.