summaryrefslogtreecommitdiff
path: root/src/mongo/db/d_globals.h
blob: 7c95d463cc3ea19912beaec6b6a1f4ce83b3e3d8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
// @file d_globals.h
//
// these are global variables used in mongod ("d").  also used in test binary as that is effectively a variation on mongod code.
// that is, these are not in mongos.
//

#pragma once

namespace mongo { 

    class RWLock;
    class MongoMutex;
    class ClientCursorMonitor;

    struct DGlobals : boost::noncopyable { 
        DGlobals();

        // these are intentionally never deleted:
        RWLock& writeExcluder;
        MongoMutex &dbMutex;
        ClientCursorMonitor& clientCursorMonitor;

    };

    extern DGlobals d;

};