Page MenuHomeSoftware Heritage

Wrap query in transaction
ClosedPublic

Authored by ardumont on May 31 2022, 10:36 AM.

Details

Summary

This alleviates current locking issues.

Related to T4228

Test Plan

T4228#85847

Corrupt objects are popping up now (and growing fast):

Tue 31 May 2022 11:01:14 AM CEST (every 2s)

+-------------------------------+-------+
|              now              | count |
+-------------------------------+-------+
| 2022-05-31 09:01:14.233113+00 |  1620 |
+-------------------------------+-------+
(1 row)
+-------------------------------+-------+
|              now              | count |
+-------------------------------+-------+
| 2022-05-31 09:01:54.394741+00 |  3233 |
+-------------------------------+-------+
(1 row)

Time: 6.463 ms

Diff Detail

Repository
rDSCRUB Datastore Scrubber
Branch
master
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 29617
Build 46285: Phabricator diff pipeline on jenkinsJenkins console · Jenkins
Build 46284: arc lint + arc unit

Event Timeline

Build is green

Patch application report for D7914 (id=28526)

Rebasing onto f24850469c...

Current branch diff-target is up to date.
Changes applied before test
commit 377f5e084ab71ec6fb4f9c69b89ff2364d93c3eb
Author: Antoine R. Dumont (@ardumont) <antoine.romain.dumont@gmail.com>
Date:   Tue May 31 10:35:45 2022 +0200

    Wrap query in transaction
    
    This might help alleviate current locking issues.
    
    Related to T4228

See https://jenkins.softwareheritage.org/job/DSCRUB/job/tests-on-diff/46/ for more details.

ardumont retitled this revision from wip: Wrap query in transaction to Wrap query in transaction.
ardumont edited the summary of this revision. (Show Details)
ardumont edited the test plan for this revision. (Show Details)
ardumont edited the test plan for this revision. (Show Details)
douardda added a subscriber: douardda.

makes sense to me

This revision is now accepted and ready to land.May 31 2022, 11:06 AM

Build is green

Patch application report for D7914 (id=28527)

Rebasing onto f24850469c...

Current branch diff-target is up to date.
Changes applied before test
commit 31bcec6000a8e7130f67a1d0f3b3d9c5f4fd6aba
Author: Antoine R. Dumont (@ardumont) <antoine.romain.dumont@gmail.com>
Date:   Tue May 31 10:35:45 2022 +0200

    Wrap queries in transaction
    
    This alleviates current locking issues where nothing gets written in production.
    
    Related to T4228

See https://jenkins.softwareheritage.org/job/DSCRUB/job/tests-on-diff/47/ for more details.

This revision was automatically updated to reflect the committed changes.