Skip to content

feat: add post_highlight table to ClickHouse sync#3757

Closed
pnvasanth wants to merge 1 commit intomainfrom
add-post-highlight-clickhouse-sync
Closed

feat: add post_highlight table to ClickHouse sync#3757
pnvasanth wants to merge 1 commit intomainfrom
add-post-highlight-clickhouse-sync

Conversation

@pnvasanth
Copy link
Copy Markdown
Contributor

Summary

  • Add public.post_highlight to the Debezium table.include.list in ClickHouse sync config to replicate the table to ClickHouse

Test plan

  • Verify ClickHouse sync picks up the new table after deployment

@pulumi
Copy link
Copy Markdown

pulumi Bot commented Mar 30, 2026

🍹 The Update (preview) for dailydotdev/api/prod (at 178bd07) was successful.

✨ Neo Explanation

This is a standard application release rolling out a new build across all API services, cron jobs, and migration jobs, with the added change of a ClickHouse sync config update that will cause a brief restart of the sync service.

Root Cause Analysis

A new application version has been deployed. All API services and jobs are being updated from the previous build to a new one, and the ClickHouse sync service's configuration secret has changed, triggering a replacement of both the secret and the sync deployment.

Dependency Chain

  1. New app version → All 8 deployments (API, background workers, WebSocket, private, temporal, worker-job, personalized digest) are being rolled to the new container image
  2. New app version → All 37 CronJobs are updated to use the new image
  3. New app version → Old DB migration job and ClickHouse migration job (tagged to the previous build) are deleted, and new equivalents (tagged to the new build) are created to run any pending schema migrations
  4. ClickHouse sync config change (clickhouse-sync-clickhouse-sync-config secret data changed) → The secret must be replaced (create new + delete old), which in turn forces the clickhouse-sync deployment to also be replaced (torn down and recreated with the updated config)

Risk analysis

The clickhouse-sync deployment uses a Recreate strategy, meaning the existing pod will be terminated before the new one starts — causing a brief gap in ClickHouse sync coverage during the replacement. This is contained to the sync pipeline and does not affect the main API. All other deployments are rolling updates with no downtime risk. The migration jobs are one-shot and replace their prior versions cleanly.

Resource Changes

    Name                                                       Type                           Operation
+   vpc-native-api-db-migration-301cf1ce                       kubernetes:batch/v1:Job        create
~   vpc-native-personalized-digest-deployment                  kubernetes:apps/v1:Deployment  update
+-  clickhouse-sync-clickhouse-sync                            kubernetes:apps/v1:Deployment  create-replacement
~   vpc-native-update-current-streak-cron                      kubernetes:batch/v1:CronJob    update
~   vpc-native-temporal-deployment                             kubernetes:apps/v1:Deployment  update
~   vpc-native-user-profile-analytics-clickhouse-cron          kubernetes:batch/v1:CronJob    update
~   vpc-native-private-deployment                              kubernetes:apps/v1:Deployment  update
~   vpc-native-sync-subscription-with-cio-cron                 kubernetes:batch/v1:CronJob    update
-   vpc-native-api-clickhouse-migration-af1d8cf3               kubernetes:batch/v1:Job        delete
~   vpc-native-clean-zombie-user-companies-cron                kubernetes:batch/v1:CronJob    update
~   vpc-native-clean-zombie-opportunities-cron                 kubernetes:batch/v1:CronJob    update
~   vpc-native-calculate-top-readers-cron                      kubernetes:batch/v1:CronJob    update
~   vpc-native-bg-deployment                                   kubernetes:apps/v1:Deployment  update
~   vpc-native-personalized-digest-cron                        kubernetes:batch/v1:CronJob    update
~   vpc-native-clean-zombie-images-cron                        kubernetes:batch/v1:CronJob    update
~   vpc-native-clean-expired-better-auth-sessions-cron         kubernetes:batch/v1:CronJob    update
~   vpc-native-rotate-daily-quests-cron                        kubernetes:batch/v1:CronJob    update
~   vpc-native-clean-zombie-users-cron                         kubernetes:batch/v1:CronJob    update
~   vpc-native-worker-job-deployment                           kubernetes:apps/v1:Deployment  update
~   vpc-native-channel-highlights-cron                         kubernetes:batch/v1:CronJob    update
~   vpc-native-validate-active-users-cron                      kubernetes:batch/v1:CronJob    update
~   vpc-native-clean-gifted-plus-cron                          kubernetes:batch/v1:CronJob    update
~   vpc-native-rotate-weekly-quests-cron                       kubernetes:batch/v1:CronJob    update
~   vpc-native-generate-search-invites-cron                    kubernetes:batch/v1:CronJob    update
~   vpc-native-update-tag-recommendations-cron                 kubernetes:batch/v1:CronJob    update
~   vpc-native-update-views-cron                               kubernetes:batch/v1:CronJob    update
~   vpc-native-squad-posts-analytics-refresh-cron              kubernetes:batch/v1:CronJob    update
~   vpc-native-channel-digests-cron                            kubernetes:batch/v1:CronJob    update
~   vpc-native-expire-super-agent-trial-cron                   kubernetes:batch/v1:CronJob    update
~   vpc-native-update-tags-str-cron                            kubernetes:batch/v1:CronJob    update
~   vpc-native-deployment                                      kubernetes:apps/v1:Deployment  update
~   vpc-native-update-trending-cron                            kubernetes:batch/v1:CronJob    update
~   vpc-native-post-analytics-clickhouse-cron                  kubernetes:batch/v1:CronJob    update
~   vpc-native-ws-deployment                                   kubernetes:apps/v1:Deployment  update
+-  clickhouse-sync-clickhouse-sync-config                     kubernetes:core/v1:Secret      create-replacement
~   vpc-native-update-achievement-rarity-cron                  kubernetes:batch/v1:CronJob    update
~   vpc-native-user-profile-updated-sync-cron                  kubernetes:batch/v1:CronJob    update
~   vpc-native-clean-channel-highlights-cron                   kubernetes:batch/v1:CronJob    update
-   vpc-native-api-db-migration-af1d8cf3                       kubernetes:batch/v1:Job        delete
~   vpc-native-user-profile-analytics-history-clickhouse-cron  kubernetes:batch/v1:CronJob    update
~   vpc-native-user-posts-analytics-refresh-cron               kubernetes:batch/v1:CronJob    update
... and 12 other changes

@pnvasanth pnvasanth self-assigned this Mar 30, 2026
@pnvasanth pnvasanth force-pushed the add-post-highlight-clickhouse-sync branch from 11820b8 to 178bd07 Compare March 30, 2026 12:27
@pnvasanth pnvasanth closed this Mar 30, 2026
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