Re: [racket-users] Reliably propagating received log messages to ports

2018-01-31 Thread George Neuner
On 1/31/2018 5:00 PM, Alexander McLin wrote: During the tool's start up period prior to calling the main function I set up a log receiver to receive messages at the desired level and place it inside a sync loop within its own thread. Each time a sync event is received, it is written out to th

Re: [racket-users] Reliably propagating received log messages to ports

2018-01-31 Thread Robby Findler
I think the right approach here is to recognize that you have a more complex protocol than is currently reflected in your code and dive into Racket's evt support. In this particular case, I suggest you make a new channel that the loop in the thread also listens on, If yet another channel comes in

Re: [racket-users] Reliably propagating received log messages to ports

2018-01-31 Thread Vincent St-Amour
Does `with-intercepted-logging` do what you want? It should take care of the sychronization aspects, like `with-logging-to-port` does, while letting you do whatever you want with the message, e.g., sending them to different ports. Vincent On Wed, 31 Jan 2018 16:00:58 -0600, Alexander McLin wro

[racket-users] Reliably propagating received log messages to ports

2018-01-31 Thread Alexander McLin
So I am using Racket's logging facilities in a command-line tool I'm developing. I have various defined loggers in a sensible hierarchical configuration for use as needed. During the tool's start up period prior to calling the main function I set up a log receiver to receive messages at the des