sonic-mgmt icon indicating copy to clipboard operation
sonic-mgmt copied to clipboard

Increase check bgp session timeout; handle failed tcp connection

Open illia-kotvitskyi opened this issue 2 years ago • 19 comments

Description of PR

Summary: increase check bgp session timeout; handle failed tcp connection

Previously we used the default value for the timeout equal to 30s. While running this test I faced errors because of small timeout occurs rarely, so it was decided to double it(30s -> 60s). Fixes # (issue)

Type of change

  • [x] Bug fix
  • [ ] Testbed and Framework(new/improvement)
  • [ ] Test case(new/improvement)

Back port request

  • [ ] 201911
  • [ ] 202012
  • [ ] 202205
  • [x] 202305

Approach

What is the motivation for this PR?

To handle failed TCP connections and adjust bgp session timeout

How did you do it?

How did you verify/test it?

Any platform specific information?

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

Documentation

illia-kotvitskyi avatar Nov 17 '23 08:11 illia-kotvitskyi

CLA Signed

The committers listed above are authorized under a signed CLA.

  • :white_check_mark: login: illia-kotvitskyi / name: Illia (86466156e95b4630040929da1cd59716c12eb3bb)

The pre-commit check detected issues in the files touched by this pull request. The pre-commit check is a mandatory check, please fix detected issues.

Detailed pre-commit check results: trim trailing whitespace.................................................Passed
fix end of files.........................................................Passed
check yaml...........................................(no files to check)Skipped
check for added large files..............................................Passed
check python ast.........................................................Passed
flake8...................................................................Failed
- hook id: flake8
- exit code: 1

tests/bgp/test_bgp_dual_asn.py:445:1: E302 expected 2 blank lines, found 1

flake8...............................................(no files to check)Skipped
check conditional mark sort..........................(no files to check)Skipped

To run the pre-commit checks locally, you can follow below steps:

  1. Ensure that default python is python3. In sonic-mgmt docker container, default python is python2. You can run the check by activating the python3 virtual environment in sonic-mgmt docker container or outside of sonic-mgmt docker container.
  2. Ensure that the pre-commit package is installed:
sudo pip install pre-commit
  1. Go to repository root folder
  2. Install the pre-commit hooks:
pre-commit install
  1. Use pre-commit to check staged file:
pre-commit
  1. Alternatively, you can check committed files using:
pre-commit run --from-ref <commit_id> --to-ref <commit_id>

mssonicbld avatar Nov 17 '23 08:11 mssonicbld

@jcaiMR @StormLiangMS may I ask you to review this PR?

illia-kotvitskyi avatar Dec 04 '23 15:12 illia-kotvitskyi

/azp run Semgrep

liat-grozovik avatar Feb 12 '24 15:02 liat-grozovik

No pipelines are associated with this pull request.

azure-pipelines[bot] avatar Feb 12 '24 15:02 azure-pipelines[bot]

/azp run

liat-grozovik avatar Feb 12 '24 15:02 liat-grozovik

Azure Pipelines successfully started running 1 pipeline(s).

azure-pipelines[bot] avatar Feb 12 '24 15:02 azure-pipelines[bot]

you need to /azpw run

illia-kotvitskyi avatar Feb 13 '24 14:02 illia-kotvitskyi

Commenter does not have sufficient privileges for PR 10774 in repo sonic-net/sonic-mgmt

azure-pipelines[bot] avatar Feb 13 '24 14:02 azure-pipelines[bot]

/azpw run Azure.sonic-mgmt

illia-kotvitskyi avatar Feb 13 '24 14:02 illia-kotvitskyi

/AzurePipelines run Azure.sonic-mgmt

mssonicbld avatar Feb 13 '24 14:02 mssonicbld

Azure Pipelines successfully started running 1 pipeline(s).

azure-pipelines[bot] avatar Feb 13 '24 14:02 azure-pipelines[bot]

/azpw run Azure.sonic-mgmt

illia-kotvitskyi avatar Feb 20 '24 11:02 illia-kotvitskyi

/AzurePipelines run Azure.sonic-mgmt

mssonicbld avatar Feb 20 '24 11:02 mssonicbld

Azure Pipelines successfully started running 1 pipeline(s).

azure-pipelines[bot] avatar Feb 20 '24 11:02 azure-pipelines[bot]

Hi, @jcaiMR @StormLiangMS Can we merge this PR?

illia-kotvitskyi avatar Mar 04 '24 08:03 illia-kotvitskyi

/azp run Semgrep

liat-grozovik avatar Apr 16 '24 13:04 liat-grozovik

No pipelines are associated with this pull request.

azure-pipelines[bot] avatar Apr 16 '24 13:04 azure-pipelines[bot]

@yxieca how one can restart the semgrep to allow such PR to be available for merge? restarting all the checkers is too much effort.

liat-grozovik avatar Apr 16 '24 13:04 liat-grozovik

/Semgrep

yxieca avatar Apr 18 '24 21:04 yxieca

Please merge the latest master.

qiluo-msft avatar Apr 22 '24 16:04 qiluo-msft

/azpw run Azure.sonic-mgmt

illia-kotvitskyi avatar Apr 23 '24 10:04 illia-kotvitskyi

/AzurePipelines run Azure.sonic-mgmt

mssonicbld avatar Apr 23 '24 10:04 mssonicbld

Azure Pipelines successfully started running 1 pipeline(s).

azure-pipelines[bot] avatar Apr 23 '24 10:04 azure-pipelines[bot]

Hi @jcaiMR @liat-grozovik , Can we merge this?

illia-kotvitskyi avatar May 02 '24 06:05 illia-kotvitskyi