-
Type: Improvement
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: None
-
Minor Change
The session spec says under https://github.com/mongodb/specifications/blob/master/source/sessions/driver-sessions.rst#endsession:
> Once a ClientSession has ended, drivers MUST report an error if any operations are attempted with that ClientSession.
In ruby driver, several session methods (txn_num, next_txn_num, session_id) instead return nil, and in case of next_txn_num, do not perform the requested operation of bumping the transaction number, if the session is ended. To be spec compliant these methods should raise an exception if they are invoked on an ended session.