-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
[lldpmgrd] Inherit DaemonBase class from sonic-py-common package #5370
Conversation
@@ -198,6 +158,13 @@ class LldpManager(object): | |||
Subscribe to CONFIG_DB - get notified of port config changes | |||
Update LLDP configuration accordingly. | |||
""" | |||
self.log_info("Starting up...") | |||
|
|||
if not os.geteuid() == 0: |
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.
Should it be part of the base class?
We can initialize the base class with parameters?
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.
This is a good suggestion for a future improvement. For now I'd like to transition daemons to inherit from the base class as-is, then we can assess other remaining duplicated code (like this), and make improvements accordingly.
Retest vsimage please |
Eliminate duplicate logging and signal handling code by inheriting from DaemonBase class in sonic-py-common package.
…ic-net#5370) Eliminate duplicate logging and signal handling code by inheriting from DaemonBase class in sonic-py-common package.
- Why I did it
Eliminate duplicate logging and signal handling code by inheriting from DaemonBase class in sonic-py-common package.
- How to verify it
Ensure lldpmgrd functionality is unchanged
- Which release branch to backport (provide reason below if selected)