Insights into the core architecture of Shopware 6

ShopwarePlatform_BLOG

In our blog post today you will get insights into the core architecture of Shopware 6. Shopware 6 is an open source eCommerce platform built by the ideas and the spirit of its community. By leveraging state of the art technologies such as Symfony and Vue.js, Shopware 6 offers low complexity, modular adaptability, and good maintainability. With Shopware 6, all aspects of your platform can be controlled via API, allowing you to automate various third-party processes in Shopware.

The diagram above shows how the Shopware platform fits into your business. It provides web frontends for managing and trading across a variety of distribution channels. It has a number of user interfaces and provides the ability to connect to your own infrastructure and external services through REST APIs.

Three top-level building blocks of the Shopware 6 platform

Shopware core

The Core is the center of the platform and encompasses all eCommerce-specific workflows and resources. It is constructed as a modular, not strictly layered monolith. The modules are categorized and distributed to different directories.

Shopware admin

The Administration is a Single Page Application that provides a rich user interface on top of REST-API based communication with the core. It is an Interaction-Oriented-System following the example of the Web-Components patterns - albeit through Vue.js.

Shopware storefront

The Storefront is a Web-UI that provides the customer view and operates the sales channel interfaces of the core. The Storefront component, conceptually similar to the Administration, sits on top of the Core. Unlike the Administration, the Storefront is a sales channel and executes in the same process as the Core. It is architecturally in part a "backend for frontends" and a classic PHP application with HTML rendering, JavaScrip enhancements (along the lines of graceful degradation) and SASS styling as an extension of the Bootstrap Framework.

More detailed information can be found in our documentation.

Repository structure

The awesome fact that Shopware 6 now is a "vendor dependency leads to a multi-repo structure. Here is an overview showing you the structure of the different repositories and which one to clone if you want to set up a shop. Shopware 6 consists of multiple repositories, two of them are particularly important for you.

shopware/platform

This repository is a monorepository containing all modules. This is where the Shopware core is developed. You need it as a dependency in your projects. It is easy to make changes across all modules to maintain stability. Here you contribute to the development via pull requests. It's split into multiple repositories for production setups, all read-only.

shopware/development

This repository is the development template and where your journey with Shopware starts.

Project template

The project template is a slight deviation of the Symfony project template. It connects your web server to the platform as an entry point. If you are familiar with Symfony projects, you’ll probably feel home. The template can also be customized for your project needs. For example, do you remember Shopware Playground? Our exclusive disguised preview of Shopware 6? It was an additional project template that had a lot of customization options to connect AWS managed services, collect metrics and make it possible to create a multi-tenant system on a large container infrastructure. All instances were fully isolated from each other and there was no need to change anything in our Shopware 6 code base.

You are a part of the core

Every Shopware plugin is an extended Symfony plugin, so your code is basically part of the core! Since with great power comes great responsibility, you may want to learn more about how the core works and how you can develop your own plugins. Get the full story on docs.shopware.com, watch some videos on academy.shopware.com or listen to our core architects Jan Bücker and Jonas Elfring right here: