-
Notifications
You must be signed in to change notification settings - Fork 22
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
[feat] add a v1alpha2 version of LinodeObjectStorageBucket #427
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #427 +/- ##
==========================================
+ Coverage 64.65% 64.89% +0.23%
==========================================
Files 68 72 +4
Lines 3517 3606 +89
==========================================
+ Hits 2274 2340 +66
- Misses 1061 1081 +20
- Partials 182 185 +3 ☔ View full report in Codecov by Sentry. |
dst.ObjectMeta = src.ObjectMeta | ||
|
||
// Spec | ||
dst.Spec.Cluster = src.Spec.Region + "-1" |
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.
Is it guaranteed that cluster will be {region}-1
?
Of course, I can't imagine a world where anyone would be trying to convert to v1alpha1
. Is the reverse conversion from v1alpha2
to v1alpha1
actually necessary?
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 it is necessarily true that it will always be {region}-1
sounds like this might make downgrading pretty challenging here though
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.
^ while it has been true so far, the api now responds with a hostname
for a bucket - maybe we can infer the clusterID from it - not always guaranteed to work, but better than -1
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.
Agreed. For successfully provisioned v1alpha1 buckets, the hostname is stored as status.hostname
. If no status.hostname
has been set (i.e. status.ready
is false), then it's probably safe to default to {region}-1
since it'd be a no-op.
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.
going forward with {region}-1, while converting from v1alpha2 to v1alpha1.
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.
will v1alpha1 work without that conversion?
@@ -179,6 +179,175 @@ spec: | |||
type: object | |||
type: object | |||
served: true | |||
storage: false |
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.
you'd need to update the reference in config/crd/patches/capicontract_in_linodeobjectstoragebuckets.yaml
to v1alpha2
as well
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.
Hey @tchinmai7 , I have actually added that change in my local version. Will be pushing it out in a bit.
…inodeOBJBucket_v1alpha2
What this PR does / why we need it:
This PR adds LinodeObjectStorageBucket to the v1alpha2 version
Which issue(s) this PR fixes (optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)
format, will close the issue(s) when PR gets merged):Fixes #
This is the Step 2: for the two fold update mentioned in PR
Special notes for your reviewer:
TODOs: