-
Notifications
You must be signed in to change notification settings - Fork 12
Generate with GoV2 and latest code-gen #109
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
Conversation
/close |
@michaelhtm: Closed this PR. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/reopen |
@michaelhtm: Reopened this PR. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
aad8566
to
17aea2e
Compare
69ee64e
to
1fd405e
Compare
ShowShardDetails: aws.Bool(true) |
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.
now it's crossing my mind.. it would be call if the code-gen it self handled the true
-> aws.Bool(true)
translation
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.
cool?
yeaa ikk..it should infer whether field is pointer or non-pointer...
"context" | ||
|
||
"github.com/pkg/errors" | ||
|
||
ackcompare "github.com/aws-controllers-k8s/runtime/pkg/compare" | ||
"github.com/aws-controllers-k8s/runtime/pkg/requeue" | ||
ackrtlog "github.com/aws-controllers-k8s/runtime/pkg/runtime/log" | ||
svcsdk "github.com/aws/aws-sdk-go/service/memorydb" | ||
svcsdk "github.com/aws/aws-sdk-go-v2/service/memorydb" | ||
svcsdktypes "github.com/aws/aws-sdk-go-v2/service/memorydb/types" | ||
|
||
svcapitypes "github.com/aws-controllers-k8s/memorydb-controller/apis/v1alpha1" | ||
svcutil "github.com/aws-controllers-k8s/memorydb-controller/pkg/util" |
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.
order fix please
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.
of course
The To/FromACKTags function signatures are changing with the next code-gen release. This PR aims to ensure custom code adapts as well.
1fd405e
to
9d79bc4
Compare
@@ -0,0 +1,17 @@ | |||
package util |
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.
license
pkg/util/convert.go
Outdated
func Int32OrNil(val *int64) *int32 { | ||
if val == nil { | ||
return nil | ||
} | ||
ret := int32(*val) | ||
return &ret | ||
} | ||
|
||
func Int64OrNil(val *int32) *int64 { | ||
if val == nil { | ||
return nil | ||
} | ||
ret := int64(*val) | ||
return &ret | ||
} |
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.
With generics you can make this one function
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.
let me see..
"github.com/aws/aws-sdk-go-v2/aws" | ||
svcsdk "github.com/aws/aws-sdk-go-v2/service/memorydb" | ||
svcsdktypes "github.com/aws/aws-sdk-go-v2/service/memorydb/types" | ||
"github.com/samber/lo" | ||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" |
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.
order
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.
Sweet, thanks @michaelhtm !
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.
thanks @michaelhtm !!
/lgtm |
@michaelhtm: The following test failed, say
Full PR test history. Your PR dashboard. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here. |
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: a-hilaly, michaelhtm, rushmash91 The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Description of changes:
ACK tags conversion with ordered keys
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.