Add log writer triggering

This commit is contained in:
Daniel 2019-09-20 22:04:04 +02:00
parent f29bd54976
commit aaa7aaf648
2 changed files with 5 additions and 0 deletions

View file

@ -20,6 +20,8 @@ var (
mediumPriorityClearance = make(chan struct{})
lowPriorityClearance = make(chan struct{})
triggerLogWriting = log.TriggerWriterChannel()
)
const (
@ -138,6 +140,8 @@ microTaskManageLoop:
select {
case taskTimeslot <- struct{}{}:
continue microTaskManageLoop
case triggerLogWriting <- struct{}{}:
continue microTaskManageLoop
case mediumPriorityClearance <- struct{}{}:
case lowPriorityClearance <- struct{}{}:
}

View file

@ -57,6 +57,7 @@ func Start() error {
}
// start logging
log.EnableScheduling()
err = log.Start()
if err != nil {
fmt.Fprintf(os.Stderr, "CRITICAL ERROR: failed to start logging: %s\n", err)