3 ms·
I used the median mainly because it was robust against any network glitches which occurred during testing. That said, I did my final measurements from inside E
by cperciva 5y ago
I used the median mainly because it was robust against any network glitches which occurred during testing.
That said, I did my final measurements from inside EC2 (rather than from my laptop over wifi) so it probably wasn't necessary.
- spenczar5 5y agoNetwork glitches will have a one-sided effect: they will make you slower, but never faster. Trimming out the top 25% slowest measurements, or even just using the minimum, can be more effective. Those are common when profiling programs for exactly that reason - the median execution time for a loop might be influenced by OS weirdness like some background job, but the minimum will hopefully really just measure the loop. Anyway - probably not a big deal, probably mostly academic, although modal behavior would be really interesting.
- cperciva 5y agoYes and no. If there's a network glitch while we're polling to see if the instance is "running", it will result in the "pending-to-running" time being high but the "running-to-port-closed" time being low.