Which way of referencing S3 files is better / faster?
Is this method of addressing S3 files better / more reliable / faster?
http://abcinfo.s3.amazonaws.com/something.doc
or this way:
http://s3.amazonaws.com/abcinfo/something.doc
Fascinating discovery!
http://abcinfo.s3.amazonaws.com/something.doc
Is CONSISTENTLY slower than the other reference mechanism!
File used: Length: 3716075 (3.5M) [video/mp4]
wget http://myfolder.s3.amazonaws.com/mytestfile.mp4
7.0s
wget http://s3.amazonaws.com/myfolder/mytestfile.mp4
2.2s
wget http://myfolder.s3.amazonaws.com/mytestfile.mp4
9.7s
wget http://s3.amazonaws.com/myfolder/mytestfile.mp4
2.2s
wget http://s3.amazonaws.com/myfolder/mytestfile.mp4
2.1s
wget http://myfolder.s3.amazonaws.com/mytestfile.mp4
9.9s
wget http://myfolder.s3.amazonaws.com/mytestfile.mp4
9.2s
Average time taken in http://myfolder mechanism:
8.95 seconds
Average time taken in /myfolder/ mechanism:
2.166666667 seconds
ie, the former is at least FOUR times as slower!
精彩评论