Skip to content

Conversation

@eramongodb
Copy link
Contributor

Resolves CXX-3237 and CXX-3238 for the v1::write_concern component.

The test/private/write_concern.cpp test component is removed: it was only asserting that specific mongoc functions were being invoked by specific mongocxx functions. This behavior is broken by the v1 API + v_noabi refactor, which now uses the *_int64 variants of mongoc_write_concern_set_wtimeout() accessors and avoids calling mongoc_write_concern_set_wmajority() in favor of *_set_w() + *_set_wtimeout() individually. For backward compatibility, .to_document() avoids appending the "wtimeout" field as a $numberLong unless it is strictly necessary, otherwise wc.timeout(0).to_document().view() == scoped_bson{R"({"wtimeout": 0})"}.view() evaluates to false (int32 vs. int64).

@eramongodb eramongodb requested a review from kevinAlbs November 14, 2025 21:58
@eramongodb eramongodb self-assigned this Nov 14, 2025
@eramongodb eramongodb requested a review from a team as a code owner November 14, 2025 21:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant