Skip to content

Avoid blocking auto-standby holds on persistence - #415

Draft
sjmiller609 wants to merge 2 commits into
mainfrom
hypeship/unblock-autostandby-holds
Draft

Avoid blocking auto-standby holds on persistence#415
sjmiller609 wants to merge 2 commits into
mainfrom
hypeship/unblock-autostandby-holds

Conversation

@sjmiller609

@sjmiller609 sjmiller609 commented Aug 14, 2026

Copy link
Copy Markdown
Collaborator

summary

  • move auto-standby runtime metadata writes outside the controller state mutex
  • serialize writes per instance and discard superseded updates so persisted runtime follows controller mutation order
  • preserve operation-specific persistence error context
  • add regression coverage for blocked persistence, cross-instance isolation, superseded generations, and instance deletion

why

Runtime metadata persistence can wait on instance storage while holding the controller-wide mutex. That delays unrelated auto-standby holds and adds latency before browser traffic can be forwarded.

tests

  • go test -race -count=10 ./lib/autostandby
  • go vet ./lib/autostandby
  • go test ./... (partial: packages unrelated to this change fail because embedded binaries and mkfs.erofs are unavailable; lib/autostandby passes)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant