Open runesl opened 10 years ago
Don't forget the cancellation possibility! We don't want to wait for the output if this task takes too long and we want to switch to the next one. Of course, the cancellation granularity (single line? single character?) must be configurable via XML. As well, we should think about output progress reporting.
This is a good issue to introduce a queue.
@filipvanlaenen Maybe it's even time to invent a hash queue.
@Dmitry-Me I think that we should look at an enterprise ready queueing solution for which we can get a solid support contract in place; WebsphereMQ immediately springs to mind
We never want to block on IO operations, so all prints should be async. This can be done by making the print-methods return Future and start an async print-thread using Threads from a thread-pool. Obviously, thread management code must be included to monitor and handle all possible and impossible outcomes of PrintOperation including timeout.