Game project in the field of mobile streaming
Transfer giant volumes of data over the mobile Internet with minimal latency
For this project we were approached by a company that launches a new startup in the field of mobile streaming. They needed a technological platform to work with video, with the ability to organize broadcasts, as well as video storage and VoD services. The client part of the platform is a mobile application that interacts with the media platform via an API.
The key requirement was the need to work with minimal delays, as well as to take into account the peculiarities of transferring large data volumes via mobile Internet. To add challenge we were severely limited in computing power, as it was necessary to deploy the media service on the lowest possible configuration of hardware. And we had to ensure its smooth operation and guarantee that it will cope with high loads.
After estimating our options, it was decided to start with a small prototype, allowing for simple horizontal scaling. The key feature of the choosen architecture is the clustering of key components, which allows the platform to keep functioning in case of failure of one or more nodes.
The next step was the deployment of a media service. Streaming component was implemented on top of the Mediagram media-service very quickly. Next, we turned to for broadcasts recording. In order to show the video to all users, including those with low mobile Internet bandwidth, we have deployed an asynchronous encoding service based on a prioritized queue. The encoding request has been prioritized depending on the system load and the requested encoding quality (profile). Thus, we dramatically reduce the gap between video entering the platform and its appearance in the user feed.
Our solution includes many independent services, the performance of which must be monitored. For the log storage, we used NoSQL DB from Yandex called ClickHouse, for which we developed our own front-end that allows you to view all the logs in one place, as well as perform quick searches with filtering by the desired service, date, context, etc.
In parallel with the deployment of the video platform, there was ongoing development of API, as well as services specific to this project, which included a unified authentication service implemented on the basis of Jason Web Token, a service for sending push notifications to mobile devices, a user's feed managing system, and an interface for managing and content moderation, integration with the payment gateway, and many others.