Decide the publish transaction model: one FMRI per transaction vs many packages per transaction #26
Labels
No labels
Compat/Breaking
Crazy Idea
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Security
Kind/Testing
Priority/Critical
Priority/High
Priority/Low
Priority/Medium
Reviewed/Confirmed
Reviewed/Duplicate
Reviewed/Invalid
Reviewed/Won't Fix
Status/Abandoned
Status/Blocked
Status/Need More Info
needs-info
needs-triage
ready-for-agent
ready-for-human
wayfinder:grilling
wayfinder:map
wayfinder:prototype
wayfinder:research
wayfinder:task
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Blocks
Depends on
#3 Server Publish
OpenIndiana/ips
#38 V1: atomically ingest one multi-package p5p per CI run
OpenIndiana/ips
Reference
OpenIndiana/ips#26
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Part of #24
Read availability and catalog replacement — 2026-09-22
Maintainer decision: reads must remain available throughout imports and catalog rebuilds. Continue serving the previous complete catalog until the replacement is ready, then switch atomically by filesystem rename (
fs.rename), retaining the existing on-disk catalog pathname. No routine-ingestion maintenance outage.Implementation/verification obligations (not claims about current behavior): prepare replacement on the same filesystem; preserve consistency for existing readers and new readers; ensure every newly advertised manifest/payload is available before publication. Inspect actual SQLite/shard/sidecar layout and connection lifetimes: renaming one file must not be assumed to atomically replace a multi-file catalog or safely handle live WAL/SHM state. Design a consistent publication boundary that honors the stable-path rename requirement. Verify crash durability/recovery and real pkg5 requests across the switch, including failure before and after rename.
Maintainer decisions — 2026-09-22
V1 transaction boundary: one completed multi-package .p5p from one CI run, imported locally by a notified script. All packages become visible atomically or none do. Identical archive retries succeed as no-ops even after commit-before-ack crashes; exact-FMRI content conflicts reject the whole batch; identical existing packages can be skipped. Implement via #38.
REST publication and its multi-upload protocol are deferred with #3. This ticket remains open for local batch commit/recovery/locking design and ADR capture; do not block v1 on choosing deferred HTTP upload shapes.
These decisions supersede conflicting earlier scope below. This update records maintainer decisions, not implementation or test completion.
Earlier brief and context
Question
The plan in
docs/ai/plans/2026-04-09-publish-api-oidc.mdopens a transaction per FMRI (POST /{publisher}/open/0/{fmri}), while the Server Publish ticket (#3) wants one transaction to carry multiple archives or packages and to be resumable after a client crash. These conflict. Decide the model.Grill on:
status/0/{txn}returning still-needed hashes is in the plan; is the needed-file list computed from manifests only, and how are shared payloads across packages deduplicated?{repo}/trans/{id}/on disk (plan) vs SQLite state; recovery on server restart; abandonment policy (no timeout decided, but is there a manual sweep?).X-IPkg-File-Hash; archive upload endpoint as a batch transaction or a separate path.Zoom into
libips/src/repository/file_backend.rs(Transaction,begin_transaction,publish_files) anddoc/pkg5_docs/guide-publication-protocol.rstfor prior art. Record as an ADR and update the plan; the resolution should let/to-ticketsslice #3.Links
Closed as out of scope for Release 1 (wayfinder). Remote publication is deferred with no target release (maintainer, 2026-09-22), so there is no publish transaction to model. The local import model this question also covered is settled by ADR-007: many packages per import, validated whole, published by one generation switch, identical re-import a no-op, exact-FMRI conflict rejects the batch. Reopen or re-chart when remote publish is scheduled; research #32 still applies.