Maybe would be a good idea to extend the exisiting interval parameter in two parameters?
The minimum interval where a new algorithm must run (current parameter)
Once the algorithm has finished the first interval, if it continues because it is the most profitable, a new interval to recheck if it has to switch to a more profitable.
So, for example
INTERVAL_PPS 300
INTERVAL_PPS_RECHECK 60
With these values, a first interval of 300 is executed and after it, will recheck the profitability each 60 seconds.
Maybe would be a good idea to extend the exisiting interval parameter in two parameters?
So, for example
INTERVAL_PPS 300 INTERVAL_PPS_RECHECK 60
With these values, a first interval of 300 is executed and after it, will recheck the profitability each 60 seconds.
(Same for INTERVAL_PPLS)