Server loop avoidance.
Posted: Fri Nov 09, 2018 7:04 pm
From experts advice here on the Forum, and what I have read on the subject, constant cycling of an idle looping server slows down everything else running on that computer.
No doubt someone has a better idea than this, or has invented it already, but what do you think?
My server could just do one pass and complete all its duties. Then run a separate program and exit.
The separate program has a wait state so it is effectively asleep for a time and then checks to see what work has come in for the server to process. In my case, if it is more than X number of files then the program loads and runs the server and terminates.
The wait state can subsequently become shorter or longer based on the flow of incoming files.
I don't know what waste or overhead restarting programs has other than the initialisation of variables, so I look forward to your advice and ideas.
Thank you.
No doubt someone has a better idea than this, or has invented it already, but what do you think?
My server could just do one pass and complete all its duties. Then run a separate program and exit.
The separate program has a wait state so it is effectively asleep for a time and then checks to see what work has come in for the server to process. In my case, if it is more than X number of files then the program loads and runs the server and terminates.
The wait state can subsequently become shorter or longer based on the flow of incoming files.
I don't know what waste or overhead restarting programs has other than the initialisation of variables, so I look forward to your advice and ideas.
Thank you.