Changeset - 0bb7b9df12e5
[Not reviewed]
default
0 2 0
drewp@bigasterisk.com - 7 years ago 2018-06-08 03:35:30
drewp@bigasterisk.com
collector warnings and errors. the reactor.crash isn't working.
Ignore-this: b7d4a6c08f04c924ffba6112483f9c19
2 files changed with 5 insertions and 4 deletions:
0 comments (0 inline, 0 general)
bin/collector
Show inline comments
 
@@ -146,8 +146,8 @@ def launch(graph, doLoadTest=False):
 
            Udmx(L9['output/dmxA/'], bus=4, numChannels=80),
 
            Udmx(L9['output/dmxB/'], bus=5, numChannels=510),
 
        ]
 
    except Exception as e:
 
        log.error("setting up outputs: %r", e)
 
    except Exception:
 
        log.error("setting up outputs:")
 
        traceback.print_exc()
 
        raise
 
    listeners = WebListeners()
 
@@ -192,7 +192,7 @@ def main():
 
    
 
    graph = SyncedGraph(networking.rdfdb.url, "collector")
 

	
 
    graph.initiallySynced.addCallback(lambda _: launch(graph, options.loadtest)).addErrback(log.error)
 
    graph.initiallySynced.addCallback(lambda _: launch(graph, options.loadtest)).addErrback(lambda e: reactor.crash())
 
    reactor.run()
 

	
 
if __name__ == '__main__':
light9/collector/collector.py
Show inline comments
 
@@ -103,7 +103,8 @@ class Collector(Generic[ClientType, Clie
 

	
 
    def _warnOnLateRequests(self, client, now, sendTime):
 
        requestLag = now - sendTime
 
        if requestLag > .1 and now > self.initTime + 10:
 
        if requestLag > .1 and now > self.initTime + 10 and getattr(self, '_lastWarnTime', 0) < now - 3:
 
            self._lastWarnTime = now
 
            log.warn('collector.setAttrs from %s is running %.1fms after the request was made',
 
                     client, requestLag * 1000)
 

	
0 comments (0 inline, 0 general)