[SERVER-39812] Add the number of in-progress transactions to server status Created: 25/Feb/19  Updated: 22/May/19  Resolved: 22/May/19

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

Type: Improvement Priority: Major - P3
Reporter: Gregory McKeon (Inactive) Assignee: Siyuan Zhou
Resolution: Duplicate Votes: 0
Labels: bigtxns_diagnostics, bigtxns_optional
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
Related
is related to SERVER-39813 Add the oldest required timestamp int... Closed
Sprint: Repl 2019-06-03
Participants:

 Comments   
Comment by Siyuan Zhou [ 22/May/19 ]

The server status is already available on primary.

rs:PRIMARY> db.serverStatus().transactions
{
	"retriedCommandsCount" : NumberLong(0),
	"retriedStatementsCount" : NumberLong(0),
	"transactionsCollectionWriteCount" : NumberLong(0),
	"currentActive" : NumberLong(1),
	"currentInactive" : NumberLong(0),
	"currentOpen" : NumberLong(1),
	"totalAborted" : NumberLong(1),
	"totalCommitted" : NumberLong(0),
	"totalStarted" : NumberLong(2),
	"totalPrepared" : NumberLong(0),
	"totalPreparedThenCommitted" : NumberLong(0),
	"totalPreparedThenAborted" : NumberLong(0),
	"currentPrepared" : NumberLong(0)
}

On secondaries, unprepared transaction are scheduled as individual operations and in-progress transactions only have on-disk state so they will not show up in server status. Only transactions that have been prepared will appear in the server status on secondaries.

Closing the ticket.

Comment by Siyuan Zhou [ 16/May/19 ]

siyuan.zhou, double check if this number is already in server status.

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