Skip to content
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

Add RedisClient class and ScopeLogger class #2

Closed
wants to merge 7 commits into from

Conversation

kcudnik
Copy link
Contributor

@kcudnik kcudnik commented Apr 1, 2016

No description provided.

@stcheng
Copy link
Contributor

stcheng commented Apr 5, 2016

i remove the previous commit. so you could create a new pull request with just new files.

@kcudnik kcudnik changed the title Convert Counter class to RedisClient Add RedisClient class Apr 7, 2016
@kcudnik kcudnik changed the title Add RedisClient class Add RedisClient class and ScopeLogger class Apr 7, 2016
@@ -27,6 +29,19 @@ class Logger
static Logger &getInstance();
static void setMinPrio(Priority prio);
void write(Priority prio, const char *fmt, ...);

class ScopeLogger
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why define this inside the Logger class? why not outside of it?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

there is an issue to fully separate it from logger class since they both depend on each oder

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's a very good patch, however, as Guohan wrote, I don't think it should be within Logger class.
In addition, it would be nice to expand this patch and include thread-id


RedisClient(swss::DBConnector *db);

int64_t del(std::string key);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure I understand why we need this class at all. We have started to implement generic function under Table.h.
Most of the suggested function are already implemented there (In your previous commit):

Table::del
Table::delField
Table::setField

Why do we need this class?
@kcudnik @lguohan @stcheng

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Table class will not provide all functionality that i need, and those functions from table will be removed later on

@kcudnik kcudnik closed this Apr 11, 2016
@kcudnik kcudnik deleted the redisclient branch April 13, 2016 21:02
qiluo-msft pushed a commit to qiluo-msft/sonic-swss-common that referenced this pull request Jul 20, 2018
prsunny added a commit that referenced this pull request Oct 9, 2018
* VNET/VXLAN Tables

* Add VNET Route tables
zbud-msft pushed a commit to zbud-msft/sonic-swss-common that referenced this pull request Aug 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants