summaryrefslogtreecommitdiff
path: root/src/mongo/db
diff options
context:
space:
mode:
authorIan Kuehne <ian.kuehne@mongodb.com>2017-07-03 16:36:03 -0400
committerIan Kuehne <ian.kuehne@mongodb.com>2017-07-03 16:36:03 -0400
commit5b83e73d2ec0165b15fd2e47f300b076d279f0c3 (patch)
tree405b0bfd4841e53b7cb0fb6b8d3f8312678f12e5 /src/mongo/db
parentacd196d77043d007b07b48b6e2c4fb13cfa5b938 (diff)
downloadmongo-5b83e73d2ec0165b15fd2e47f300b076d279f0c3.tar.gz
Fix comment formatting.
Diffstat (limited to 'src/mongo/db')
-rw-r--r--src/mongo/db/catalog/create_collection.cpp20
-rw-r--r--src/mongo/db/repl/collection_bulk_loader_impl.cpp3
2 files changed, 8 insertions, 15 deletions
diff --git a/src/mongo/db/catalog/create_collection.cpp b/src/mongo/db/catalog/create_collection.cpp
index 283e10f267c..d8e98306e5d 100644
--- a/src/mongo/db/catalog/create_collection.cpp
+++ b/src/mongo/db/catalog/create_collection.cpp
@@ -153,17 +153,12 @@ Status createCollectionForApplyOps(OperationContext* opCtx,
// In the case of oplog replay, a future command may have created or renamed a
// collection with that same name. In that case, renaming this future collection to
- // a
- // random temporary name is correct: once all entries are replayed no temporary
- // names
- // will remain.
- // On MMAPv1 the rename can result in index names that are too long. However this
- // should
- // only happen for initial sync and "resync collection" for rollback, so we can let
- // the
- // error propagate resulting in an abort and restart of the initial sync or result
- // in
- // rollback to fassert, requiring a resync of that node.
+ // a random temporary name is correct: once all entries are replayed no temporary
+ // names will remain. On MMAPv1 the rename can result in index names that are too
+ // long. However this should only happen for initial sync and "resync collection"
+ // for rollback, so we can let the error propagate resulting in an abort and restart
+ // of the initial sync or result in rollback to fassert, requiring a resync of that
+ // node.
const bool stayTemp = true;
if (auto futureColl = db ? db->getCollection(opCtx, newCollName) : nullptr) {
auto tmpName =
@@ -183,8 +178,7 @@ Status createCollectionForApplyOps(OperationContext* opCtx,
}
// If the collection with the requested UUID already exists, but with a different
- // name,
- // just rename it to 'newCollName'.
+ // name, just rename it to 'newCollName'.
if (catalog.lookupCollectionByUUID(uuid)) {
Status status =
db->renameCollection(opCtx, currentName.ns(), newCollName.ns(), stayTemp);
diff --git a/src/mongo/db/repl/collection_bulk_loader_impl.cpp b/src/mongo/db/repl/collection_bulk_loader_impl.cpp
index c7118429ba9..daf349029b7 100644
--- a/src/mongo/db/repl/collection_bulk_loader_impl.cpp
+++ b/src/mongo/db/repl/collection_bulk_loader_impl.cpp
@@ -158,8 +158,7 @@ Status CollectionBulkLoaderImpl::insertDocuments(const std::vector<BSONObj>::con
WriteUnitOfWork wunit(_opCtx.get());
if (!indexers.empty()) {
// This flavor of insertDocument will not update any pre-existing indexes,
- // only
- // the indexers passed in.
+ // only the indexers passed in.
const auto status = _autoColl->getCollection()->insertDocument(
_opCtx.get(), *iter, indexers, false);
if (!status.isOK()) {