fdb-record-layer icon indicating copy to clipboard operation
fdb-record-layer copied to clipboard

Fixes #2275: Version mutations aren't cleared out by delete records where

Open alecgrieser opened this issue 1 year ago • 3 comments

The main record store and index maintainers now clear out uncommitted version mutations when performing a record range delete. Previously, this failure to do so meant that it would be dangerous to perform deleteRecordsWhere with record versions enabled if there were uncommitted record saves performed in the same transaction. Committing the transaction would lead to the record data not being written, but the version information and the version indexes would be, leading to corrupt record stores and orphaned index entries. This cleans up that data during the clear so that we don't have uncommitted versions.

There's something to be said about the abstractions here potentially being a little off, and that we should improve some of our I/O methods here to make this bug harder to write. For now, I've just tried to patch the bug.

This fixes #2275.

alecgrieser avatar Aug 30 '23 15:08 alecgrieser

Result of fdb-record-layer-pr-proto3 on Linux CentOS 7

  • Commit ID: 98c5855fbe0b199732ca609d09d094fd5e33602d
  • Duration 0:23:37
  • Result: :white_check_mark: SUCCEEDED
  • Error: N/A
  • Build Log terminal output (available for 30 days)
  • Build Workspace zip file of the working directory (available for 30 days)

foundationdb-ci avatar Aug 30 '23 15:08 foundationdb-ci

Result of fdb-record-layer-pr-proto2 on Linux CentOS 7

  • Commit ID: 98c5855fbe0b199732ca609d09d094fd5e33602d
  • Duration 0:23:26
  • Result: :white_check_mark: SUCCEEDED
  • Error: N/A
  • Build Log terminal output (available for 30 days)
  • Build Workspace zip file of the working directory (available for 30 days)

foundationdb-ci avatar Aug 30 '23 15:08 foundationdb-ci

SonarCloud Quality Gate failed.    Quality Gate failed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 2 Code Smells

0.0% 0.0% Coverage
0.0% 0.0% Duplication

warning The version of Java (11.0.20) you have used to run this analysis is deprecated and we will stop accepting it soon. Please update to at least Java 17. Read more here

idea Catch issues before they fail your Quality Gate with our IDE extension sonarlint SonarLint

sonarqubecloud[bot] avatar Aug 30 '23 16:08 sonarqubecloud[bot]

Result of fdb-record-layer-pr-proto2 on Linux CentOS 7

  • Commit ID: c1bc2d7bec9563b6ffe4e7403c1da39b5aeccd21
  • Duration 0:21:24
  • Result: :white_check_mark: SUCCEEDED
  • Error: N/A
  • Build Log terminal output (available for 30 days)
  • Build Workspace zip file of the working directory (available for 30 days)

foundationdb-ci avatar Aug 30 '23 16:08 foundationdb-ci

Result of fdb-record-layer-pr-proto3 on Linux CentOS 7

  • Commit ID: c1bc2d7bec9563b6ffe4e7403c1da39b5aeccd21
  • Duration 0:21:56
  • Result: :white_check_mark: SUCCEEDED
  • Error: N/A
  • Build Log terminal output (available for 30 days)
  • Build Workspace zip file of the working directory (available for 30 days)

foundationdb-ci avatar Aug 30 '23 16:08 foundationdb-ci