diff options
author | Mark Benvenuto <mark.benvenuto@mongodb.com> | 2014-05-19 12:46:52 -0400 |
---|---|---|
committer | Mark Benvenuto <mark.benvenuto@mongodb.com> | 2014-05-19 14:43:05 -0400 |
commit | f2bfd36a6f3eb7e7e2587268be3cc12636703d42 (patch) | |
tree | 6436772fbceb28f07bbfaee528d700159beb0cec /src/mongo/db/repl/master_slave.h | |
parent | c10e8282a7af38f8512e911a14889e14df8a2c6a (diff) | |
download | mongo-f2bfd36a6f3eb7e7e2587268be3cc12636703d42.tar.gz |
SERVER-13256: Remove pch - qualify std in headers
Diffstat (limited to 'src/mongo/db/repl/master_slave.h')
-rw-r--r-- | src/mongo/db/repl/master_slave.h | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/src/mongo/db/repl/master_slave.h b/src/mongo/db/repl/master_slave.h index dbcd0953fb5..740a767cc4e 100644 --- a/src/mongo/db/repl/master_slave.h +++ b/src/mongo/db/repl/master_slave.h @@ -51,7 +51,7 @@ namespace mongo { extern volatile int relinquishSyncingSome; extern volatile int syncing; - // Global variable that contains a string telling why master/slave halted + // Global variable that contains a std::string telling why master/slave halted extern const char *replAllDead; /* A replication exception */ @@ -92,18 +92,18 @@ namespace mongo { back to read more transactions. (Imagine a scenario of slave startup where we try to clone 100 databases in one pass.) */ - set<string> addDbNextPass; + std::set<std::string> addDbNextPass; - set<string> incompleteCloneDbs; + std::set<std::string> incompleteCloneDbs; BSONObj _me; ReplSource(); - void resyncDrop( OperationContext* txn, const string& db ); + void resyncDrop( OperationContext* txn, const std::string& db ); // call without the db mutex void syncToTailOfRemoteLog(); - string ns() const { return string( "local.oplog.$" ) + sourceName(); } + std::string ns() const { return std::string( "local.oplog.$" ) + sourceName(); } unsigned _sleepAdviceTime; /** @@ -124,17 +124,17 @@ namespace mongo { OplogReader oplogReader; void applyOperation(OperationContext* txn, Database* db, const BSONObj& op); - string hostName; // ip addr or hostname plus optionally, ":<port>" - string _sourceName; // a logical source name. - string sourceName() const { return _sourceName.empty() ? "main" : _sourceName; } - string only; // only a certain db. note that in the sources collection, this may not be changed once you start replicating. + std::string hostName; // ip addr or hostname plus optionally, ":<port>" + std::string _sourceName; // a logical source name. + std::string sourceName() const { return _sourceName.empty() ? "main" : _sourceName; } + std::string only; // only a certain db. note that in the sources collection, this may not be changed once you start replicating. /* the last time point we have already synced up to (in the remote/master's oplog). */ OpTime syncedTo; int nClonedThisPass; - typedef vector< shared_ptr< ReplSource > > SourceVector; + typedef std::vector< shared_ptr< ReplSource > > SourceVector; static void loadAll(SourceVector&); explicit ReplSource(BSONObj); @@ -150,7 +150,7 @@ namespace mongo { bool operator==(const ReplSource&r) const { return hostName == r.hostName && sourceName() == r.sourceName(); } - string toString() const { return sourceName() + "@" + hostName; } + std::string toString() const { return sourceName() + "@" + hostName; } bool haveMoreDbsToSync() const { return !addDbNextPass.empty(); } int sleepAdvice() const { @@ -172,14 +172,14 @@ namespace mongo { class DatabaseIgnorer { public: /** Indicate that operations for 'db' should be ignored until after 'futureOplogTime' */ - void doIgnoreUntilAfter( const string &db, const OpTime &futureOplogTime ); + void doIgnoreUntilAfter( const std::string &db, const OpTime &futureOplogTime ); /** * Query ignore state of 'db'; if 'currentOplogTime' is after the ignore * limit, the ignore state will be cleared. */ - bool ignoreAt( const string &db, const OpTime ¤tOplogTime ); + bool ignoreAt( const std::string &db, const OpTime ¤tOplogTime ); private: - map< string, OpTime > _ignores; + std::map< std::string, OpTime > _ignores; }; } |