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

Merged
merged 7 commits into from
Jan 23, 2025
Merged

Add deck gateway apply command #1459

merged 7 commits into from
Jan 23, 2025

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 103 lines in your changes missing coverage. Please review.

Project coverage is 29.16%. Comparing base (412ad16) to head (0236bb2).

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% 8 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.53%   29.16%   -0.37%     
==========================================
  Files          61       62       +1     
  Lines        6583     6666      +83     
==========================================
  Hits         1944     1944              
- Misses       4500     4583      +83     
  Partials      139      139              

☔ 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 4 times, most recently from 1aaa089 to 226f98f Compare January 7, 2025 12:47
@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 force-pushed the apply-command branch 2 times, most recently from 7d2d789 to 3364815 Compare January 8, 2025 14:14
@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.

mheap added 4 commits January 22, 2025 15:49
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 22, 2025

@Prashansa-K I've rebased on main and enabled the test that was previously failing. Please review and merge when possible

tests/integration/apply_test.go Outdated Show resolved Hide resolved
@Prashansa-K Prashansa-K merged commit e44874a into main Jan 23, 2025
21 checks passed
@Prashansa-K Prashansa-K deleted the apply-command branch January 23, 2025 08:04
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