summaryrefslogtreecommitdiff
path: root/src/mongo/rpc
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/rpc')
-rw-r--r--src/mongo/rpc/legacy_reply_builder.cpp2
-rw-r--r--src/mongo/rpc/metadata/oplog_query_metadata_test.cpp4
-rw-r--r--src/mongo/rpc/metadata/repl_set_metadata_test.cpp4
-rw-r--r--src/mongo/rpc/metadata/sharding_metadata.cpp4
-rw-r--r--src/mongo/rpc/object_check_test.cpp2
5 files changed, 8 insertions, 8 deletions
diff --git a/src/mongo/rpc/legacy_reply_builder.cpp b/src/mongo/rpc/legacy_reply_builder.cpp
index 5f4d3cfe3d1..5fb373d12c8 100644
--- a/src/mongo/rpc/legacy_reply_builder.cpp
+++ b/src/mongo/rpc/legacy_reply_builder.cpp
@@ -100,7 +100,7 @@ LegacyReplyBuilder& LegacyReplyBuilder::setMetadata(const BSONObj& metadata) {
// because we already have skipped some bytes for the message header.
BSONObjBuilder resumedBuilder(
BSONObjBuilder::ResumeBuildingTag(), _builder, sizeof(QueryResult::Value));
- shardingMetadata.getValue().writeToMetadata(&resumedBuilder);
+ shardingMetadata.getValue().writeToMetadata(&resumedBuilder).transitional_ignore();
}
_state = State::kOutputDocs;
return *this;
diff --git a/src/mongo/rpc/metadata/oplog_query_metadata_test.cpp b/src/mongo/rpc/metadata/oplog_query_metadata_test.cpp
index cc08bf832fb..06784a65ee1 100644
--- a/src/mongo/rpc/metadata/oplog_query_metadata_test.cpp
+++ b/src/mongo/rpc/metadata/oplog_query_metadata_test.cpp
@@ -47,7 +47,7 @@ TEST(ReplResponseMetadataTest, OplogQueryMetadataRoundtrip) {
ASSERT_EQ(opTime2, metadata.getLastOpApplied());
BSONObjBuilder builder;
- metadata.writeToMetadata(&builder);
+ metadata.writeToMetadata(&builder).transitional_ignore();
BSONObj expectedObj(BSON(kOplogQueryMetadataFieldName << BSON(
"lastOpCommitted"
@@ -75,7 +75,7 @@ TEST(ReplResponseMetadataTest, OplogQueryMetadataRoundtrip) {
ASSERT_EQ(metadata.getSyncSourceIndex(), clonedMetadata.getSyncSourceIndex());
BSONObjBuilder clonedBuilder;
- clonedMetadata.writeToMetadata(&clonedBuilder);
+ clonedMetadata.writeToMetadata(&clonedBuilder).transitional_ignore();
BSONObj clonedSerializedObj = clonedBuilder.obj();
ASSERT_BSONOBJ_EQ(expectedObj, clonedSerializedObj);
diff --git a/src/mongo/rpc/metadata/repl_set_metadata_test.cpp b/src/mongo/rpc/metadata/repl_set_metadata_test.cpp
index 6d5b7be1a2f..b6285e63342 100644
--- a/src/mongo/rpc/metadata/repl_set_metadata_test.cpp
+++ b/src/mongo/rpc/metadata/repl_set_metadata_test.cpp
@@ -52,7 +52,7 @@ TEST(ReplResponseMetadataTest, Roundtrip) {
ASSERT_TRUE(metadata.hasReplicaSetId());
BSONObjBuilder builder;
- metadata.writeToMetadata(&builder);
+ metadata.writeToMetadata(&builder).transitional_ignore();
BSONObj expectedObj(
BSON(kReplSetMetadataFieldName
@@ -82,7 +82,7 @@ TEST(ReplResponseMetadataTest, Roundtrip) {
ASSERT_EQ(metadata.getReplicaSetId(), clonedMetadata.getReplicaSetId());
BSONObjBuilder clonedBuilder;
- clonedMetadata.writeToMetadata(&clonedBuilder);
+ clonedMetadata.writeToMetadata(&clonedBuilder).transitional_ignore();
BSONObj clonedSerializedObj = clonedBuilder.obj();
ASSERT_BSONOBJ_EQ(expectedObj, clonedSerializedObj);
diff --git a/src/mongo/rpc/metadata/sharding_metadata.cpp b/src/mongo/rpc/metadata/sharding_metadata.cpp
index b1c4b47b8e5..384c75f2679 100644
--- a/src/mongo/rpc/metadata/sharding_metadata.cpp
+++ b/src/mongo/rpc/metadata/sharding_metadata.cpp
@@ -116,7 +116,7 @@ Status ShardingMetadata::downconvert(const BSONObj& commandReply,
// We can reuse the same logic to write the sharding metadata out to the legacy
// command as the element has the same format whether it is there or on the metadata
// object.
- swShardingMetadata.getValue().writeToMetadata(legacyCommandReplyBob);
+ swShardingMetadata.getValue().writeToMetadata(legacyCommandReplyBob).transitional_ignore();
} else if (swShardingMetadata.getStatus() == ErrorCodes::NoSuchKey) {
// It is valid to not have a $gleStats field.
} else {
@@ -132,7 +132,7 @@ Status ShardingMetadata::upconvert(const BSONObj& legacyCommand,
// as it has the same format whether it is there or on the metadata object.
auto swShardingMetadata = readFromMetadata(legacyCommand);
if (swShardingMetadata.isOK()) {
- swShardingMetadata.getValue().writeToMetadata(metadataBob);
+ swShardingMetadata.getValue().writeToMetadata(metadataBob).transitional_ignore();
// Write out the command excluding the $gleStats subobject.
for (const auto& elem : legacyCommand) {
diff --git a/src/mongo/rpc/object_check_test.cpp b/src/mongo/rpc/object_check_test.cpp
index 00092ec009d..e36b396b10c 100644
--- a/src/mongo/rpc/object_check_test.cpp
+++ b/src/mongo/rpc/object_check_test.cpp
@@ -68,7 +68,7 @@ TEST(DataTypeValidated, BSONValidationEnabled) {
// mess up the data
DataRangeCursor drc(begin(buf), end(buf));
// skip past size so we don't trip any sanity checks.
- drc.advance(4); // skip size
+ drc.advance(4).transitional_ignore(); // skip size
while (drc.writeAndAdvance(0xFF).isOK())
;
}