-
Notifications
You must be signed in to change notification settings - Fork 779
[Fast-linkup] Added CLIs for config/show #4182
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
base: master
Are you sure you want to change the base?
[Fast-linkup] Added CLIs for config/show #4182
Conversation
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
ba03a54 to
2881c71
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
2881c71 to
00800c5
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
00800c5 to
6bec417
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
6bec417 to
3524454
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
3524454 to
9df5b8a
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
9df5b8a to
ab914aa
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
ab914aa to
9b7b3d6
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
9b7b3d6 to
620bf18
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
620bf18 to
1a76a73
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
3089510 to
d0c8056
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
d0c8056 to
c67b8f9
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
c67b8f9 to
5183942
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
Signed-off-by: Yair Raviv <[email protected]>
5183942 to
e4a7798
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
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.
Pull request overview
This PR implements CLI commands for the Fast Link-Up feature, adding configuration and show commands for global settings and per-interface control. The implementation follows the SONiC CLI patterns for adding new feature commands, but contains critical bugs that prevent the interface command from working correctly.
Changes:
- Added
config switch-fast-linkup globalto configure polling time, guard time, and BER threshold - Added
config interface fast-linkup <interface> <mode>to enable/disable fast-linkup per port - Added
show switch-fast-linkup globalto display global configuration with table and JSON output - Added
show interfaces fast-linkup statusto display per-interface fast-linkup status - Extended portconfig script to support
-flflag for setting fast-linkup mode - Added comprehensive test suite with 15 test cases covering various scenarios
- Updated Command Reference documentation with usage examples
Reviewed changes
Copilot reviewed 10 out of 10 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| tests/fast_linkup_test.py | Comprehensive test suite covering config/show commands, validation, and error cases |
| tests/fast_linkup_input/mock_state/supported/state_db.json | Mock STATE_DB data for supported platform scenario |
| tests/fast_linkup_input/mock_state/not_supported/state_db.json | Mock STATE_DB data for unsupported platform scenario |
| tests/fast_linkup_input/mock_config/ports/config_db.json | Mock CONFIG_DB data for port configuration tests |
| tests/fast_linkup_input/mock_config/global/config_db.json | Mock CONFIG_DB data for global configuration tests |
| show/main.py | Added switch-fast-linkup global command group with table/JSON output |
| show/interfaces/init.py | Added fast-linkup status subcommand to display per-interface status |
| scripts/portconfig | Extended portconfig with -fl flag to set fast-linkup mode via CONFIG_DB |
| doc/Command-Reference.md | Comprehensive documentation for all new commands with usage examples |
| config/main.py | Added switch-fast-linkup global and interface fast-linkup commands with validation |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
Signed-off-by: Yair Raviv <[email protected]>
bdd69f7 to
8a5474a
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
Signed-off-by: Yair Raviv <[email protected]>
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
@qiluo-msft - Resolved all comments |
HLD: fast-link-up-hld.md
What I did
Implemented CLI for Fast-linkup feature including:
How I did it
configandshowCLIHow to verify it
Which release branch to backport (provide reason below if selected)
New command output (if the output of a command-line utility has changed)