Content Distribution
This repository contains configuration for the Content MLS and Content Mixer. It also contains the Content Bundle source code, which is used in the Content MLS and Content Mixer services.
This is supposed to be the new mono-repo for all things related to legacy content distribution. The following sections describe the current workflow of the legacy content distribution system.
The following picture illustrates the architecture of the content distribution system:

Content Bundle
The source code used in the Content MLS and Content Mixer services as dependency installed via Composer.
Content MLS
Content MLS serves as a Middle Layer Service (MLS) implemented in PHP/Symfony. It facilitates the management of various types of content used by the Statista platform and other internal services, including statistics, studies, branches, companies, dossiers, regions, and topics. The service acts as an API layer, providing endpoints for reading, creating, updating, and deleting content entities and is utilized by Content Mixer as a bundle. Content MLS is deployed on-premises servers and is accessible through internal networks.
The host for Content MLS is: lb-euc-mls-content-staging.statista.com
Sample REST API Requests
There are sample requests for the Content MLS available in the sample-requests.md file.
Content Mixer
The Content Mixer facilitates seamless integration between various components of our system, including content producers and consumers. By efficiently processing messages via RabbitMQ, it ensures smooth communication and data flow within our ecosystem. It accesses data via Content Bundle (Content MLS) by using it as a Symfony bundle which then requires a read-only database user to access the Content database.
Content Mixer utilizes RabbitMQ, a message broker, to handle communication between different services. Producers publish messages to specific queues within RabbitMQ. Consumers, including those managed by Content Mixer, listen to these queues and process the messages.
For instance:
- Producers: Send messages to various exchanges, like a content producer sending messages to a content exchange.
- Consumers: Listen to specified queues, such as the content consumer listening to the content queue.
The hosts for Content Mixer are:
- stat-hh-contentmixer-01.corp.statista.com
- stat-hh-contentmixer-02.corp.statista.com
- stat-hh-contentmixer-03.corp.statista.com
- stat-hh-contentmixer-04.corp.statista.com
Example Usage
The following command publishes statistics with IDs ranging from 250000 to 300000:
/usr/bin/php /var/www/contentmixer/current/app/console publish:content Statistic --from=250000 --to=300000