Skip to content

Commit a868e9a

Browse files
committed
Make sure to reschedule lookup on fail
Also lower log level of agent not found to warn (not error)
1 parent c4e579a commit a868e9a

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

instana/fsm.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -78,9 +78,9 @@ def lookup_agent_host(self, e):
7878
self.agent.set_host(host)
7979
self.fsm.announce()
8080
return True
81-
else:
82-
l.error("Cannot lookup agent host. Scheduling retry.")
83-
self.schedule_retry(self.lookup_agent_host, e, "agent_lookup")
81+
82+
l.warn("Instana Host Agent can't be found. Scheduling retry.")
83+
self.schedule_retry(self.lookup_agent_host, e, "agent_lookup")
8484
return False
8585

8686
def get_default_gateway(self):
@@ -130,7 +130,7 @@ def announce_sensor(self, e):
130130
l.warn("Host agent available. We're in business. Announced pid: %i (true pid: %i)" % (p.pid, self.agent.from_.pid))
131131
return True
132132
else:
133-
l.error("Cannot announce sensor. Scheduling retry.")
133+
l.warn("Cannot announce sensor. Scheduling retry.")
134134
self.schedule_retry(self.announce_sensor, e, "announce")
135135
return False
136136

0 commit comments

Comments
 (0)