Skip to content

fix(volumesnapshots,cnpg-i): ensure CheckEmptyWalArchive runs during WAL restore - #9306

Merged
gbartolini merged 1 commit into
mainfrom
dev/9305
Nov 27, 2025
Merged

gbartolini merged 1 commit into
mainfrom
dev/9305

Conversation

@mnencia

@mnencia mnencia commented Nov 24, 2025 •

Copy link
Copy Markdown
Member

The CheckEmptyWalArchive safeguard was not executed when restoring from a volume snapshot using a CNPG-I backup/WAL plugin (e.g. plugin-barman-cloud).
This was due to the operator skipping creation of the CheckEmptyWalArchiveFile marker and relying instead on an early direct call to the in-tree barman-cloud-check-wal-archive command—an approach incompatible with external plugins.

This patch ensures that the CheckEmptyWalArchive mechanism is triggered reliably for both in-tree and plugin-based WAL archive implementations during snapshot restore.

Closes #9305

@mnencia
mnencia requested a review from a team November 24, 2025 09:48
@dosubot dosubot Bot added the size:S This PR changes 10-29 lines, ignoring generated files. label Nov 24, 2025
@cnpg-bot cnpg-bot added backport-requested ◀️ This pull request should be backported to all supported releases release-1.25 labels Nov 24, 2025
@github-actions

Copy link
Copy Markdown
Contributor

❗ By default, the pull request is configured to backport to all release branches.

  • To stop backporting this pr, remove the label: backport-requested ◀️ or add the label 'do not backport'
  • To stop backporting this pr to a certain release branch, remove the specific branch label: release-x.y

@dosubot dosubot Bot added bug 🐛 Something isn't working ok to merge 👌 This PR can be merged labels Nov 24, 2025
@mnencia

mnencia commented Nov 24, 2025

Copy link
Copy Markdown
Member Author

/test

@github-actions

Copy link
Copy Markdown
Contributor

@mnencia
mnencia force-pushed the dev/9305 branch 3 times, most recently from d743538 to 4444fbf Compare November 24, 2025 10:49
@mnencia mnencia changed the title fix(restore): ensure destination WAL archive path is empty on CNPG-I plugin restore fix(volumesnapshots): check empty wal archive on CNPG-I plugin restore Nov 24, 2025
@mnencia

mnencia commented Nov 24, 2025

Copy link
Copy Markdown
Member Author

/test

@github-actions

Copy link
Copy Markdown
Contributor

@mnencia

mnencia commented Nov 24, 2025

Copy link
Copy Markdown
Member Author

/test

@github-actions

Copy link
Copy Markdown
Contributor

@dosubot dosubot Bot added the lgtm This PR has been approved by a maintainer label Nov 25, 2025
@gbartolini gbartolini changed the title fix(volumesnapshots): check empty wal archive on CNPG-I plugin restore fix(volumesnapshots): ensure CheckEmptyWalArchive runs with CNPG-I plugin restore Nov 26, 2025
@gbartolini gbartolini changed the title fix(volumesnapshots): ensure CheckEmptyWalArchive runs with CNPG-I plugin restore fix(volumesnapshots,cnpg-i): ensure CheckEmptyWalArchive runs during WAL restore Nov 26, 2025
@gbartolini
gbartolini merged commit 01e673d into main Nov 27, 2025
@gbartolini
gbartolini deleted the dev/9305 branch November 27, 2025 10:29
cnpg-bot pushed a commit that referenced this pull request Nov 27, 2025
…g WAL restore (#9306)

The `CheckEmptyWalArchive` safeguard was not executed when restoring
from a volume snapshot using a CNPG-I backup/WAL plugin (e.g.
`plugin-barman-cloud`).
This was due to the operator skipping creation of the
`CheckEmptyWalArchiveFile` marker and relying instead on an early direct
call to the in-tree `barman-cloud-check-wal-archive` command—an approach
incompatible with external plugins.

This patch ensures that the `CheckEmptyWalArchive` mechanism is
triggered reliably for both in-tree and plugin-based WAL archive
implementations during snapshot restore.

Closes #9305

Signed-off-by: Marco Nenciarini <[email protected]>
(cherry picked from commit 01e673d)
cnpg-bot pushed a commit that referenced this pull request Nov 27, 2025
…g WAL restore (#9306)

The `CheckEmptyWalArchive` safeguard was not executed when restoring
from a volume snapshot using a CNPG-I backup/WAL plugin (e.g.
`plugin-barman-cloud`).
This was due to the operator skipping creation of the
`CheckEmptyWalArchiveFile` marker and relying instead on an early direct
call to the in-tree `barman-cloud-check-wal-archive` command—an approach
incompatible with external plugins.

This patch ensures that the `CheckEmptyWalArchive` mechanism is
triggered reliably for both in-tree and plugin-based WAL archive
implementations during snapshot restore.

Closes #9305

Signed-off-by: Marco Nenciarini <[email protected]>
(cherry picked from commit 01e673d)
cnpg-bot pushed a commit that referenced this pull request Nov 27, 2025
…g WAL restore (#9306)

The `CheckEmptyWalArchive` safeguard was not executed when restoring
from a volume snapshot using a CNPG-I backup/WAL plugin (e.g.
`plugin-barman-cloud`).
This was due to the operator skipping creation of the
`CheckEmptyWalArchiveFile` marker and relying instead on an early direct
call to the in-tree `barman-cloud-check-wal-archive` command—an approach
incompatible with external plugins.

This patch ensures that the `CheckEmptyWalArchive` mechanism is
triggered reliably for both in-tree and plugin-based WAL archive
implementations during snapshot restore.

Closes #9305

Signed-off-by: Marco Nenciarini <[email protected]>
(cherry picked from commit 01e673d)
mnencia added a commit that referenced this pull request Jan 20, 2026
…g WAL restore (#9306)

The `CheckEmptyWalArchive` safeguard was not executed when restoring
from a volume snapshot using a CNPG-I backup/WAL plugin (e.g.
`plugin-barman-cloud`).
This was due to the operator skipping creation of the
`CheckEmptyWalArchiveFile` marker and relying instead on an early direct
call to the in-tree `barman-cloud-check-wal-archive` command—an approach
incompatible with external plugins.

This patch ensures that the `CheckEmptyWalArchive` mechanism is
triggered reliably for both in-tree and plugin-based WAL archive
implementations during snapshot restore.

Closes #9305

Signed-off-by: Marco Nenciarini <[email protected]>
(cherry picked from commit 01e673d)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport-requested ◀️ This pull request should be backported to all supported releases bug 🐛 Something isn't working lgtm This PR has been approved by a maintainer ok to merge 👌 This PR can be merged size:S This PR changes 10-29 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: CheckEmptyWalArchive doesn't run with volumesnapshots and CNPG-I plugin restores

5 participants