René's URL Explorer Experiment


Title: Restore drill: compare the restored rows with the dump, dump globals by shipmill-romamo[bot] · Pull Request #236 · cloudfall-dev/cloudfall · GitHub

Open Graph Title: Restore drill: compare the restored rows with the dump, dump globals by shipmill-romamo[bot] · Pull Request #236 · cloudfall-dev/cloudfall

X Title: Restore drill: compare the restored rows with the dump, dump globals by shipmill-romamo[bot] · Pull Request #236 · cloudfall-dev/cloudfall

Description: Plan Serves: G-3 Files: engine/ansible/roles/cloudfall_postgresql/templates/restore-check.sh.j2, backup.sh.j2, tasks/main.yml, sdk/src/cloudfall/validation.py, the golden example scripts, engine/README.md, tests in engine/tests/test_postgresql_restore_drill.py, test_postgresql_templates.py, sdk/tests/test_validation.py Order: a failing test that runs the rendered drill against stand-ins for the PostgreSQL tools (an empty restore passed on main), then the drill fix, the scratch-name rule, the globals dump, the docs Proof: engine/tests/test_postgresql_restore_drill.py (empty restore, row mismatch and table-less dump fail; a matching restore passes; the role's scratch-name assert), sdk/tests/test_validation.py::test_service_rejects_a_database_named_as_a_restore_drill_scratch, test_backup_script_dumps_the_globals_beside_the_databases Summary The restore-drill and globals part of #225, as agreed in the triage; the off-host copy, OnFailure= and the backup-age alert stay on the issue for their spec. The drill compares rows with the dump. It used to count pg_class rows, which an empty database has too, so a restore that brought back nothing passed. It now reads one schema.tablerows line per data block of the dump (pg_restore --data-only, piped through awk), counts every table of the restored scratch database with the same exact count(*) through query_to_xml that data copy uses, and fails when any table of the dump is missing or has another count. A dump that holds no table fails too. The expected counts come from the dump rather than the live database: pg_dump read them from one snapshot of the source, so writes since then can't make the drill fail. The pass line now reads restore check passed for crm: (3 tables, 5 rows, as in the dump), which lands in the BackupReceipt summary The scratch name can't be a declared database. _restore_check keeps the first 49 characters of the name, so it stays within PostgreSQL's 63-byte identifiers. Before, a 63-character database name and its scratch name were cut to the same identifier. cloudfall config validate (code service_database_restore_check_name) and the role's first asserts refuse a declared database that carries another's scratch name Globals beside the dumps. backup.sh writes globals-.sql from pg_dumpall --globals-only --no-role-passwords into the backup directory, and retention prunes it with the dumps. Role passwords stay out because converge sets each owner role's password from its secret. engine/README.md says where the file is and in which order a fresh-server restore loads it Test notes Reproduced first: on main, the new drill test with an empty restore exited 0 with ( catalog relations) Ran uv run ruff check ., uv run mypy, and uv run pytest on engine/tests/test_postgresql_restore_drill.py, test_postgresql_templates.py, test_postgresql_owner_role.py, test_examples_render_unchanged.py, sdk/tests/test_validation.py and test_owned_postgresql.py: all green. The full suite is left to CI The S-006-12 golden backup.sh and restore-check.sh are re-rendered from the new templates (intended change) ansible-lint passed for engine/ansible/roles/cloudfall_postgresql. A whole-tree run here, through python -m ansiblelint (the session can't run the ansible-lint entry directly), reported five syntax-check "role not found" errors in playbooks this PR doesn't touch, so CI's uv run ansible-lint engine/ansible decides Not exercised against a real PostgreSQL: the awk parser was checked on pg_dump's script shape (quoted names, a table without columns, a data row containing FROM stdin;) through stand-ins, not on a live dump Part of #225 🤖 Generated with Claude Code

Open Graph Description: Plan Serves: G-3 Files: engine/ansible/roles/cloudfall_postgresql/templates/restore-check.sh.j2, backup.sh.j2, tasks/main.yml, sdk/src/cloudfall/validation.py, the golden example scripts, engine/R...

X Description: Plan Serves: G-3 Files: engine/ansible/roles/cloudfall_postgresql/templates/restore-check.sh.j2, backup.sh.j2, tasks/main.yml, sdk/src/cloudfall/validation.py, the golden example scripts, engine/R...

Opengraph URL: https://github.com/cloudfall-dev/cloudfall/pull/236

X: @github

direct link

Domain: github.com

