[SERVER-30331] Enhance RandomizedScalarGenerator to generate all kinds of BSON types for idempotency testing Created: 25/Jul/17  Updated: 27/Sep/18  Resolved: 27/Sep/18

Status: Closed
Project: Core Server
Component/s: Replication, Testing Infrastructure
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Major - P3
Reporter: Max Hirschhorn Assignee: DO NOT USE - Backlog - Test Infrastructure Group (TIG)
Resolution: Won't Fix Votes: 0
Labels: close
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
depends on SERVER-30327 Introduce ScalarGenerator interface f... Closed
Participants:

 Description   

The UpdateSequenceGenerator class introduced in SERVER-29939 randomly selects between null, true, false, and double values between -INT_MAX and INT_MAX. We should update the RandomizedScalarGenerator to be able to generate all possible BSON types in order to be able to detect idempotency issues related to different BSON types (e.g. type fidelity in $set, see SERVER-16801).

Note: When generating Decimal128 values, we should uniformly generate an exponent and generate a mantissa separately in order to be able to generate both small and large Decimal128 values with non-negligible probabilities, per geert.bosch's recommendation.


Generated at Thu Feb 08 04:23:27 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.