2.1 Modern Products
No one really calls them programs anymore. A modern product could include dozens of programs, hundreds of internet services, and loads of APIs provided by a cloud data center (also known as data processing centers), where it's deployed.
Many modern products (if not all) operate with the Client-Server paradigm. That's when your device (phone, laptop, computer) runs a program responsible for communicating with you, while the critical functionality is on a remote server where all the important stuff happens.
Sometimes your client might interact with several independent servers, or a server from one product might communicate with a server from another product. It's like a global network of clients and servers, all interacting with each other.
So the modern application model is maybe better described by the Client-Internet-Server paradigm. There's just too much complex communication going on. There are even "smart communication channels" that autonomously decide who gets your request and when.
2.2 Clients
Client programs can be roughly divided into 4 categories:
- Desktop client — a program running on a computer.
- Mobile client — an app for iOS or Android.
- Web client — a website/web app running in a browser.
- Server client — an app running on another server.
And each of these can be broken down further. For example, a web client is a website or a web app, which means it consists of a Browser and a Site that loads into it. Not all browsers are the same and they can operate differently.
Even if we take the most common browser, there's still the site that loads into it. A site usually consists of three things:
- HTML
- CSS
- JavaScript
"It's simple," you might say. But no one writes sites using just HTML and JavaScript anymore. Websites are now built using full-fledged frameworks like React, Angular, or Vue. And they're not just sites; they're full-blown web apps with their builds, tests, and paradigms.
Plain CSS isn't used anymore, either. There are CSS preprocessors that help generate it, and whole CSS frameworks exist now. There are even special CSS frameworks for email templates to ensure your email looks great both in the browser and in most mail clients.
Hardly anyone codes in pure JavaScript today — major web apps are created with TypeScript, which is then compiled to JavaScript. You get the idea...
2.3 Internet and Infrastructure
Client-server communication — sounds simple, right? But even their relationship has changed.
Your product is likely to be hosted in one of the modern data centers. Many companies worldwide offer various hosting services for your products, whether it's on their servers or your own physical servers. Any service you want, if you can pay for it.
A physical server is no longer physical. All modern data centers offer virtual server leases. A virtual server is basically a virtual computer, and a single physical server can house dozens of them. It's convenient for server upgrades. If you need more memory, you can add it to your virtual server in minutes.
But even this approach is becoming outdated. The trend now is moving to the cloud — where your product isn't just deployed on a virtual server in a data center but actively uses the extensive infrastructure and services of these data centers.
Need a server for backup storage? There's a ready-made convenient infrastructure in the cloud for that. Need a database with 99.9999999% reliability? They've got it too. Kafka, RabbitMQ, NoSQL? It's all there and easy to set up. Just keep those payments coming.
And these data centers and clouds become part of your product. For example, Amazon has tons of data centers worldwide, so they offer a CDN service: your public content will be cached on all Amazon data centers, and your users everywhere will get it faster.
Or you can route requests to your app's API through Amazon Gateway API, which allows for highly flexible interaction with your services. You can distribute loads across different services, fend off DDoS attacks, automate file uploads, set up smart caching, and much more.
Thus, between the client application and your services, there's a multitude of "smart communications" that you can and should configure. Even if you'll never do it personally, you should know they exist and can significantly affect your program's performance.
And we haven't even touched on routers, 5G towers, satellites, and undersea internet cables. You're streaming video from your server to your client, and it fails because the client has poor connectivity, constantly dropping the connection. Guess who has to solve that problem?
2.4 Server
The term "server" can mean so many different things. It's useful to know some of the most common ones.
Physical serverA physical server is equipment acting as a standalone computer with resources (CPU, memory, storage) used for data processing and ensuring the functioning of various software applications. These servers are installed in data centers, where they provide the power for hosting websites, applications, databases, and other services.
Virtual serverA virtual server is a software-emulated server running in the environment of a physical server. Virtualization technologies allow a single physical server to be divided into several isolated virtual servers, each with its operating system, independently rebootable and configurable.
Server program (e.g., Nginx)A server program, like Nginx, is server software used to process requests to web resources. Nginx is widely known as a web server that can also function as a mail proxy server and a reverse proxy server in microservices architectures, as well as a load balancer.
Database serverA database server is a specialized server used for managing databases and processing queries. It provides centralized data storage and processing, offering data access over the network. Database servers support transaction processing, data search and modification, ensuring reliable and secure information storage. Examples include MySQL, PostgreSQL, Oracle Database, and Microsoft SQL Server.
Somewhere in a data center, on one of the virtual servers, your Python and Django project will be running. It'll interact with the database, receive requests from NginX, and send logs of its actions to Splunk.
But thanks to your code, millions of users of your product will be happy. They'll use the product, pay for it, and in that case, the product owner will be happy too. The company's stock will rise, you'll get stock bonuses and be happy too. It's like some kind of happiness circle in nature :)
GO TO FULL VERSION