@@ -158,7 +158,7 @@ def send(
158
158
159
159
def _run_scheduler (self ) -> None :
160
160
"""
161
- After me made a connection periodically enqueue “heartbeat” jobs until stop is signaled.
161
+ After we made a connection, periodically enqueue “heartbeat” jobs until stop is signaled.
162
162
"""
163
163
while not self ._stop .wait (self ._interval ):
164
164
if self ._schedule :
@@ -240,16 +240,16 @@ def stop(self) -> None:
240
240
241
241
# Before exiting send signal the server we are disconnecting to free our resources
242
242
# This is not required by the spec but is helpful in practice
243
- logger .debug ("Stopping OpAMPClient : sending AgentDisconnect" )
243
+ logger .debug ("Stopping OpAMPAgent : sending AgentDisconnect" )
244
244
payload = self ._client .build_agent_disconnect_message ()
245
245
try :
246
246
self ._client .send (payload )
247
247
except Exception : # pylint: disable=broad-exception-caught
248
248
logger .debug (
249
- "Stopping OpAMPClient : failed to send AgentDisconnect message"
249
+ "Stopping OpAMPAgent : failed to send AgentDisconnect message"
250
250
)
251
251
252
- logger .debug ("Stopping OpAMPClient : cancelling jobs" )
252
+ logger .debug ("Stopping OpAMPAgent : cancelling jobs" )
253
253
# Clear pending jobs
254
254
while True :
255
255
try :
@@ -265,12 +265,12 @@ def stop(self) -> None:
265
265
self ._worker .join ()
266
266
except RuntimeError as exc :
267
267
logger .warning (
268
- "Stopping OpAMPClient : worker thread failed to join %s" , exc
268
+ "Stopping OpAMPAgent : worker thread failed to join %s" , exc
269
269
)
270
270
try :
271
271
self ._scheduler .join ()
272
272
except RuntimeError as exc :
273
273
logger .warning (
274
- "Stopping OpAMPClient : scheduler thread failed to join %s" , exc
274
+ "Stopping OpAMPAgent : scheduler thread failed to join %s" , exc
275
275
)
276
- logger .debug ("OpAMPClient stopped" )
276
+ logger .debug ("OpAMPAgent stopped" )
0 commit comments