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

Avoid listing labeled resources for newly created app #659

Merged
merged 3 commits into from
Jan 19, 2023

Conversation

kumaritanushree
Copy link
Contributor

What this PR does / why we need it:

When we deploy an app, we first list the labeled resources (GVs) and then try to get the non labeled resources one by one one that are not found in the first step. When an app is deployed for the first time, the first step would always return nil.

This PR has changes to avoid listing labeled resources for newly created app

Which issue(s) this PR fixes:

Fixes #599

Does this PR introduce a user-facing change?


Additional Notes for your reviewer:

Review Checklist:
  • Follows the developer guidelines
  • Relevant tests are added or updated
  • Relevant docs in this repo added or updated
  • Relevant carvel.dev docs added or updated in a separate PR and there's
    a link to that PR
  • Code is at least as readable and maintainable as it was before this
    change

Additional documentation e.g., Proposal, usage docs, etc.:


Copy link
Contributor

@100mik 100mik left a comment

Choose a reason for hiding this comment

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

A few nitpicks!

pkg/kapp/cmd/app/deploy.go Outdated Show resolved Hide resolved
pkg/kapp/cmd/app/deploy.go Outdated Show resolved Hide resolved
pkg/kapp/cmd/app/deploy.go Outdated Show resolved Hide resolved
@kumaritanushree kumaritanushree mentioned this pull request Dec 14, 2022
12 tasks
@kumaritanushree kumaritanushree marked this pull request as draft December 16, 2022 07:44
@kumaritanushree kumaritanushree marked this pull request as ready for review December 27, 2022 11:23
Copy link
Contributor

@sethiyash sethiyash left a comment

Choose a reason for hiding this comment

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

LGTM!

@100mik
Copy link
Contributor

100mik commented Jan 4, 2023

The changes themselves look good to me!
I am good with this after we add a test making sure that we are including non-labelled resources.

test/e2e/app_deploy_test.go Outdated Show resolved Hide resolved
test/e2e/app_deploy_test.go Outdated Show resolved Hide resolved
Copy link
Contributor

@100mik 100mik left a comment

Choose a reason for hiding this comment

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

The changes look good to me! Just a few clarifications

test/e2e/create_update_delete_test.go Show resolved Hide resolved
test/e2e/create_update_delete_test.go Show resolved Hide resolved
@praveenrewar praveenrewar merged commit 94ff68d into develop Jan 19, 2023
@praveenrewar praveenrewar deleted the avoid-list-labledRes-for-newApp branch February 21, 2023 07:18
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.

Performance enhancements
7 participants