[pve-devel] [PATCH 2/2] dynamically adjust interval based on last runtime

Stefan Priebe - Profihost AG s.priebe at profihost.ag
Tue Oct 8 10:07:11 CEST 2013


Am 08.10.2013 07:34, schrieb Dietmar Maurer:
>>> Am 08.10.2013 06:33, schrieb Dietmar Maurer:
>>>> Wouldn't it be simpler to add a callback which gets called after the load?
>>>>
>>>> 	    if (PVE.Utils.authOK()) {
>>>> 		PVE.data.UpdateQueue.queue(me, function(success)  {
>>>> 		      load_task.delay(config.interval, run_load_task);
>>>> 		})
>>>> 	....
>>>
>>> So you mean to skip the patch the first patch and put the calculation
>>> into the UpdateStore.js?
> 
> Maybe best is to combine both things (keep first patch, and pass load_time to
> the callback?

But what's the advantage then? We just introduce an additional callback.
Maybe i miss an important part in your idea.

Stefan

>>
>> The idea is to modify UpdateQueue.queue() , so that the callback is called
>> "after" the load.
>> That way you do not need to calculate anything, because the new task is started
>> after the load.
>>
>> _______________________________________________
>> pve-devel mailing list
>> pve-devel at pve.proxmox.com
>> http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
> 
> 



More information about the pve-devel mailing list