btree_stats.h   btree_stats.h 
skipping to change at line 38 skipping to change at line 38
class IndexCounters : public ServerStatusSection { class IndexCounters : public ServerStatusSection {
public: public:
IndexCounters(); IndexCounters();
virtual ~IndexCounters(); virtual ~IndexCounters();
virtual bool includeByDefault() const { return true; } virtual bool includeByDefault() const { return true; }
virtual BSONObj generateSection(const BSONElement& configElement) c onst; virtual BSONObj generateSection(const BSONElement& configElement) c onst;
// used without a mutex intentionally (can race) // used without a mutex intentionally (can race)
void btree( char * node ) { void btree( const char* node ) {
if ( ! _memSupported ) if ( ! _memSupported )
return; return;
btree( Record::likelyInPhysicalMemory( node ) ); btree( Record::likelyInPhysicalMemory( node ) );
} }
void btree( bool memHit ) { void btree( bool memHit ) {
if ( memHit ) if ( memHit )
_btreeMemHits++; _btreeMemHits++;
else else
_btreeMemMisses++; _btreeMemMisses++;
skipping to change at line 70 skipping to change at line 70
bool _memSupported; bool _memSupported;
int _resets; int _resets;
long long _maxAllowed; long long _maxAllowed;
long long _btreeMemMisses; long long _btreeMemMisses;
long long _btreeMemHits; long long _btreeMemHits;
long long _btreeAccesses; long long _btreeAccesses;
}; };
extern IndexCounters globalIndexCounters; extern IndexCounters* globalIndexCounters;
} }
 End of changes. 2 change blocks. 
2 lines changed or deleted 2 lines changed or added


 builder.h   builder.h 
skipping to change at line 204 skipping to change at line 204
/** @return length of current string */ /** @return length of current string */
int len() const { return l; } int len() const { return l; }
void setlen( int newLen ) { l = newLen; } void setlen( int newLen ) { l = newLen; }
/** @return size of the buffer */ /** @return size of the buffer */
int getSize() const { return size; } int getSize() const { return size; }
/* returns the pre-grow write position */ /* returns the pre-grow write position */
inline char* grow(int by) { inline char* grow(int by) {
int oldlen = l; int oldlen = l;
l += by; int newLen = l + by;
if ( l > size ) { if ( newLen > size ) {
grow_reallocate(); grow_reallocate(newLen);
} }
l = newLen;
return data + oldlen; return data + oldlen;
} }
private: private:
/* "slow" portion of 'grow()' */ /* "slow" portion of 'grow()' */
void NOINLINE_DECL grow_reallocate() { void NOINLINE_DECL grow_reallocate(int newLen) {
int a = 64; int a = 64;
while( a < l ) while( a < newLen )
a = a * 2; a = a * 2;
if ( a > BufferMaxSize ) { if ( a > BufferMaxSize ) {
std::stringstream ss; std::stringstream ss;
ss << "BufBuilder attempted to grow() to " << a << " bytes, past the 64MB limit."; ss << "BufBuilder attempted to grow() to " << a << " bytes, past the 64MB limit.";
msgasserted(13548, ss.str().c_str()); msgasserted(13548, ss.str().c_str());
} }
data = (char *) al.Realloc(data, a); data = (char *) al.Realloc(data, a);
if ( data == NULL ) if ( data == NULL )
msgasserted( 16070 , "out of memory BufBuilder::grow_reallo cate" ); msgasserted( 16070 , "out of memory BufBuilder::grow_reallo cate" );
size = a; size = a;
 End of changes. 4 change blocks. 
5 lines changed or deleted 6 lines changed or added


 chunk_version.h   chunk_version.h 
skipping to change at line 119 skipping to change at line 119
bool operator>=( const ChunkVersion& otherVersion ) const { bool operator>=( const ChunkVersion& otherVersion ) const {
return this->_combined >= otherVersion._combined; return this->_combined >= otherVersion._combined;
} }
bool operator<( const ChunkVersion& otherVersion ) const { bool operator<( const ChunkVersion& otherVersion ) const {
return this->_combined < otherVersion._combined; return this->_combined < otherVersion._combined;
} }
bool operator<=( const ChunkVersion& otherVersion ) const { bool operator<=( const ChunkVersion& otherVersion ) const {
return this->_combined < otherVersion._combined; return this->_combined <= otherVersion._combined;
} }
// //
// Equivalence comparison types. // Equivalence comparison types.
// //
// Can we write to this data and not have a problem? // Can we write to this data and not have a problem?
bool isWriteCompatibleWith( const ChunkVersion& otherVersion ) cons t { bool isWriteCompatibleWith( const ChunkVersion& otherVersion ) cons t {
if( ! hasCompatibleEpoch( otherVersion ) ) return false; if( ! hasCompatibleEpoch( otherVersion ) ) return false;
return otherVersion._major == _major; return otherVersion._major == _major;
 End of changes. 1 change blocks. 
1 lines changed or deleted 1 lines changed or added


 pdfile.h   pdfile.h 
skipping to change at line 313 skipping to change at line 313
bool likelyInPhysicalMemory() const ; bool likelyInPhysicalMemory() const ;
/** /**
* tell the cache this Record was accessed * tell the cache this Record was accessed
* @return this, for simple chaining * @return this, for simple chaining
*/ */
Record* accessed(); Record* accessed();
static bool likelyInPhysicalMemory( const char* data ); static bool likelyInPhysicalMemory( const char* data );
static bool blockCheckSupported();
/** /**
* this adds stats about page fault exceptions currently * this adds stats about page fault exceptions currently
* specically how many times we call _accessing where the record is not in memory * specically how many times we call _accessing where the record is not in memory
* and how many times we throw a PageFaultException * and how many times we throw a PageFaultException
*/ */
static void appendStats( BSONObjBuilder& b ); static void appendStats( BSONObjBuilder& b );
static void appendWorkingSetInfo( BSONObjBuilder& b ); static void appendWorkingSetInfo( BSONObjBuilder& b );
private: private:
 End of changes. 1 change blocks. 
2 lines changed or deleted 0 lines changed or added


 rs.h   rs.h 
skipping to change at line 152 skipping to change at line 152
* and S3 can ghost sync from the primary. * and S3 can ghost sync from the primary.
* *
* Say we have an S1--->S2--->P situation and this node is S2. rid * Say we have an S1--->S2--->P situation and this node is S2. rid
* would refer to S1. S2 would create a ghost slave of S1 and conn ect * would refer to S1. S2 would create a ghost slave of S1 and conn ect
* it to P (_currentSyncTarget). Then it would use this connection to * it to P (_currentSyncTarget). Then it would use this connection to
* pretend to be S1, replicating off of P. * pretend to be S1, replicating off of P.
*/ */
void percolate(const BSONObj& rid, const OpTime& last); void percolate(const BSONObj& rid, const OpTime& last);
void associateSlave(const BSONObj& rid, const int memberId); void associateSlave(const BSONObj& rid, const int memberId);
void updateSlave(const mongo::OID& id, const OpTime& last); void updateSlave(const mongo::OID& id, const OpTime& last);
void clearCache();
}; };
class Consensus { class Consensus {
ReplSetImpl &rs; ReplSetImpl &rs;
struct LastYea { struct LastYea {
LastYea() : when(0), who(0xffffffff) { } LastYea() : when(0), who(0xffffffff) { }
time_t when; time_t when;
unsigned who; unsigned who;
}; };
static SimpleMutex lyMutex; static SimpleMutex lyMutex;
skipping to change at line 492 skipping to change at line 493
unsigned selfId() const { return _id; } unsigned selfId() const { return _id; }
Manager *mgr; Manager *mgr;
GhostSync *ghost; GhostSync *ghost;
/** /**
* This forces a secondary to go into recovering state and stay the re * This forces a secondary to go into recovering state and stay the re
* until this is called again, passing in "false". Multiple thread s can * until this is called again, passing in "false". Multiple thread s can
* call this and it will leave maintenance mode once all of the cal lers * call this and it will leave maintenance mode once all of the cal lers
* have called it again, passing in false. * have called it again, passing in false.
*/ */
bool setMaintenanceMode(const bool inc); bool setMaintenanceMode(const bool inc);
// Records a new slave's id in the GhostSlave map, at handshake tim
e.
void registerSlave(const BSONObj& rid, const int memberId);
private: private:
Member* head() const { return _members.head(); } Member* head() const { return _members.head(); }
public: public:
const Member* findById(unsigned id) const; const Member* findById(unsigned id) const;
Member* findByName(const std::string& hostname) const; Member* findByName(const std::string& hostname) const;
private: private:
void _getTargets(list<Target>&, int &configVersion); void _getTargets(list<Target>&, int &configVersion);
void getTargets(list<Target>&, int &configVersion); void getTargets(list<Target>&, int &configVersion);
void startThreads(); void startThreads();
friend class FeedbackThread; friend class FeedbackThread;
 End of changes. 2 change blocks. 
0 lines changed or deleted 5 lines changed or added


 sasl_client_authenticate.h   sasl_client_authenticate.h 
skipping to change at line 37 skipping to change at line 37
* *
* Do not use directly in client code. Use the DBClientWithCommands::a uth(const BSONObj&) * Do not use directly in client code. Use the DBClientWithCommands::a uth(const BSONObj&)
* method, instead. * method, instead.
* *
* Test against NULL for availability. Client driver must be compiled with SASL support _and_ * Test against NULL for availability. Client driver must be compiled with SASL support _and_
* client application must have successfully executed mongo::runGlobalI nitializersOrDie() or its * client application must have successfully executed mongo::runGlobalI nitializersOrDie() or its
* ilk to make this functionality available. * ilk to make this functionality available.
* *
* The "saslParameters" BSONObj should be initialized with zero or more of the * The "saslParameters" BSONObj should be initialized with zero or more of the
* fields below. Which fields are required depends on the mechanism. Consult the * fields below. Which fields are required depends on the mechanism. Consult the
* libgsasl documentation. * relevant IETF standards.
* *
* "mechanism": The string name of the sasl mechanism to use. Mand atory. * "mechanism": The string name of the sasl mechanism to use. Mand atory.
* "autoAuthorize": Truthy values tell the server to automatically acquire privileges on * "autoAuthorize": Truthy values tell the server to automatically acquire privileges on
* all resources after successful authentication, which is the default. Falsey values * all resources after successful authentication, which is the default. Falsey values
* instruct the server to await separate privilege-acquisition commands. * instruct the server to await separate privilege-acquisition commands.
* "user": The string name of the principal to authenticate, GSASL_ AUTHID. * "user": The string name of the principal to authenticate.
* "userSource": The database target of the auth command, which ide ntifies the location * "userSource": The database target of the auth command, which ide ntifies the location
* of the credential information for the principal. May be "$e xternal" if credential * of the credential information for the principal. May be "$e xternal" if credential
* information is stored outside of the mongo cluster. * information is stored outside of the mongo cluster.
* "pwd": The password data, GSASL_PASSWORD. * "pwd": The password.
* "serviceName": The GSSAPI service name to use. Defaults to "mon godb". * "serviceName": The GSSAPI service name to use. Defaults to "mon godb".
* "serviceHostname": The GSSAPI hostname to use. Defaults to the name of the remote host. * "serviceHostname": The GSSAPI hostname to use. Defaults to the name of the remote host.
* *
* Other fields in saslParameters are silently ignored. * Other fields in saslParameters are silently ignored.
* *
* "sessionHook" is a pointer to optional data, which may be used by th
e gsasl_callback
* previously set on "gsasl". The session hook is set on an underlying
Gsasl_session using
* gsasl_session_hook_set, and may be accessed by callbacks using gsasl
_session_hook_get.
* See the gsasl documentation.
*
* Returns an OK status on success, and ErrorCodes::AuthenticationFaile d if authentication is * Returns an OK status on success, and ErrorCodes::AuthenticationFaile d if authentication is
* rejected. Other failures, all of which are tantamount to authentica tion failure, may also be * rejected. Other failures, all of which are tantamount to authentica tion failure, may also be
* returned. * returned.
*/ */
extern Status (*saslClientAuthenticate)(DBClientWithCommands* client, extern Status (*saslClientAuthenticate)(DBClientWithCommands* client,
const BSONObj& saslParameters, const BSONObj& saslParameters);
void* sessionHook);
/** /**
* Extracts the payload field from "cmdObj", and store it into "*payloa d". * Extracts the payload field from "cmdObj", and store it into "*payloa d".
* *
* Sets "*type" to the BSONType of the payload field in cmdObj. * Sets "*type" to the BSONType of the payload field in cmdObj.
* *
* If the type of the payload field is String, the contents base64 deco des and * If the type of the payload field is String, the contents base64 deco des and
* stores into "*payload". If the type is BinData, the contents are st ored directly * stores into "*payload". If the type is BinData, the contents are st ored directly
* into "*payload". In all other cases, returns * into "*payload". In all other cases, returns
*/ */
 End of changes. 5 change blocks. 
13 lines changed or deleted 4 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/