All, I’ve written a distribution service that spawns processes using
IO.popen in a seperate thread for each job.
In my Task class, I would like to create a block method such as
‘Task.monitor(mode=“stdout”)’, which would yield the stdout for that
task from that point forward. – similar to tail -f, but for a
The result would in essence be called like:
task = Task.new(:cmd => “tail -f /some/log”)
fresh content from some/log will be yielded
Since $stdout is global, what would be the beat way tackle this?