The usual scheme for transferring data on the Internet is implemented in such a way that all users receive information directly from a specific server, which can be located far away.
On the other hand, the CDN service allows you to download content immediately, literally within a few seconds. It does not matter where the source server is located.
The scheme of work of CDN
The CDN provider to which the site is connected has a group of already configured servers located in a certain territory. These servers are designed primarily for the distribution of heavy static content, as well as streaming content because dynamics almost always load quickly.
Now, the user who requests the page is no longer redirected to the origin but to the nearest edge node. That is, a high-performance network of a provider is used to transfer content.
When transmitting streaming videos that are recorded in Live mode, the origins, after receiving the next video data packet, immediately rebroadcast it to border nodes, from which video content is downloaded by nearby users. This provides almost instantaneous loading.
How to organize the content distribution
Let’s see how to do it using the example of the G-Core Labs CDN service:
- Go to the CDN section.
- Click Create.
- Enter the name of the resource.
- Specify the content source – the domain of your site from where the CDN will take static files.
- Click Create.
The provider will create a default domain from which content will be distributed. The client can then change the default domain to a custom domain.
Now, when the page is loaded, all statics will be loaded by the distributed infrastructure of the provider.
At the same time, it is not at all necessary to use the server base of the site owner to load static content. It is much more convenient to set up distribution directly from the cloud storage, which provides faster and more stable downloads.