Skip to content

Commit

Permalink
BUFFER::ADDED:: Generate a warning in logs when expiry couldn't be se…
Browse files Browse the repository at this point in the history
…t on a key
  • Loading branch information
frikilax committed Feb 4, 2022
1 parent b87ca17 commit af58aa4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion samples/fbuffer/BufferThread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,9 @@ bool BufferThread::Main() {

// Set an expiration on the redis key, to purge if threads/filters are stopped or configuration is modified
// The expiration MUST be over the interval period
this->_connector->REDISSetExpiry(redis_list, this->_interval + 60);
if (not this->_connector->REDISSetExpiry(redis_list, this->_interval + 60)) {
DARWIN_LOG_WARNING("BufferThread::Main:: Could not set an expiration on key '" + redis_list + "'");
}
}

return true;
Expand Down

0 comments on commit af58aa4

Please sign in to comment.