mouthporn.net
#wireless network – @dragoni on Tumblr
Avatar

DragonI

@dragoni

"Truth is not what you want it to be; it is what it is, and you must bend to its power or live a lie", Miyamoto Musashi
Avatar

Ilya’s book is online. Read it for free

Performance is a feature. 
This book provides a hands-on overview of what every web developer needs to know about the various types of networks (WiFi, 3G/4G), transport protocols (UDP, TCP, and TLS), application protocols (HTTP/1.1, HTTP/2), and APIs available in the browser (XHR & Fetch, WebSocket, WebRTC, and more) to deliver the best—fast, reliable, and resilient—user experience.
Avatar
A successful application is one that is resilient to fluctuations in network availability and performance: it can take advantage of the peak performance, but it plans for and continues to work when conditions degrade.
...
A 4G user will experience a much better median experience both in terms of bandwidth and latency than a 3G user, but the same 4G user will also fall back to the 3G network for some of the time due to coverage, capacity, or other reasons. Case in point, OpenSignal data shows that an average "4G user" in the US gets LTE service only ~67% of the time. In fact, in some cases the same "4G user" will even find themselves on 2G, or worse, with no service at all.
All connections are slow some of the time. All connections fail some of the time. All users experience these behaviors on their devices regardless of their carrier, geography, or underlying technology — 4G, 3G, or 2G.

Why does this matter?

Networks are not reliable, latency is not zero, and bandwidth is not infinite. Most applications ignore these simple truths and design for the best-case scenario, which leads to broken experiences whenever the network deviates from its optimal case. We treat these cases as exceptions but in reality they are the norm.
  • All 4G users are 3G users some of the time.
  • All 3G users are 2G users some of the time.
  • All 2G users are offline some of the time.
...

Testing against localhost, where latency is zero and bandwidth is infinite, is a recipe for failure.

You are using an unsupported browser and things might not work as intended. Please make sure you're using the latest version of Chrome, Firefox, Safari, or Edge.
mouthporn.net