diff options
author | wolfkdy <kdy71107216@aliyun.com> | 2017-03-04 16:10:58 +0800 |
---|---|---|
committer | Geert Bosch <geert@mongodb.com> | 2017-07-05 17:44:39 -0400 |
commit | 93beb0234eba9dc58ab6070ad472022f96e019e6 (patch) | |
tree | 2187cdfef5e3b602fb736d175677e4eb7db562f5 /src/mongo/db/storage/kv/kv_collection_catalog_entry.cpp | |
parent | 2aefd80d1acea065c77bd3bd69abf686a27ae3e0 (diff) | |
download | mongo-93beb0234eba9dc58ab6070ad472022f96e019e6.tar.gz |
SERVER-22766 wiredtiger engine support update oplogsize online
Diffstat (limited to 'src/mongo/db/storage/kv/kv_collection_catalog_entry.cpp')
-rw-r--r-- | src/mongo/db/storage/kv/kv_collection_catalog_entry.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/mongo/db/storage/kv/kv_collection_catalog_entry.cpp b/src/mongo/db/storage/kv/kv_collection_catalog_entry.cpp index e96cddbb1a7..c775ada1a23 100644 --- a/src/mongo/db/storage/kv/kv_collection_catalog_entry.cpp +++ b/src/mongo/db/storage/kv/kv_collection_catalog_entry.cpp @@ -248,6 +248,12 @@ void KVCollectionCatalogEntry::updateValidator(OperationContext* opCtx, _catalog->putMetaData(opCtx, ns().toString(), md); } +void KVCollectionCatalogEntry::updateCappedSize(OperationContext* opCtx, long long size) { + MetaData md = _getMetaData(opCtx); + md.options.cappedSize = size; + _catalog->putMetaData(opCtx, ns().toString(), md); +} + BSONCollectionCatalogEntry::MetaData KVCollectionCatalogEntry::_getMetaData( OperationContext* opCtx) const { return _catalog->getMetaData(opCtx, ns().toString()); |