[SERVER-31830] Log values in invariant statements Created: 03/Nov/17  Updated: 30/Oct/23  Resolved: 06/Dec/17

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

Type: Improvement Priority: Major - P3
Reporter: Judah Schvimer Assignee: Samantha Ritter (Inactive)
Resolution: Fixed Votes: 1
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Problem/Incident
causes SERVER-32369 Invariant incorrectly with message st... Closed
Related
Backwards Compatibility: Fully Compatible
Backport Requested:
v3.6
Sprint: Platforms 2017-12-04, Platforms 2017-12-18
Participants:
Linked BF Score: 0

 Description   

When an invariant gets triggered, we often have no idea what the values were that caused it to fail. We should have a way to provide a log message to print out with it.



 Comments   
Comment by Githook User [ 25/May/18 ]

Author:

{'username': 'samantharitter', 'name': 'samantharitter', 'email': 'samantha.ritter@10gen.com'}

Message: SERVER-31830 Allow invariant to accept messages

(cherry picked from commit 19f93e1015bc177c5f5578a0890718d18926b7d7)
Branch: v3.6
https://github.com/mongodb/mongo/commit/ae6fd6629926e119e884e8823e24945f4ba0bb7c

Comment by Githook User [ 06/Dec/17 ]

Author:

{'name': 'samantharitter', 'username': 'samantharitter', 'email': 'samantha.ritter@10gen.com'}

Message: SERVER-31830 Allow invariant to accept messages
Branch: master
https://github.com/mongodb/mongo/commit/19f93e1015bc177c5f5578a0890718d18926b7d7

Comment by Andy Schwerin [ 04/Nov/17 ]

I've often wished for invariant_eq, as in the unit test framework. Similarly, it would be nice to stream into invariant and fassert failures.

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