[DcpProducer] Refactor function name to indicate intent 72/57872/4
authorabhinavdangeti <abhinav@couchbase.com>
Thu, 17 Dec 2015 03:56:44 +0000 (19:56 -0800)
committerChiyoung Seo <chiyoung@couchbase.com>
Thu, 17 Dec 2015 05:10:41 +0000 (05:10 +0000)
unpauseIfSpace --> unpauseIfSpaceAvailable

Change-Id: Ifb4ec181e2228d819ab460bd03eccfefd75c48d6
Reviewed-on: http://review.couchbase.org/57872
Tested-by: buildbot <build@couchbase.com>
Reviewed-by: Chiyoung Seo <chiyoung@couchbase.com>
src/dcp-producer.cc
src/dcp-producer.h

index ceeb92a..1def385 100644 (file)
@@ -75,7 +75,7 @@ bool DcpProducer::BufferLog::pauseIfFull() {
     return false;
 }
 
-void DcpProducer::BufferLog::unpauseIfSpace() {
+void DcpProducer::BufferLog::unpauseIfSpaceAvailable() {
     ReaderLockHolder rlh(logLock);
     if (getState_UNLOCKED() != Full) {
         producer.notifyPaused(true);
@@ -692,7 +692,7 @@ void DcpProducer::setDisconnect(bool disconnect) {
 void DcpProducer::notifyStreamReady(uint16_t vbucket, bool schedule) {
     bool expected = false;
     if (vbReady[vbucket].compare_exchange_strong(expected, true)) {
-        log.unpauseIfSpace();
+        log.unpauseIfSpaceAvailable();
     }
 }
 
index cf76391..eb76d75 100644 (file)
@@ -151,7 +151,7 @@ public:
         /*
             Unpause the producer if there's space (or disabled).
         */
-        void unpauseIfSpace();
+        void unpauseIfSpaceAvailable();
 
     private: