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

fix: do not error out on EE endpoints with no license #821

Merged
merged 1 commit into from
Jan 24, 2023

Conversation

GGabriele
Copy link
Collaborator

Right now decK error out when the Consumer Groups and Vaults list endpoints are hit and no license is present in the Gateway.
In such case, decK should continue its flow.

@GGabriele GGabriele requested a review from a team January 13, 2023 13:56
@GGabriele GGabriele temporarily deployed to Configure ci January 13, 2023 13:56 — with GitHub Actions Inactive
@GGabriele GGabriele temporarily deployed to Configure ci January 13, 2023 13:56 — with GitHub Actions Inactive
@codecov-commenter
Copy link

codecov-commenter commented Jan 13, 2023

Codecov Report

Base: 35.44% // Head: 35.44% // No change to project coverage 👍

Coverage data is based on head (c03e6ac) compared to base (10ac89d).
Patch coverage: 0.00% of modified lines in pull request are covered.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #821   +/-   ##
=======================================
  Coverage   35.44%   35.44%           
=======================================
  Files          92       92           
  Lines       11245    11245           
=======================================
  Hits         3986     3986           
  Misses       6862     6862           
  Partials      397      397           
Impacted Files Coverage Δ
dump/dump.go 1.41% <0.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@@ -248,7 +248,7 @@ func getProxyConfiguration(ctx context.Context, group *errgroup.Group,
consumerGroups, err = GetAllConsumerGroups(ctx, client, config.SelectorTags)
}
if err != nil {
if kong.IsNotFoundErr(err) {
if kong.IsNotFoundErr(err) || kong.IsForbiddenErr(err) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

since we are just returning nil will they see a warning about this too?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

They will only see the status code in verbose mode. Do you think we should log a warning too?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could be a good idea, but we can keep this as is for this PR.

aboudreault
aboudreault previously approved these changes Jan 13, 2023
Right now decK error out when the Consumer Groups and
Vaults list endpoints are hit and no license is present in the
Gateway.
In such case, decK should continue its flow.
@GGabriele GGabriele temporarily deployed to Configure ci January 24, 2023 08:58 — with GitHub Actions Inactive
@GGabriele GGabriele temporarily deployed to Configure ci January 24, 2023 08:59 — with GitHub Actions Inactive
@GGabriele GGabriele merged commit 3e4511b into main Jan 24, 2023
@GGabriele GGabriele deleted the fix/list-ee-endpoints branch January 24, 2023 09:03
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