We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
logging_rpc
2 parents 8012e26 + 45bf48f commit ce6e662Copy full SHA for ce6e662
1 file changed
neutron/services/logapi/drivers/manager.py
@@ -68,14 +68,18 @@ def __init__(self):
68
self._drivers = set()
69
self.rpc_required = False
70
registry.publish(log_const.LOGGING_PLUGIN, events.AFTER_INIT, self)
71
-
72
- if self.rpc_required:
73
- self.logging_rpc = server_rpc.LoggingApiNotification()
+ self._logging_rpc = None
74
75
@property
76
def drivers(self):
77
return self._drivers
78
+ @property
+ def logging_rpc(self):
79
+ if self.rpc_required and not self._logging_rpc:
80
+ self._logging_rpc = server_rpc.LoggingApiNotification()
81
+ return self._logging_rpc
82
+
83
def register_driver(self, driver):
84
"""Register driver with logging plugin.
85
0 commit comments