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

Wait for ENI and secondary IPs #1131

Closed
wants to merge 1 commit into from

Conversation

mogren
Copy link
Contributor

@mogren mogren commented Aug 13, 2020

Issue #, if available:
#989, #1148

Description of changes:

The log statements helping us find #989 were added earlier this year in #909 and #939, but the issue has probably been there longer. The problem is detailed in #1148, we need to wait for the Secondary IPv4 addresses to show up in the EC2 response. This PR does the following:

  • Move waitENIAttached() from ipamd.go to awsutils.go
  • Added an additional argument for how many secondary IPs to wait for
  • Use retry with backoff instead of for-loop with sleep.
  • If we find at least 1 secondary IP, but less than we wanted, we don't return an error, but count it as a partial success
  • Added unit tests

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

@nithu0115
Copy link
Contributor

Thanks, @mogren. LGTM 👍

@mogren mogren requested a review from jayanthvn August 13, 2020 22:52
@mogren mogren force-pushed the dont-log-limit-exceeded-as-error branch 5 times, most recently from 524f508 to a68b1bb Compare August 17, 2020 16:48
@mogren mogren marked this pull request as draft August 17, 2020 16:49
@mogren mogren force-pushed the dont-log-limit-exceeded-as-error branch from a68b1bb to 64f2853 Compare August 17, 2020 16:49
@mogren mogren changed the title Move error log to after we check the message Wait for ENI and secondary IPs Aug 17, 2020
@mogren mogren force-pushed the dont-log-limit-exceeded-as-error branch 6 times, most recently from 72290ea to 0613a65 Compare August 22, 2020 03:37
When a newly created ENI gets attached, we should wait for the
secondary IPv4 addresses to be assigned to the ENI before continuing.
@mogren mogren force-pushed the dont-log-limit-exceeded-as-error branch from 0613a65 to ed5a4ad Compare August 22, 2020 03:43
@mogren mogren marked this pull request as ready for review August 22, 2020 03:47
@mogren
Copy link
Contributor Author

mogren commented Aug 26, 2020

Replaced by #1174

@mogren mogren closed this Aug 26, 2020
@mogren mogren deleted the dont-log-limit-exceeded-as-error branch September 4, 2020 05:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants