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

Chaguar / committer / 36569473496
91%
main: 91%

Build:
Build:
LAST BUILD BRANCH: bench/sidecar-end-to-end
DEFAULT BRANCH: main
Ran 29 Sep 2026 12:43PM UTC
Jobs 3
Files 142
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 12:28PM UTC coverage: 90.593% (-0.1%) from 90.735%
36569473496

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 9 files covered. (90.53%)

171 existing lines in 12 files now uncovered.

9823 of 10843 relevant lines covered (90.59%)

10101.27 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
76.86
2.08% utils/statedb/snapshot_state.go

Coverage Regressions

Lines Coverage ∆ File
75
80.98
-1.23% service/sidecar/sidecar.go
32
84.16
-0.11% service/vc/database_snapshot.go
23
76.86
2.08% utils/statedb/snapshot_state.go
11
91.41
-0.52% service/vc/validator_committer_service.go
7
93.43
-3.5% service/coordinator/coordinator.go
6
85.29
0.0% service/vc/database.go
5
94.34
-2.78% mock/coordinator.go
4
95.58
0.08% mock/vcservice.go
4
74.26
-3.96% service/vc/validator.go
2
97.22
0.0% service/verifier/verifier_server.go
1
96.2
-1.27% mock/sigverifier.go
1
76.0
-2.0% utils/utils.go
Jobs
ID Job ID Ran Files Coverage
1 db-test - 36569473496.1 29 Sep 2026 12:43PM UTC 142
78.12
GitHub Action Run
2 unit-test - 36569473496.2 29 Sep 2026 12:44PM UTC 96
86.09
GitHub Action Run
3 core-db-test - 36569473496.3 29 Sep 2026 12:45PM UTC 109
49.09
GitHub Action Run
Source Files on build 36569473496
  • Tree
  • List 142
  • 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