Chapter 4. Networking
Chapter 3 showed that structure and architecture in our applications are largely about communication between individual parts. This is common in software engineering and software architecture. However, web applications add another layer of complexity. Web applications must bridge the gap between client and server. They connect the user’s device with the computer of those providing the service, relying on one thing: a stable network.
In reality, the network is anything but stable. Especially on mobile devices, where users are constantly on the move, outages can occur more frequently. The interactive application on the client side often has no choice but to wait until a request finally completes and reports whether the transfer of the desired data was even successful. Impatient users will have already tried multiple times to press the Reload button to finally get a result. In vain.
Different applications have different network requirements. Constant updates from the server might be critical for some, less so for others. The size of data we can afford to transport varies just as much. A monitoring application that displays many graphs and dashboards based on a large dataset may assume a stable fiber connection and allow itself more data, whereas a mobile website that displays sports results for betting, accepts wagers, and needs to deliver the most critical information in a time-sensitive manner in an unpredictable environment, may send far fewer packets through ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access