Hi everyone,
I have q process that needs to go into a while loop that can take a long time to complete. However when this happens , querying the process port does not work. Is there any way to overcome this problem ?
Thanks
Hi everyone,
I have q process that needs to go into a while loop that can take a long time to complete. However when this happens , querying the process port does not work. Is there any way to overcome this problem ?
Thanks
It is not possible to query the server while the master thread is computing. However, you may be able to run multiple q processes in a load balancing setup to achieve what you want to do: http://code.kx.com/q/cookbook/load-balancing/
Given that q is a single-threaded process, it’s not possible when the master thread is busy.
One possible alternative is to break the computationally intensive process into multiple smaller parts, and schedule each part to be executed sequentially on a timer. With this approach, you are effectively giving client processes intermittent opportunities to interact with the server.