Skip to content

Commit 6f76316

Browse files
authored
m_bmqstoragetool::RecordPrinter: Fix print bug (#663)
Signed-off-by: Yuan Jing Vincent Yan <[email protected]>
1 parent 3cea0b8 commit 6f76316

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

src/applications/bmqstoragetool/m_bmqstoragetool_printer.t.cpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -364,9 +364,9 @@ static void test3_humanReadableRecordsTest()
364364
<< " Epoch : 100\n"
365365
<< " JournalOpType : SYNCPOINT\n"
366366
<< " SyncPointType : REGULAR\n"
367-
<< " SyncPtPrimaryLeaseId: 25\n"
367+
<< " SyncPtPrimaryLeaseId: 121\n"
368368
<< " SyncPtSequenceNumber: 1234567\n"
369-
<< " PrimaryNodeId : 121\n"
369+
<< " PrimaryNodeId : 25\n"
370370
<< " DataFileOffsetDwords: 8800\n\n";
371371

372372
BMQTST_ASSERT_EQ(expectedStream.str(), resultStream.str());
@@ -1128,9 +1128,9 @@ static void test11_jsonPrettyRecordsTest()
11281128
<< " \"Epoch\": \"100\",\n"
11291129
<< " \"JournalOpType\": \"SYNCPOINT\",\n"
11301130
<< " \"SyncPointType\": \"REGULAR\",\n"
1131-
<< " \"SyncPtPrimaryLeaseId\": \"25\",\n"
1131+
<< " \"SyncPtPrimaryLeaseId\": \"121\",\n"
11321132
<< " \"SyncPtSequenceNumber\": \"1234567\",\n"
1133-
<< " \"PrimaryNodeId\": \"121\",\n"
1133+
<< " \"PrimaryNodeId\": \"25\",\n"
11341134
<< " \"DataFileOffsetDwords\": \"8800\"\n"
11351135
<< " }\n"
11361136
<< " ]\n"
@@ -2006,9 +2006,9 @@ static void test19_jsonLineRecordsTest()
20062006
<< "\"Epoch\": \"100\", "
20072007
<< "\"JournalOpType\": \"SYNCPOINT\", "
20082008
<< "\"SyncPointType\": \"REGULAR\", "
2009-
<< "\"SyncPtPrimaryLeaseId\": \"25\", "
2009+
<< "\"SyncPtPrimaryLeaseId\": \"121\", "
20102010
<< "\"SyncPtSequenceNumber\": \"1234567\", "
2011-
<< "\"PrimaryNodeId\": \"121\", "
2011+
<< "\"PrimaryNodeId\": \"25\", "
20122012
<< "\"DataFileOffsetDwords\": \"8800\"" << "}\n"
20132013
<< " ]\n"
20142014
<< "}\n";

src/applications/bmqstoragetool/m_bmqstoragetool_recordprinter.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -267,8 +267,8 @@ void RecordDetailsPrinter<PRINTER_TYPE>::printRecord(
267267
d_fields.push_back("DataFileOffsetDwords");
268268

269269
*d_printer_mp << rec.d_record.type() << rec.d_record.syncPointType()
270-
<< rec.d_record.primaryNodeId() << rec.d_record.sequenceNum()
271270
<< rec.d_record.primaryLeaseId()
271+
<< rec.d_record.sequenceNum() << rec.d_record.primaryNodeId()
272272
<< rec.d_record.dataFileOffsetDwords();
273273
}
274274

src/groups/mqb/mqbs/mqbs_filestoreprotocolprinter.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -438,7 +438,7 @@ void printRecord(bsl::ostream& stream, const mqbs::JournalOpRecord& rec)
438438
}
439439

440440
printer << epochValue << rec.type() << rec.syncPointType()
441-
<< rec.primaryNodeId() << rec.sequenceNum() << rec.primaryLeaseId()
441+
<< rec.primaryLeaseId() << rec.sequenceNum() << rec.primaryNodeId()
442442
<< rec.dataFileOffsetDwords();
443443

444444
stream << "\n";

0 commit comments

Comments
 (0)