Skip to content

feat: make the queue volume optional - #198

Open
armru wants to merge 2 commits into
mainfrom
dev/135
Open

feat: make the queue volume optional#198
armru wants to merge 2 commits into
mainfrom
dev/135

Conversation

@armru

@armru armru commented Aug 31, 2026

Copy link
Copy Markdown
Member

A Server had to declare a queue PVC whenever tier1 was configured. The queue
only needs durable storage, not a volume of its own, so the queue section is
now optional: when omitted, the queue lives in the queue directory of the
tier1 data volume. A dedicated volume is still recommended in production, so
that a full data volume cannot also stall the queue that drives retention.

Adding or removing the section moves the queue during the resulting rolling
restart: the server copies it from the previous location, named by
QUEUE_MIGRATION_SOURCE, before opening it. On removal the StatefulSet stops
templating the queue PVC, which is then kept mounted by claim name until it is
deleted by hand.

Closes #135

@armru
armru force-pushed the dev/135 branch 2 times, most recently from 87a6d4a to af2a787 Compare September 1, 2026 13:54
The work queue can now live either on its own volume or inside the tier1
data volume, so the server has to relocate it when the Server resource
changes which one it is. QUEUE_MIGRATION_SOURCE names the previous
location: its content is copied into QUEUE_DIRECTORY before the queue is
opened, then removed.

The copy is staged next to the destination and fsynced before the rename,
so an interrupted migration never leaves a partial queue behind. A
non-empty destination always wins, as it holds the WAL files still
pending transfer to tier2.

Signed-off-by: Armando Ruocco <armando.ruocco@enterprisedb.com>
The queue only needs durable storage, not a volume of its own, so the
`queue` section is no longer required alongside tier1: when omitted, the
queue lives in the `queue` directory of the tier1 data volume. A dedicated
volume is still recommended in production, so that a full data volume
cannot also stall the queue that drives retention.

Adding or removing the section moves the queue during the resulting
rolling restart. On removal the StatefulSet stops templating the queue
PVC, which is then kept mounted by claim name until it is deleted by hand.

Signed-off-by: Armando Ruocco <armando.ruocco@enterprisedb.com>
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.

Make queue volume optional

1 participant