Skip to content

CP-14164 - Backfill + normalize ATS-pointed webhooks#75

Open
bernardodsanderson wants to merge 1 commit into
mainfrom
CP-14164
Open

CP-14164 - Backfill + normalize ATS-pointed webhooks#75
bernardodsanderson wants to merge 1 commit into
mainfrom
CP-14164

Conversation

@bernardodsanderson

Copy link
Copy Markdown
Collaborator

CP-14164

What

Adds a one-time, idempotent task that creates missing ATS-pointed WebhookUrls and normalizes stale ones for every Account and Partnership. Stale rows (notably the ~22 pre-existing rows missing submission.completed) are updated to the canonical event set so non-approval forms complete-sync again.

Why

The on-create provisioning callback only fires for records created after the CAREERPLUG_WEBHOOK_URL/SECRET env vars were set, so pre-existing DocuSeal accounts/partnerships were never covered, and migration-seeded rows carry an old event set missing submission.completed. This caused DocuSeal task completions to stop syncing to the ATS. Prod dry-run confirmed 22 stale rows (needing update), 18 accounts + 5 partnerships with no webhook (needing create), and zero URL drift.

How to test

DRY_RUN=1 bundle exec rake webhooks:backfill_careerplug bundle exec rake webhooks:backfill_careerplug

What
Adds a one-time, idempotent task that creates missing ATS-pointed WebhookUrls
and normalizes stale ones for every Account and Partnership. Stale rows
(notably the ~22 pre-existing rows missing submission.completed) are updated
to the canonical event set so non-approval forms complete-sync again.

Why
The on-create provisioning callback only fires for records created after the
CAREERPLUG_WEBHOOK_URL/SECRET env vars were set, so pre-existing DocuSeal
accounts/partnerships were never covered, and migration-seeded rows carry an
old event set missing submission.completed. This caused DocuSeal task
completions to stop syncing to the ATS. Prod dry-run confirmed 22 stale rows
(needing update), 18 accounts + 5 partnerships with no webhook (needing
create), and zero URL drift.

How to test
DRY_RUN=1 bundle exec rake webhooks:backfill_careerplug
bundle exec rake webhooks:backfill_careerplug
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