[Kimchi-devel] [DOUBT] How to use setTimeout correctly
Ramon Medeiros
ramonn at linux.vnet.ibm.com
Fri Jul 10 20:57:37 UTC 2015
Hi team,
i was trying to cache 2 objects, but they came from a HTTP request, and
took some time to download it. I was unable to use the function
setTimeout while calling this function:
kimchi.getPCIDeviceCompanions(kimchi.hostPCIs[i].name,
setTimeout(function(result) {
kimchi.deviceCompanions[kimchi.hostPCIs[i].name] = result;
},5000));
}
The function kimchi.getPCIDeviceCompanions usually takes 2s to finish.
--
Ramon Nunes Medeiros
Kimchi Developer
Linux Technology Center Brazil
IBM Systems & Technology Group
Phone : +55 19 2132 7878
ramonn at br.ibm.com
More information about the Kimchi-devel
mailing list