Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(clustering/sync): validate deltas #14127

Open
wants to merge 27 commits into
base: master
Choose a base branch
from

Conversation

chobits
Copy link
Contributor

@chobits chobits commented Jan 10, 2025

Summary

  1. validate entity schema
    • run original full sync logic
  2. validate entity's references (foreign references)
    • re-implemented logic: traverse delta -> try to find delta's foreign entity in config & LMDB

Checklist

  • The Pull Request has tests
  • A changelog file has been created under changelog/unreleased/kong or skip-changelog label added on PR if changelog is unnecessary. README.md
  • There is a user-facing docs PR against https://github.com/Kong/docs.konghq.com - PUT DOCS PR HERE

Issue reference

Fix KAG-5897

@chronolaw chronolaw changed the title feat(sync): validate deltas feat(clustering/sync): validate deltas Jan 10, 2025
kong/clustering/services/sync/validate.lua Outdated Show resolved Hide resolved
kong/clustering/services/sync/validate.lua Outdated Show resolved Hide resolved
kong/db/schema/others/declarative_config.lua Outdated Show resolved Hide resolved
kong/db/schema/others/declarative_config.lua Outdated Show resolved Hide resolved
@github-actions github-actions bot added core/clustering core/db schema-change-noteworthy cherry-pick kong-ee schedule this PR for cherry-picking to kong/kong-ee labels Jan 13, 2025
@chobits chobits force-pushed the feat/sync_validate_deltas branch from 888f1a4 to 281683a Compare January 13, 2025 08:06
spec/fixtures/dc_blueprints.lua Show resolved Hide resolved
spec/internal/db.lua Show resolved Hide resolved
kong/db/schema/others/declarative_config.lua Outdated Show resolved Hide resolved
kong/db/schema/others/declarative_config.lua Outdated Show resolved Hide resolved
kong/db/schema/others/declarative_config.lua Outdated Show resolved Hide resolved
@chobits chobits force-pushed the feat/sync_validate_deltas branch from 1311558 to 34a04dd Compare January 14, 2025 02:14
@chronolaw chronolaw requested a review from Water-Melon January 14, 2025 02:22
kong/db/schema/others/declarative_config.lua Outdated Show resolved Hide resolved
kong/db/schema/others/declarative_config.lua Outdated Show resolved Hide resolved
kong/db/schema/others/declarative_config.lua Outdated Show resolved Hide resolved
kong/db/declarative/init.lua Outdated Show resolved Hide resolved
kong/db/schema/others/declarative_config.lua Outdated Show resolved Hide resolved
kong/init.lua Outdated Show resolved Hide resolved
@chobits chobits force-pushed the feat/sync_validate_deltas branch from 022b490 to ec2e241 Compare January 15, 2025 02:45
@chobits
Copy link
Contributor Author

chobits commented Jan 15, 2025

cherry-pick in advance: https://github.com/Kong/kong-ee/pull/11065

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants