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

feat: add wait_for_bgp option to reboot #16542

Merged
merged 1 commit into from
Jan 16, 2025

Conversation

cyw233
Copy link
Contributor

@cyw233 cyw233 commented Jan 16, 2025

Description of PR

The reboot process for chassis will need longer time to wait for the BGP to be established. For example, the acl/test_acl.py can be flaky if we are not waiting BGP long enough. Therefore, we are introducing wait_for_bgp option to the reboot() function.

Summary:
Fixes # (issue) Microsoft ADO 30862178

Type of change

  • Bug fix
  • Testbed and Framework(new/improvement)
  • New Test case
    • Skipped for non-supported platforms
  • Test case improvement

Back port request

  • 202012
  • 202205
  • 202305
  • 202311
  • 202405
  • 202411

Approach

What is the motivation for this PR?

We found that tests like acl/test_acl.py can be flaky if we are not waiting for BGP long enough on chassis after reboot. Therefore, we want to mimic what we have in config_reload() to also introduce the wait_for_bgp option to the reboot() function.

How did you do it?

How did you verify/test it?

I ran the updated acl test code and can make sure it's working well.

Any platform specific information?

Supported testbed topology if it's a new test case?

Documentation

@mssonicbld
Copy link
Collaborator

/azp run

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

Copy link
Collaborator

@yejianquan yejianquan left a comment

Choose a reason for hiding this comment

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

LGTM

@mssonicbld
Copy link
Collaborator

@cyw233 PR conflicts with 202411 branch

@mssonicbld
Copy link
Collaborator

@cyw233 PR conflicts with 202405 branch

cyw233 added a commit to cyw233/sonic-mgmt that referenced this pull request Jan 16, 2025
Description of PR
The reboot process for chassis will need longer time to wait for the BGP to be established. For example, the acl/test_acl.py can be flaky if we are not waiting BGP long enough. Therefore, we are introducing wait_for_bgp option to the reboot() function.

Summary:
Fixes # (issue) Microsoft ADO 30862178

Type of change
 Bug fix
 Testbed and Framework(new/improvement)
 New Test case
 Skipped for non-supported platforms
 Test case improvement
Back port request
 202012
 202205
 202305
 202311
 202405
 202411
Approach
What is the motivation for this PR?
We found that tests like acl/test_acl.py can be flaky if we are not waiting for BGP long enough on chassis after reboot. Therefore, we want to mimic what we have in config_reload() to also introduce the wait_for_bgp option to the reboot() function.

How did you do it?
How did you verify/test it?
I ran the updated acl test code and can make sure it's working well.

co-authorized by: jianquanye@microsoft.com
@cyw233 cyw233 deleted the add-wait-for-bgp-in-reboot branch January 16, 2025 23:15
@cyw233
Copy link
Contributor Author

cyw233 commented Jan 16, 2025

Cherry-pick PR to 202405: #16562

cyw233 added a commit to cyw233/sonic-mgmt that referenced this pull request Jan 17, 2025
Description of PR
The reboot process for chassis will need longer time to wait for the BGP to be established. For example, the acl/test_acl.py can be flaky if we are not waiting BGP long enough. Therefore, we are introducing wait_for_bgp option to the reboot() function.

Summary:
Fixes # (issue) Microsoft ADO 30862178

Type of change
 Bug fix
 Testbed and Framework(new/improvement)
 New Test case
 Skipped for non-supported platforms
 Test case improvement
Back port request
 202012
 202205
 202305
 202311
 202405
 202411
Approach
What is the motivation for this PR?
We found that tests like acl/test_acl.py can be flaky if we are not waiting for BGP long enough on chassis after reboot. Therefore, we want to mimic what we have in config_reload() to also introduce the wait_for_bgp option to the reboot() function.

How did you do it?
How did you verify/test it?
I ran the updated acl test code and can make sure it's working well.

co-authorized by: jianquanye@microsoft.com
@cyw233
Copy link
Contributor Author

cyw233 commented Jan 17, 2025

Cherry-pick PR to 202411: #16563

yejianquan pushed a commit that referenced this pull request Jan 17, 2025
Description of PR
The reboot process for chassis will need longer time to wait for the BGP to be established. For example, the acl/test_acl.py can be flaky if we are not waiting BGP long enough. Therefore, we are introducing wait_for_bgp option to the reboot() function.

Summary:
Fixes # (issue) Microsoft ADO 30862178

Type of change
 Bug fix
 Testbed and Framework(new/improvement)
 New Test case
 Skipped for non-supported platforms
 Test case improvement
Back port request
 202012
 202205
 202305
 202311
 202405
 202411
Approach
What is the motivation for this PR?
We found that tests like acl/test_acl.py can be flaky if we are not waiting for BGP long enough on chassis after reboot. Therefore, we want to mimic what we have in config_reload() to also introduce the wait_for_bgp option to the reboot() function.

How did you do it?
How did you verify/test it?
I ran the updated acl test code and can make sure it's working well.

co-authorized by: jianquanye@microsoft.com
yejianquan pushed a commit that referenced this pull request Jan 17, 2025
Description of PR
The reboot process for chassis will need longer time to wait for the BGP to be established. For example, the acl/test_acl.py can be flaky if we are not waiting BGP long enough. Therefore, we are introducing wait_for_bgp option to the reboot() function.

Summary:
Fixes # (issue) Microsoft ADO 30862178

Type of change
 Bug fix
 Testbed and Framework(new/improvement)
 New Test case
 Skipped for non-supported platforms
 Test case improvement
Back port request
 202012
 202205
 202305
 202311
 202405
 202411
Approach
What is the motivation for this PR?
We found that tests like acl/test_acl.py can be flaky if we are not waiting for BGP long enough on chassis after reboot. Therefore, we want to mimic what we have in config_reload() to also introduce the wait_for_bgp option to the reboot() function.

How did you do it?
How did you verify/test it?
I ran the updated acl test code and can make sure it's working well.

co-authorized by: jianquanye@microsoft.com
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants