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

Add support for IPSet CRD #4

Merged
merged 4 commits into from
Aug 9, 2024

Conversation

TiberiuGC
Copy link
Member

Issue #, if available: aws-controllers-k8s/community#1300

Description of changes:

  • adds support for IPSet CRD
  • adds integration tests for above

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

Copy link

ack-prow bot commented Jul 25, 2024

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@ack-prow ack-prow bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jul 25, 2024
@ack-prow ack-prow bot requested a review from a-hilaly July 25, 2024 11:16
@TiberiuGC TiberiuGC force-pushed the resource/ip-set branch 2 times, most recently from 5ebfe8a to 2aa478d Compare July 25, 2024 11:19
@TiberiuGC
Copy link
Member Author

/test all

@TiberiuGC
Copy link
Member Author

/retest

1 similar comment
@TiberiuGC
Copy link
Member Author

/retest

@TiberiuGC TiberiuGC marked this pull request as ready for review July 25, 2024 14:05
@ack-prow ack-prow bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jul 25, 2024
Copy link
Member

@a-hilaly a-hilaly left a comment

Choose a reason for hiding this comment

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

Thank you @TiberiuGC ! I left a few comments in line

go_version: go1.22.5
version: v0.35.0
Copy link
Member

Choose a reason for hiding this comment

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

Can you please pull code-gen v0.35.0?

Copy link
Member Author

Choose a reason for hiding this comment

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

Comment on lines 1 to 3
if resp.IPSet != nil {
if resp.IPSet.Description != nil {
ko.Spec.Description = resp.IPSet.Description
}
if resp.IPSet.Addresses != nil {
ko.Spec.Addresses = resp.IPSet.Addresses
}
}
Copy link
Member

Choose a reason for hiding this comment

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

Copy link
Member Author

Choose a reason for hiding this comment

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

Comment on lines +115 to +124
// A token used for optimistic locking. WAF returns a token to your get and
// list requests, to mark the state of the entity at the time of the request.
// To make changes to the entity associated with the token, you provide the
// token to operations like update and delete. WAF uses the token to ensure
// that no changes have been made to the entity since you last retrieved it.
// If a change has been made, the update fails with a WAFOptimisticLockException.
// If this happens, perform another get, and use the new token returned by that
// operation.
// +kubebuilder:validation:Optional
LockToken *string `json:"lockToken,omitempty"`
Copy link
Member

Choose a reason for hiding this comment

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

Do we need the LockToken in the status?

Copy link
Member Author

Choose a reason for hiding this comment

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

LockToken is required input for both SDK update and delete, so I believe we do need it? I am not aware of a better practice, lmk if there's one.

Description *string `json:"description,omitempty"`
// The version of the IP addresses, either IPV4 or IPV6.
// +kubebuilder:validation:Required
IPAddressVersion *string `json:"iPAddressVersion"`
Copy link
Member

Choose a reason for hiding this comment

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

This is a bug in https://github.com/aws-controllers-k8s/pkg/tree/main/names - needs to be ipAddressVersion

Copy link
Member

Choose a reason for hiding this comment

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

Copy link
Member Author

Choose a reason for hiding this comment

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

Copy link
Member

@a-hilaly a-hilaly left a comment

Choose a reason for hiding this comment

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

Neat, thank you!
/lgtm

@ack-prow ack-prow bot added the lgtm Indicates that a PR is ready to be merged. label Aug 9, 2024
Copy link

ack-prow bot commented Aug 9, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: a-hilaly, TiberiuGC

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ack-prow ack-prow bot added the approved label Aug 9, 2024
@ack-prow ack-prow bot merged commit 4a5ad87 into aws-controllers-k8s:main Aug 9, 2024
6 checks passed
ack-prow bot pushed a commit that referenced this pull request Aug 27, 2024
Issue #, if available: aws-controllers-k8s/community#1300

Description of changes:
- on top of, and to be reviewed after merging: #4
- adds support for RuleGroup CRD
- adds integration tests for above

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants