diff options
author | Henrik Edin <henrik.edin@mongodb.com> | 2020-04-09 16:29:36 -0400 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2020-04-20 15:41:45 +0000 |
commit | fccca7a804efdaf008ba859ceeb09d62444b2738 (patch) | |
tree | 15c291a2fb065caa4183b3ccd759c0d4ff3703b6 /src/mongo/bson/bson_depth.h | |
parent | 61f5d6cf5087d656ebc4bbd2bf75a0a5eacb9cad (diff) | |
download | mongo-fccca7a804efdaf008ba859ceeb09d62444b2738.tar.gz |
SERVER-47476 Use small_vector to be able to store a few multikey components without allocating memory
Also cleaned up FieldRef
Diffstat (limited to 'src/mongo/bson/bson_depth.h')
-rw-r--r-- | src/mongo/bson/bson_depth.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mongo/bson/bson_depth.h b/src/mongo/bson/bson_depth.h index 371b7d11afa..e7e6836a8bf 100644 --- a/src/mongo/bson/bson_depth.h +++ b/src/mongo/bson/bson_depth.h @@ -43,7 +43,7 @@ struct BSONDepth { static constexpr std::int32_t kBSONDepthParameterFloor = 5; // The maximum allowable value for the BSON depth parameter. - static constexpr std::int32_t kBSONDepthParameterCeiling = 1000; + static constexpr std::int32_t kBSONDepthParameterCeiling = 250; // The number of extra levels of nesting above the storage depth limit that the server will // tolerate. @@ -67,4 +67,5 @@ struct BSONDepth { */ static std::uint32_t getMaxDepthForUserStorage(); }; +using BSONDepthIndex = std::uint8_t; } // namespace mongo |