forked from sonic-net/sonic-swss-common
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implement DBInterface/SonicV2Connector in C++ (sonic-net#387)
* [pyext] Add more OUTPUT type * Refactor: add new class RedisConnector * dbconnector: remove emtpy line * Refine script functions parameter * Add copy constructor to RedisConnector * Optimize DBConnector ctor * Revert back m_namespace * Refactor: change name * Fix build * Extract psubscribe and subscribe function into DBConnector class * Implement _subscribe_keyspace_notification, _unsubscribe_keyspace_notification and _connection_error_handler * Implement blockable * Implement connect with retry * Implement DBConnector::publish(), * Use c++11 syntax instead of c++14 * Implement blocking for get and del * Add to pyext * Add set_redis_kwargs(), fix _onetime_connect() * Fix LGTM: delete implicitly-declared copy assignment operator * update DBInterface redis_client index from db_id to db_name * Add DBInterface::delete_all_by_pattern() * Add SonicV2Connector class * Add unit test for SonicV2Connector * Make const strings public because they are used as public method default parameters * SWIG supports keyword arguments in generated python module * Add python namespace property to DBConnector class, solve the paramter conflicting with C++ keyword by customizing python code generation * Move SonicV2Connector to standalone .h/.cpp files * Add missing include statements into SWIG inteface file * Add pytest unit test for DBInterface and SonicV2Connector * Fix swig customization on SonicV2Connector ctor * Add attrib SonicV2Connector.namespace * Remove debug code * Use EXPECT_NE to simplify test * Remove unused code
- Loading branch information
1 parent
c6e2b28
commit 5a4f355
Showing
19 changed files
with
983 additions
and
131 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
Oops, something went wrong.