Skip to content

follow-up: fold reverse-dep edge deletion into NativeDatabase.purgeFilesData for atomicity #670

@carlos-alm

Description

@carlos-alm

Deferred from PR #669 review.

Original reviewer comment: #669 (comment)

Context: purgeFilesData commits its own transaction via the persistent NativeDatabase connection, while the immediately following reverse-dependency edge purge still runs through the better-sqlite3 db handle. If the process is interrupted between the two, dangling edges may remain. This is a pre-existing atomicity gap (not a regression from this PR), but now that purge runs through NativeDatabase, the reverse-dep edge deletion could also be folded into purgeFilesData to give true single-transaction atomicity.

Metadata

Metadata

Assignees

No one assigned

    Labels

    follow-upDeferred work from PR reviews that needs tracking

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions