L
L
LeonidPokrovskiy2019-11-09 20:13:01
Data storage
LeonidPokrovskiy, 2019-11-09 20:13:01

0.3 seconds to download a 71KB image - is this normal?

I use MailRu CloudStorage to store user avatars and documents they upload. I use their PHP SDK (composer package). Uploaded a typical 71KB user avatar to the cloud.
At first, I simply assigned a new path to the pictures in the src attribute. Refreshed the page and noticed a slight delay in uploading the photo. The whole page loaded and in a moment the photo appeared. Then I decided for the sake of interest to measure the speed of loading an image using the microtime php function. On average, such an avatar takes 0.3 seconds to load.
I looked in the inspector in the network tab in VK - there a 140KB picture is loaded in 0.6 seconds
Important: I did all this locally on openservere. Everything except the downloaded image is local.
Question:
This is fine? Does it make sense to try to speed up?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
dollar, 2019-11-09
@LeonidPokrovskiy

There are no standards or guarantees that image hosting must comply with in terms of speed. Some companies only have restrictions on the images that the hosting accepts. Just if it's subjectively too slow for you, you can try another hosting. And there are so many factors. Maybe your antivirus will check this picture with deep heuristics. Or maybe Roskomnadzor is testing a new technology for analyzing and blocking certain traffic.
Open devtools (F12 key in the browser), go to the Network tab, and then for the corresponding picture, already see what actually takes time.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question