IPv4 address: 140.82.114.3

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:d2d77872-034e-96e0-260a-fcd5780363c7
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-id8B84:2DC5AF:7BA743:AC6DDE:6B0598EA
html-safe-nonce6961b743ddc97f2b189b77201f4501eb94278adccf1e9b74aedef83f178be87b
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4Qjg0OjJEQzVBRjo3QkE3NDM6QUM2RERFOjZCMDU5OEVBIiwidmlzaXRvcl9pZCI6IjM3Mzk2NjgxNjcxODcwNzczNTQiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmac6b8a9964b1b59c68155985c14bde2bfd2e0eb9528d084988e0bf6b86d3b09d6f
hovercard-subject-tagpull_request:5292898393
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/cloudfall-dev/cloudfall/pull/236/files
twitter:imagehttps://avatars.githubusercontent.com/u/5600783?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/5600783?s=400&v=4
og:image:altPlan Serves: G-3 Files: engine/ansible/roles/cloudfall_postgresql/templates/restore-check.sh.j2, backup.sh.j2, tasks/main.yml, sdk/src/cloudfall/validation.py, the golden example scripts, engine/R...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
None3b72fd2385d76a50ce0fe937d50bb4a81434432c4fd47866074a26f6cd03623f
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/cloudfall-dev/cloudfall git https://github.com/cloudfall-dev/cloudfall.git
octolytics-dimension-user_id339512759
octolytics-dimension-user_logincloudfall-dev
octolytics-dimension-repository_id1360999777
octolytics-dimension-repository_nwocloudfall-dev/cloudfall
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id1360999777
octolytics-dimension-repository_network_root_nwocloudfall-dev/cloudfall
turbo-body-classeslogged-out env-production page-responsive full-width
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release58e2bd32336f3dcee343ec627a4d09c7c444e214
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/cloudfall-dev/cloudfall/pull/236/files#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fcloudfall-dev%2Fcloudfall%2Fpull%2F236%2Ffiles
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fcloudfall-dev%2Fcloudfall%2Fpull%2F236%2Ffiles
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=cloudfall-dev%2Fcloudfall
Reloadhttps://github.com/cloudfall-dev/cloudfall/pull/236/files
Reloadhttps://github.com/cloudfall-dev/cloudfall/pull/236/files
Reloadhttps://github.com/cloudfall-dev/cloudfall/pull/236/files
cloudfall-devhttps://github.com/cloudfall-dev
cloudfallhttps://github.com/cloudfall-dev/cloudfall
Codehttps://github.com/cloudfall-dev/cloudfall
Issues76 (76)https://github.com/cloudfall-dev/cloudfall/issues
Pull requests10 (10)https://github.com/cloudfall-dev/cloudfall/pulls
Discussionshttps://github.com/cloudfall-dev/cloudfall/discussions
Actionshttps://github.com/cloudfall-dev/cloudfall/actions
Security and qualityhttps://github.com/cloudfall-dev/cloudfall/security
Insightshttps://github.com/cloudfall-dev/cloudfall/insights
Sign up for GitHub https://github.com/signup?return_to=%2Fcloudfall-dev%2Fcloudfall%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://github.com/login?return_to=%2Fcloudfall-dev%2Fcloudfall%2Fissues%2Fnew%2Fchoose
shipmill-romamohttps://github.com/apps/shipmill-romamo
mainhttps://github.com/cloudfall-dev/cloudfall/tree/main
fix/225-restore-drillhttps://github.com/cloudfall-dev/cloudfall/tree/fix/225-restore-drill
Conversation 0 https://github.com/cloudfall-dev/cloudfall/pull/236
Commits 1 https://github.com/cloudfall-dev/cloudfall/pull/236/commits
Checks 1 https://github.com/cloudfall-dev/cloudfall/pull/236/checks
Files changed https://github.com/cloudfall-dev/cloudfall/pull/236/files
Please reload this pagehttps://github.com/cloudfall-dev/cloudfall/pull/236/files
Restore drill: compare the restored rows with the dump, dump globals https://github.com/cloudfall-dev/cloudfall/pull/236/files#top
Show all changes 1 commit https://github.com/cloudfall-dev/cloudfall/pull/236/files
1b44b34 Restore drill: compare the restored rows with the dump, dump globals shipmill-romamo[bot] Nov 13, 2026 https://github.com/cloudfall-dev/cloudfall/pull/236/commits/1b44b34f88ee48c42af59af7c7cad4c541f92c4d
Clear filters https://github.com/cloudfall-dev/cloudfall/pull/236/files
Please reload this pagehttps://github.com/cloudfall-dev/cloudfall/pull/236/files
Please reload this pagehttps://github.com/cloudfall-dev/cloudfall/pull/236/files
225-restore-drill.md https://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-ab01cd5cdbdf92d81088f5fe83fd75c8d4595076524e31a9dc2c71320c8acd98
README.md https://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-78692e5a5d793b5257775d62b6fb596b7a11b3757d7a9ee0414cbe44b1ef444b
main.yml https://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-222aae9cb38f9155023dd5a38041e3a078124cab5683bc89814291d3dde65683
backup.sh.j2 https://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-f51c458dbbfe3e7c5779973a34c286ad74c2bb6ed8ffbcff4e7f200eeeddd47f
restore-check.sh.j2 https://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-094814395558774027abcf44498a0cec0b6862133e6893bd29e17b58cfb5a015
backup.sh https://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-9bd4b8930a6d077cc58300a80d2916486c859f273de5fb503f83291b41c2371e
restore-check.sh https://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-d9d0aa9e98f27efa518337c85a190679d642739915f06f6169560b6d6f2a2ff6
test_postgresql_restore_drill.py https://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-f8bb91b0130355688ad893d263e0ba5be631b7a29e78bf1b3a00ff85ba4e0834
test_postgresql_templates.py https://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-55eaf50feb6b6a7c069432d0ba7433607bbd97b400638555d715b8e5ac21d6d0
validation.py https://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-49df42efb61e79803f6878b494a9f4020665a502abad42b22938158cf50f5f28
test_validation.py https://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-313b956e63152cc7dd8b9b340f90155c94d8dbba8d4f7603e68c5de74555bf4b
changelog.d/225-restore-drill.mdhttps://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-ab01cd5cdbdf92d81088f5fe83fd75c8d4595076524e31a9dc2c71320c8acd98
View file https://github.com/cloudfall-dev/cloudfall/blob/1b44b34f88ee48c42af59af7c7cad4c541f92c4d/changelog.d/225-restore-drill.md
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/cloudfall-dev/cloudfall/pull/236/{{ revealButtonHref }}
engine/README.mdhttps://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-78692e5a5d793b5257775d62b6fb596b7a11b3757d7a9ee0414cbe44b1ef444b
View file https://github.com/cloudfall-dev/cloudfall/blob/1b44b34f88ee48c42af59af7c7cad4c541f92c4d/engine/README.md
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/cloudfall-dev/cloudfall/pull/236/{{ revealButtonHref }}
https://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-78692e5a5d793b5257775d62b6fb596b7a11b3757d7a9ee0414cbe44b1ef444b
https://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-78692e5a5d793b5257775d62b6fb596b7a11b3757d7a9ee0414cbe44b1ef444b
engine/ansible/roles/cloudfall_postgresql/tasks/main.ymlhttps://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-222aae9cb38f9155023dd5a38041e3a078124cab5683bc89814291d3dde65683
View file https://github.com/cloudfall-dev/cloudfall/blob/1b44b34f88ee48c42af59af7c7cad4c541f92c4d/engine/ansible/roles/cloudfall_postgresql/tasks/main.yml
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/cloudfall-dev/cloudfall/pull/236/{{ revealButtonHref }}
https://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-222aae9cb38f9155023dd5a38041e3a078124cab5683bc89814291d3dde65683
https://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-222aae9cb38f9155023dd5a38041e3a078124cab5683bc89814291d3dde65683
engine/ansible/roles/cloudfall_postgresql/templates/backup.sh.j2https://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-f51c458dbbfe3e7c5779973a34c286ad74c2bb6ed8ffbcff4e7f200eeeddd47f
View file https://github.com/cloudfall-dev/cloudfall/blob/1b44b34f88ee48c42af59af7c7cad4c541f92c4d/engine/ansible/roles/cloudfall_postgresql/templates/backup.sh.j2
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/cloudfall-dev/cloudfall/pull/236/{{ revealButtonHref }}
https://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-f51c458dbbfe3e7c5779973a34c286ad74c2bb6ed8ffbcff4e7f200eeeddd47f
engine/ansible/roles/cloudfall_postgresql/templates/restore-check.sh.j2https://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-094814395558774027abcf44498a0cec0b6862133e6893bd29e17b58cfb5a015
View file https://github.com/cloudfall-dev/cloudfall/blob/1b44b34f88ee48c42af59af7c7cad4c541f92c4d/engine/ansible/roles/cloudfall_postgresql/templates/restore-check.sh.j2
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/cloudfall-dev/cloudfall/pull/236/{{ revealButtonHref }}
engine/tests/golden/examples/h1/postgresql-main/backup.shhttps://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-9bd4b8930a6d077cc58300a80d2916486c859f273de5fb503f83291b41c2371e
View file https://github.com/cloudfall-dev/cloudfall/blob/1b44b34f88ee48c42af59af7c7cad4c541f92c4d/engine/tests/golden/examples/h1/postgresql-main/backup.sh
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/cloudfall-dev/cloudfall/pull/236/{{ revealButtonHref }}
https://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-9bd4b8930a6d077cc58300a80d2916486c859f273de5fb503f83291b41c2371e
engine/tests/golden/examples/h1/postgresql-main/restore-check.shhttps://github.com/cloudfall-dev/cloudfall/pull/236/files#diff-d9d0aa9e98f27efa518337c85a190679d642739915f06f6169560b6d6f2a2ff6
View file https://github.com/cloudfall-dev/cloudfall/blob/1b44b34f88ee48c42af59af7c7cad4c541f92c4d/engine/tests/golden/examples/h1/postgresql-main/restore-check.sh
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/cloudfall-dev/cloudfall/pull/236/{{ revealButtonHref }}
Please reload this pagehttps://github.com/cloudfall-dev/cloudfall/pull/236/files
Please reload this pagehttps://github.com/cloudfall-dev/cloudfall/pull/236/files
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Response headers:
Servergithub.com
Content-Typetext/html; charset=utf-8
Cache-Controlno-cache

Viewport: width=device-width


URLs of crawlers that visited me.