Contact
Get in touch with us so that we can create a digital project after a free initial consultation and work out a roadmap together.
Learn more
Anyone working in web development will likely refer to Pimcore as a data powerhouse. And the CMS has certainly earned this title: there are very few systems that store, consolidate, and structure as much data. Pimcore goes even further by seamlessly exchanging this data with other systems – thanks to Pimcore Datahub. In this blog post, we’ll take an in-depth look at this central interface within Pimcore and guide you through the installation process, so you can also bring your data into the online world with the CMS!
Before we dive deeper, let’s take a step back and address the question of what a data hub actually is. In the context of Product Information Management (PIM) and Master Data Management (MDM), a data hub simplifies the transfer of data from one system to another. It provides a single access point for transferring data to a platform. For instance, a data hub can connect a PIM like Pimcore with an e-commerce platform such as Commerce Tools. Additionally, a data hub can also be used to process data for reports.
As you can see, a data hub is a true boon for technology. What used to be complicated and required specialized web developer skills is now simplified by the data hub, which allows for quick access to data.
Applied to Pimcore, the goals of the Pimcore Datahub are to simplify the transfer of data to and from Pimcore, including objects, documents, and assets, as well as to provide dedicated access control. The Pimcore Datahub has these features built-in, allowing admins to specify who is allowed to transfer or retrieve data in Pimcore and which data individual users can interact with.
It’s important to know how to activate your Pimcore Datahub in the backend. First, download the Datahub bundle via the Composer package manager. Open a shell and navigate to the main folder of the book source code. Then, run the following command to enter the Docker container:
docker-compose php bash
Then run the following command to download the Datahub package:
composer requiere pimcore/data-hub
If you have downloaded the bundle, you must activate it in order to use it. This can be done via the Tools I Bundles menu. Installing the package creates additional tables within the database structure.
Alternatively, you can perform these operations using the Bash commands:
php bin/console pimcore:bundle:enablePimcoreDatahubBundle
php bin/console pimcore:bundle:installPimcoreDatahubBundle
Once you have installed the Datahub package, you need to follow these steps to activate the bundle in Pimcore.
Install the following dependencies:
composer require pimcore/data-importer
Next, you need to ensure that the bundle is activated in the config/bundles.php file. To do this, add the following lines:
use Pimcore\Bundle\DataImporterBundle\PimcoreDataImporterBundle;
// ...
return [
// ...
// make sure PimcoreDataHubBundle is added before to that list
// ...
PimcoreDataImporterBundle::class => ['all' => true],
// ...
];
Then, install the package using the following command:
composer require pimcore/admin-ui-classic-bundle
The imports are executed asynchronously in the background. The following commands need to be run regularly for the command-based import:
– # Process import queue items that can be executed in parallel
*/5 * * * * * php /home/project/www/bin/console datahub:data-importer:process-queue-parallel –processes=5
# Process import queue items that need to be executed sequentially
*/5 * * * * * php /home/project/www/bin/console datahub:data-importer:process-queue-sequential
Since the Pimcore Datahub implementation in 2019, the application has impressed with a variety of features, starting with the configurable interface layer for data transfer and usage. Datahub is therefore the tool of choice for connecting Pimcore with any external systems and applications outside the internal PHP API – whether backend applications like ERP systems or frontend applications like your storefront.
In addition, Pimcore Datahub allows multiple endpoints to be defined for different use cases and target/source systems – all on a user-friendly graphical user interface (GUI), where data can be transformed and prepared without the need for in-depth coding knowledge.
One of the biggest advantages of the Pimcore Datahub, based on its features, is its high performance and scalability. The optimized data queries ensure fast response times, and the application is ideal for omnichannel strategies, as multiple systems can retrieve data simultaneously.
What sets Pimcore Datahub apart is the ability to define multiple key points for data transfer and usage. These are configured through settings that can be added in the Pimcore Admin Dashboard.
To do this, go to the Datahub configuration window and select an endpoint technology under Add Configuration. To complete the configuration, you need to define the following fields:
â—Ź General Settings
â—Ź Schema Configuration
â—Ź Security Definitions
â—Ź Additional Settings
The GraphQL API from Meta is undeniably one of the most popular query languages and runtime environments for APIs. It offers a flexible and efficient alternative to traditional REST APIs: unlike REST, where separate endpoints exist for different resources, GraphQL provides a central API interface for all data queries and mutations. Many development platforms, including Pimcore, have integrated GraphQL API support into their systems.
The popularity of the GraphQL query language lies in its ability to allow clients to retrieve data in a simple and intuitive way. To do this, the client makes a request to a single endpoint by sending a GraphQL query and specifying the required data.
GraphQL can be used for both reading and modifying data and is based on a schema that precisely defines which data is available and which queries are possible.
Pimcore uses GraphQL as an API interface to provide data from the Product Information Management (PIM), Digital Asset Management (DAM), and Content Management System (CMS). This allows developers to access specific product data, media assets, or structured content.
Here is an example:
- {
getProduct(id: "123") {
name
description
price
images {
url
}
}
}
In the background, Pimcore generates a schema and stores it in the following file:
/var/config/datahub-configurations.php file
GraphQL focuses more on describing the available data in its functionality. Pimcore Datahub allows you to configure a GraphQL schema via the user interface. To do this, simply click on Add Configuration in Datahub and select GraphQL from the dropdown. Once selected, you can insert a relevant description or add an SQL condition.
Whether it’s providing product data for e-commerce websites, integrating with external systems, or real-time synchronization of customer data across various applications, Pimcore Datahub makes it easier to transform your data into omnichannel experiences and bridges the gap from your PIM to your customers.
Would you like to learn more? Get in touch with us! As a Pimcore Gold Partner and long-time Pimcore user, we’ll answer all your questions, walk you through the application in a demo, and set up your Pimcore instance with Pimcore Datahub upon request.