Change DBConnector to connect redis with unix socket.#21345
Merged
qiluo-msft merged 8 commits intosonic-net:masterfrom Jan 10, 2025
Merged
Change DBConnector to connect redis with unix socket.#21345qiluo-msft merged 8 commits intosonic-net:masterfrom
qiluo-msft merged 8 commits intosonic-net:masterfrom
Conversation
Collaborator
|
/azp run Azure.sonic-buildimage |
|
Azure Pipelines successfully started running 1 pipeline(s). |
qiluo-msft
reviewed
Jan 10, 2025
| from swsscommon import swsscommon | ||
| self.state_db = swsscommon.DBConnector("STATE_DB", | ||
| REDIS_TIMEOUT_USECS, | ||
| True) |
Collaborator
Collaborator
|
/azp run Azure.sonic-buildimage |
|
Azure Pipelines successfully started running 1 pipeline(s). |
qiluo-msft
approved these changes
Jan 10, 2025
VladimirKuk
pushed a commit
to Marvell-switching/sonic-buildimage
that referenced
this pull request
Jan 21, 2025
Change DBConnector to connect redis with unix socket. Why I did it Improve SONiC Redis security by switch to unix socket connection. How I did it Change DBConnector parameter to connect redis with unix socket: DBConnector(const std::string &dbName, unsigned int timeout_ms, bool isTcpConn = false); How to verify it Pass all UT. Description for the changelog Change DBConnector to connect redis with unix socket.
11 tasks
miatttao
pushed a commit
to miatttao/sonic-buildimage
that referenced
this pull request
Mar 5, 2025
Why I did it Reverting part of sonic-net#21345, since Chassis DB connection from remote host (linecard) cannot use unix socket How I did it Continue to use TCP socket for chassis DB connection How to verify it Bring up BGP on chassis, which currently fails after change in sonic-net#21345
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Change DBConnector to connect redis with unix socket.
Why I did it
Improve SONiC Redis security by switch to unix socket connection.
Work item tracking
How I did it
Change DBConnector parameter to connect redis with unix socket:
DBConnector(const std::string &dbName, unsigned int timeout_ms, bool isTcpConn = false);
How to verify it
Pass all UT.
Which release branch to backport (provide reason below if selected)
Tested branch (Please provide the tested image version)
Description for the changelog
Change DBConnector to connect redis with unix socket.
Link to config_db schema for YANG module changes
A picture of a cute animal (not mandatory but encouraged)