feat(switch/brocade): Implement client to interact with Brocade switches #168

Merged
letian merged 1 commits from brocade-switch-client into master 2025-10-16 18:23:02 +00:00
Owner

Description

  • Expose a high-level brocade::init() function to connect to a Brocade switch and automatically pick the best implementation based on its OS and version
  • Implement a client for Brocade switches running on Network Operating System (NOS)
  • Implement a client for older Brocade switches running on FastIron (partial implementation)

Architecture decisions

The architecture for the library is based on 3 layers:

  1. The BrocadeClient trait to describe the available capabilities to interact with a Brocade switch. It is partly opinionated in order to offer higher level features to group multiple commands into a single function (e.g. create a port channel). Its implementations are basically just the commands to run on the switch and the functions to parse the output.
  2. The BrocadeShell struct to make it easier to authenticate, send commands, and interact with the switch.
  3. The ssh module to actually connect to the switch over SSH and execute the commands.

With time, we will add support for more Brocade switches and their various OS/versions. If needed, shared behavior could be extracted into a separate module to make it easier to add new implementations and keep duplication to a minimum.

## Description * Expose a high-level `brocade::init()` function to connect to a Brocade switch and automatically pick the best implementation based on its OS and version * Implement a client for Brocade switches running on Network Operating System (NOS) * Implement a client for older Brocade switches running on FastIron (partial implementation) ## Architecture decisions The architecture for the library is based on 3 layers: 1. The `BrocadeClient` trait to describe the available capabilities to interact with a Brocade switch. It is partly opinionated in order to offer higher level features to group multiple commands into a single function (e.g. create a port channel). Its implementations are basically just the commands to run on the switch and the functions to parse the output. 2. The `BrocadeShell` struct to make it easier to authenticate, send commands, and interact with the switch. 3. The `ssh` module to actually connect to the switch over SSH and execute the commands. With time, we will add support for more Brocade switches and their various OS/versions. If needed, shared behavior could be extracted into a separate module to make it easier to add new implementations and keep duplication to a minimum.
letian added 1 commit 2025-10-15 19:27:34 +00:00
feat(switch/brocade): Implement client to interact with Brocade Switch
All checks were successful
Run Check Script / check (pull_request) Successful in 1m4s
4955b74d75
* Expose a high-level `brocade::init()` function to connect to a Brocade switch and automatically pick the best implementation based on its OS and version
* Implement a client for Brocade switches running on Network Operating System (NOS)
* Implement a client for older Brocade switches running on FastIron (partial implementation)

The architecture for the library is based on 3 layers:
1. The `BrocadeClient` trait to describe the available capabilities to
   interact with a Brocade switch. It is partly opinionated in order to
   offer higher level features to group multiple commands into a single
   function (e.g. create a port channel). Its implementations are
   basically just the commands to run on the switch and the functions to
   parse the output.
2. The `BrocadeShell` struct to make it easier to authenticate, send commands, and interact with the switch.
3. The `ssh` module to actually connect to the switch over SSH and execute the commands.

With time, we will add support for more Brocade switches and their various OS/versions. If needed, shared behavior could be extracted into a separate module to make it easier to add new implementations.
letian force-pushed brocade-switch-client from 4955b74d75 to c0bd8007c7 2025-10-15 19:28:28 +00:00 Compare
letian changed title from feat(switch/brocade): Implement clients to interact with Brocade switches to feat(switch/brocade): Implement client to interact with Brocade switches 2025-10-15 20:02:22 +00:00
letian merged commit 6989d208cf into master 2025-10-16 18:23:02 +00:00
letian deleted branch brocade-switch-client 2025-10-16 18:23:05 +00:00
Sign in to join this conversation.
No reviewers
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: NationTech/harmony#168
No description provided.