Skip to content
edgesync Check-in [ab2db30284]
Login

Check-in [ab2db30284]

Overview
Comment:refactor(leaf/agent): use libfossil v0.5.0 UUIDFromRID + whole-checkin Diff (#124)

Cleans up two workarounds in code_artifact.go that existed only because libfossil v0.4.x didn't expose them as first-class APIs:

- Delete the ridToUUID helper (raw SQL probe of libfossil's blob table). Replaced with r.UUIDFromRID(rid) at both callsites: Agent.Tip and Agent.toSyncResult.

- Collapse Agent.Diff from ~25 LOC of file enumeration to a single r.Diff(ridA, ridB, "") call. Uses libfossil v0.5.0's Option-A whole- checkin form. Also fixes wrong-ish rename-detection in the previous hand-rolled implementation.

Adds TestAgent_Diff_RenameAcrossRevs to exercise the rename case the old enumeration got wrong.

Closes #112

Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: ab2db30284acace93034bd84d7ea3705ef3a7cdd58ca323a383b692ad23859e5
User & Date: [email protected] on 2026-05-04 19:33:21.000
Other Links: manifest | tags
Context
2026-05-04
19:44
test(sim): hub + leaf agent end-to-end integration test (#126)

Adds sim/hub_leaf_test.go: a real *hub.Hub bound to auto-allocated ports, a real *agent.Agent built against a leaf repo cloned from the hub, and a round-trip Commit + SyncTo + Hub.ReadAt that exercises the HTTP-xfer path end-to-end.

Without this test, the kind of cross-component regression bones surfaced in #120 (the SetMaxOpenConns deadlock under concurrent clones) only shows up downstream. With it, EdgeSync's own CI catches it.

Wired into the existing 'Sim serve tests' step (Makefile + test.yml) alongside TestServeHTTP/TestLeafToLeaf/TestAgentServe so the test runs on every PR.

Closes #113 check-in: 995066ac2a user: [email protected] tags: trunk

19:33
refactor(leaf/agent): use libfossil v0.5.0 UUIDFromRID + whole-checkin Diff (#124)

Cleans up two workarounds in code_artifact.go that existed only because libfossil v0.4.x didn't expose them as first-class APIs:

- Delete the ridToUUID helper (raw SQL probe of libfossil's blob table). Replaced with r.UUIDFromRID(rid) at both callsites: Agent.Tip and Agent.toSyncResult.

- Collapse Agent.Diff from ~25 LOC of file enumeration to a single r.Diff(ridA, ridB, "") call. Uses libfossil v0.5.0's Option-A whole- checkin form. Also fixes wrong-ish rename-detection in the previous hand-rolled implementation.

Adds TestAgent_Diff_RenameAcrossRevs to exercise the rename case the old enumeration got wrong.

Closes #112 check-in: ab2db30284 user: [email protected] tags: trunk

19:24
chore: bump leaf v0.0.7 → v0.0.8 (#123)

Pulls in the SetMaxOpenConns(1) deadlock fix (#120/PR #122) and the libfossil v0.5.0 baseline (PR #121).

This is the version downstream consumers should pin to instead of v0.0.7 (which deterministically deadlocks under concurrent clones). check-in: ca812c4f85 user: [email protected] tags: trunk, v0.0.10

Changes