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

Add deck gateway apply command #1459

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open

Add deck gateway apply command #1459

wants to merge 5 commits into from

Conversation

mheap
Copy link
Member

@mheap mheap commented Dec 2, 2024

Depends on Kong/go-database-reconciler#143 being merged and released


The deck gateway apply command allows you to apply partial configuration to a running Gateway instance.

To do this, it runs a sync with the NoDeletes flag enabled. This means that only new and existing resources are updated. Existing resources that do not exist in the declarative configuration file are left untouched.

@mheap mheap requested a review from Prashansa-K December 2, 2024 17:50
@codecov-commenter
Copy link

codecov-commenter commented Dec 2, 2024

Codecov Report

Attention: Patch coverage is 0% with 104 lines in your changes missing coverage. Please review.

Project coverage is 29.12%. Comparing base (caaf75c) to head (3364815).

Files with missing lines Patch % Lines
cmd/common.go 0.00% 56 Missing ⚠️
cmd/gateway_apply.go 0.00% 34 Missing ⚠️
tests/integration/test_utils.go 0.00% 9 Missing ⚠️
cmd/common_konnect.go 0.00% 1 Missing ⚠️
cmd/gateway_diff.go 0.00% 1 Missing ⚠️
cmd/gateway_reset.go 0.00% 1 Missing ⚠️
cmd/gateway_sync.go 0.00% 1 Missing ⚠️
cmd/root.go 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1459      +/-   ##
==========================================
- Coverage   29.43%   29.12%   -0.31%     
==========================================
  Files          61       62       +1     
  Lines        6537     6620      +83     
==========================================
+ Hits         1924     1928       +4     
- Misses       4474     4554      +80     
+ Partials      139      138       -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@mheap mheap marked this pull request as draft December 2, 2024 20:28
@mheap
Copy link
Member Author

mheap commented Dec 2, 2024

Converting to draft. I'm adding tests and they're uncovering some issues

@mheap mheap marked this pull request as ready for review January 7, 2025 10:38
@mheap mheap force-pushed the apply-command branch 3 times, most recently from 8f78216 to a689d0d Compare January 7, 2025 11:15
@mheap mheap marked this pull request as draft January 7, 2025 11:31
@mheap mheap force-pushed the apply-command branch 3 times, most recently from b19c773 to 1aaa089 Compare January 7, 2025 11:58
The `deck gateway apply` command allows you to apply partial
configuration to a running Gateway instance.

To do this, it runs a `sync` with the NoDeletes flag enabled.
This means that only new and existing resources are updated.
Existing resources that do not exist in the declarative
configuration file are left untouched.
@mheap
Copy link
Member Author

mheap commented Jan 7, 2025

This is now ready for review. Once Kong/go-database-reconciler#143 is merged we can update go.mod in this PR too

@mheap
Copy link
Member Author

mheap commented Jan 7, 2025

Failing tests are due to #1483

@mheap mheap marked this pull request as ready for review January 8, 2025 15:37
@Prashansa-K
Copy link
Contributor

Just need to fix the commented out test-case. Rest looks good.

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.

3 participants