-
Notifications
You must be signed in to change notification settings - Fork 276
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
ZMQ based state tables #715
Conversation
2080d27
to
1426d70
Compare
1426d70
to
8b7499c
Compare
/azp run |
Azure Pipelines successfully started running 1 pipeline(s). |
@jiahua-wang |
#778 should help passing the sairedis syncd unit test. |
/azp run |
Azure Pipelines successfully started running 1 pipeline(s). |
/azp run |
Azure Pipelines successfully started running 1 pipeline(s). |
PR blocked by docker API issue, fix PR here: #779 |
38f071c
to
1ae2ae6
Compare
/azp run |
Azure Pipelines successfully started running 1 pipeline(s). |
common/zmqclient.cpp
Outdated
else | ||
{ | ||
// for other error, send failed immediately. | ||
auto message = "zmq send failed, endpoint: " + m_endpoint + ",error: " + to_string(rc); |
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.
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.
Fixed
common/zmqclient.cpp
Outdated
else if (zmq_err == ETERM) | ||
{ | ||
m_connected = false; | ||
auto message = "zmq connection break, endpoint: " + m_endpoint + ",error: " + to_string(rc); |
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.
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.
Fixed
common/table.h
Outdated
throw std::invalid_argument("Invalid table name separator"); | ||
} | ||
|
||
static std::string gettableSeparator(int dbId) |
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.
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.
Fixed
Also change ZmqConsumerTable inherite TableBase
…le. (#2562) **What I did** Improve Consumer interface to support ZMQ based Producer/Consumer table. **Why I did it** To improve route create performance, swsscommon lib will add ZMQ based Producer/Consumer table. Because currently Consumer interface only support Redis based Producer/Consumer table, so improve this interface to support ZMQ based Producer/Consumer table. ZMQ based Producer/Consumer table can find in this PR: sonic-net/sonic-swss-common#715 **How I verified it** Pass all UT. **Details if related**
…le. (sonic-net#2562) **What I did** Improve Consumer interface to support ZMQ based Producer/Consumer table. **Why I did it** To improve route create performance, swsscommon lib will add ZMQ based Producer/Consumer table. Because currently Consumer interface only support Redis based Producer/Consumer table, so improve this interface to support ZMQ based Producer/Consumer table. ZMQ based Producer/Consumer table can find in this PR: sonic-net/sonic-swss-common#715 **How I verified it** Pass all UT. **Details if related**
…le. (#2562) (#2778) This is a cherry-pick PR for #2562 **What I did** Improve Consumer interface to support ZMQ based Producer/Consumer table. **Why I did it** To improve route create performance, swsscommon lib will add ZMQ based Producer/Consumer table. Because currently Consumer interface only support Redis based Producer/Consumer table, so improve this interface to support ZMQ based Producer/Consumer table. ZMQ based Producer/Consumer table can find in this PR: sonic-net/sonic-swss-common#715 **How I verified it** Pass all UT. **Details if related** <!-- Please make sure you have read and understood the contribution guildlines: https://github.com/Azure/SONiC/blob/gh-pages/CONTRIBUTING.md 1. Make sure your commit includes a signature generted with `git commit -s` 2. Make sure your commit title follows the correct format: [component]: description 3. Make sure your commit message contains enough details about the change and related tests 4. Make sure your pull request adds related reviewers, asignees, labels Please also provide the following information in this pull request: --> **What I did** **Why I did it** **How I verified it** **Details if related**
Why I did it
Add ZMQ based ProducerStateTable and CustomerStateTable, which is 15 times faster than Redis based tables.
For transfer 10000 route config, ZMQ based tables take 120ms, Redis based tables take 1796ms.
How I did it
Add ZMQ based ProducerStateTable and CustomerStateTable.
How to verify it
Add new UT to cover ZmqProducerStateTable and ZmqCustomerStateTable.
Pass all UT and E2E test cases.
Which release branch to backport (provide reason below if selected)
Description for the changelog
Add ZMQ based ProducerStateTable and CustomerStateTable.
Link to config_db schema for YANG module changes
A picture of a cute animal (not mandatory but encouraged)