Data Abstraction Layer

The DataAbstractionLayer (DAL) centrally handles data retrieval, modification and search through an object oriented interface. The following diagram illustrates the general architecture of the component.

Data abstraction layer

The dashed line in the middle represents the differentiation between userland and internal space. The different containers mean:

Represents the data of a single row in table in the storage. The entity may contain related data if you wished to fetch it this way.
A collection is the result set of a DAL search. It contains convenience methods and metadata related to the search.
Configuration file defining the fields, relations and entity- and collection-classes.
The repository is the main access point for every DAL request. It houses the basic methods to work with data.
All DAL requests dispatch events to trigger handling inside of Shopware 6. Be it adding static data, triggering re indexing or handling a file upload.

Table of contents

This category contains in depth descriptions of the different concerns of the Data Abstraction Layer.

Working with the Data Abstraction Layer

  • Read - Learn the basics on reading data
  • Search - Learn how to search for data
  • Write - Learn how to write entities
  • Translations - Working with translations
  • Custom fields - Add custom data to core entities
  • UUID - UUID handling explained

Extending existing Entities

Creating your own entities

Extending the Data Abstraction Layer