-
Notifications
You must be signed in to change notification settings - Fork 192
Detect TKGS environment for any version of TKC API #2970
Detect TKGS environment for any version of TKC API #2970
Conversation
Hi @abhijit-dev82! And thank you for opening your first Pull Request. Someone will review it soon. Thank you for committing to making Tanzu Framework better. |
Codecov Report
@@ Coverage Diff @@
## main #2970 +/- ##
==========================================
+ Coverage 44.00% 44.15% +0.14%
==========================================
Files 416 416
Lines 41852 42141 +289
==========================================
+ Hits 18417 18607 +190
- Misses 21714 21809 +95
- Partials 1721 1725 +4
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor comments, but overall LGTM.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added a minor comment, but this LGTM!!
Can you add the link to the issue this pr is addressing and release note in the pr description? Also, can you squash the commits, when you are done addressing the comments? thanks..
@@ -38,7 +39,10 @@ func (dc *DiscoveryClient) IsTKGm(ctx context.Context) (bool, error) { | |||
|
|||
// IsTKGS returns true if the cluster is a TKGS cluster. | |||
func (dc *DiscoveryClient) IsTKGS(ctx context.Context) (bool, error) { | |||
return dc.HasTanzuKubernetesClusterV1alpha1(ctx) | |||
/* Check for TKGS on any TKC API version */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you make this a single line comment?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Taken care of the comment and squashed the commits.
e8ca17e
to
1c82278
Compare
@@ -36,9 +37,11 @@ func (dc *DiscoveryClient) IsTKGm(ctx context.Context) (bool, error) { | |||
return dc.HasInfrastructureProvider(ctx, InfrastructureProviderVsphere) | |||
} | |||
|
|||
// IsTKGS returns true if the cluster is a TKGS cluster. | |||
// IsTKGS returns true if the cluster is a TKGS cluster. Check for TKGS on any TKC API version */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// IsTKGS returns true if the cluster is a TKGS cluster. Check for TKGS on any TKC API version */ | |
// IsTKGS returns true if the cluster is a TKGS cluster. Checks for the existence of any TKC API version |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Corrected.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think the suggested change was committed?
Could you please change the commit message to be more meaningful? Something like Also, please fix build/test issues (or rebase if it's unrelated) before this can be merged. Thanks. |
1277276
to
bc901cc
Compare
bc901cc
to
7f5b9b2
Compare
Cluster Generation A/B Results: |
046a5b3
to
1d8fe0b
Compare
12dee8c
to
876c020
Compare
Modified capabilties API to a generic call Modified capabilties API to a generic call Modified capabilties API to a generic call Modified capabilties API to a generic call Modified capabilties API to a generic call Detect TKGS environment for any version of TKC API Detect TKGS environment for any version of TKC API
32af7bf
to
bd99430
Compare
What this PR does / why we need it
Which issue(s) this PR fixes
Fixes #2786
Describe testing done for PR
Added a new method in capabilties_test.go
Release note
Issue: #2786
IsTKGS () API function might break because TKC v1alpha1 is likely to be dropped soon.
PR Checklist
Additional information
Special notes for your reviewer