ldb dump_wal: add LOG_DATA, TIMED_PUT, PUT_BLOB_INDEX#14211
ldb dump_wal: add LOG_DATA, TIMED_PUT, PUT_BLOB_INDEX#14211evanj wants to merge 1 commit intofacebook:mainfrom
Conversation
3fd14b6 to
9d968fe
Compare
Previously, LOG_DATA would be ignored and would print like an empty record, and TIMED_PUT and PUT_BLOB_INDEX would cause ldb to exit with an unimplemented error. Add a unit test to cover these cases.
9d968fe to
2072d5c
Compare
|
Rebased on main. This is still relevant. |
✅ clang-tidy: No findings on changed linesCompleted in 341.2s. |
✅ Claude Code ReviewAuto-triggered after CI passed — reviewing commit 2072d5c Code Review: ldb dump_wal: add LOG_DATA, TIMED_PUT, PUT_BLOB_INDEXAPPROVE with suggestions. The implementation is correct, follows existing patterns, and solves a real user-facing problem. FindingsF1. Test only asserts LOG_DATA — missing TIMED_PUT and PUT_BLOB_INDEX assertions (MEDIUM)The test writes all three record types but only verifies LOG_DATA. The other two handlers could be broken and the test would still pass. Add: ASSERT_NE(std::string::npos, captured_output.find("TIMED_PUT("))
<< "ldb output:\n\n" << captured_output;
ASSERT_NE(std::string::npos, captured_output.find("PUT_BLOB_INDEX("))
<< "ldb output:\n\n" << captured_output;F2. stdout capture not restored on early test exit (LOW)The F3. TimedPutCF format includes write_time in parentheses (SUGGESTION)
F4. Consider decoding blob index for readability (SUGGESTION)
Full review written to ℹ️ About this responseGenerated by Claude Code. Limitations:
Commands:
|
Previously, LOG_DATA would be ignored and would print like an empty record, and TIMED_PUT and PUT_BLOB_INDEX would cause ldb to exit with an unimplemented error.
Add a unit test to cover these cases.