• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Chaguar / committer / 36577246929
91%
main: 91%

Build:
Build:
LAST BUILD BRANCH: bench/sidecar-end-to-end
DEFAULT BRANCH: main
Ran 29 Sep 2026 01:49PM UTC
Jobs 3
Files 141
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

29 Sep 2026 01:43PM UTC coverage: 90.648% (-0.09%) from 90.735%
36577246929

Pull #826

github

cendhu
[vc, sidecar] Delete a snapshot database clone on admin request

#### Type of change

- New feature
- Documentation update

#### Description

- Adds `DeleteDBCloneForSnapshot(tx_id)`, propagating sidecar → coordinator → VC.
  The VC drops the database named by the `_snapshot` record's `clone_database`
  field and clears that field via a versioned namespace write; clearing it *is*
  the deletion signal, since `SnapshotState` carries no deletion timestamp. The
  record is retained, so the snapshot's status and hash stay queryable after its
  database is gone.
- Deletion is refused unless the snapshot's status is `CHECKPOINTED`
  (`FAILED_PRECONDITION`). Until then the clone is the only artifact from which
  the snapshot hash can be recomputed or a contested hash re-verified, so
  dropping it would be unrecoverable.
- Reports `INVALID_ARGUMENT` for an empty `tx_id` and `NOT_FOUND` for an unknown
  one. A repeated delete of an already-cleared record succeeds: the caller cannot
  distinguish a retry of its own request from a duplicate, and both mean the
  database is gone. That check precedes the status gate, so a retry of a delete
  that already succeeded stays a success.
- Adds `ClearCloneDatabase` to `statedb.SnapshotUpdate`, so the deletion path can
  clear `clone_database` through the shared `_snapshot` record accessor. The clear
  re-asserts `CHECKPOINTED` and sets `ExpectedStatus` to it, so the locked row must
  still be `CHECKPOINTED` for the clear to apply.
- Adds `statedb.SnapshotStateManager.Read(tx_id)` and the `statedb.ErrSnapshotNotFound`
  sentinel it reports, extracted from `ReadLatest`'s read-and-decode step so both agree
  on how a missing row and an undecodable value are reported. `ReadLatest` keeps
  treating a missing row as corruption, since its key comes from the pointer rather
  than from a caller.
- Records `DeleteDBCloneForSnapshot` calls in one embedded `mock.deleteCloneRecorder`
  shared by the mock coordinator and the mock vcse... (continued)
Pull Request #826: [vc, sidecar] Delete a snapshot database clone on admin request

86 of 95 new or added lines in 8 files covered. (90.53%)

169 existing lines in 10 files now uncovered.

9829 of 10843 relevant lines covered (90.65%)

11621.03 hits per line

Uncovered Changes

Lines Coverage ∆ File
4
84.16
-0.11% service/vc/database_snapshot.go
2
80.98
-1.23% service/sidecar/sidecar.go
2
91.41
-0.52% service/vc/validator_committer_service.go
1
78.51
3.74% utils/statedb/snapshot_state.go

Coverage Regressions

Lines Coverage ∆ File
80
80.98
-1.23% service/sidecar/sidecar.go
31
84.16
-0.11% service/vc/database_snapshot.go
19
78.51
3.74% utils/statedb/snapshot_state.go
12
91.41
-0.52% service/vc/validator_committer_service.go
6
93.4
-3.72% mock/coordinator.go
6
85.29
0.0% service/vc/database.go
5
96.03
0.54% mock/vcservice.go
5
94.44
-2.49% service/coordinator/coordinator.go
4
74.26
-3.96% service/vc/validator.go
1
96.2
-1.27% mock/sigverifier.go
Jobs
ID Job ID Ran Files Coverage
1 unit-test - 36577246929.1 29 Sep 2026 01:50PM UTC 95
86.09
GitHub Action Run
2 core-db-test - 36577246929.2 29 Sep 2026 01:51PM UTC 108
49.14
GitHub Action Run
3 db-test - 36577246929.3 29 Sep 2026 01:49PM UTC 141
78.47
GitHub Action Run
Source Files on build 36577246929
  • Tree
  • List 141
  • Changed 0
  • Source Changed 0
  • Coverage Changed 0
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Pull Request #826
  • PR Base - main (#36565007287)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc