An ORM (object-relational mapping) is a layer in a program that translates data from the database, such as a shop's orders or products, into objects in the program code and back.
One example in PHP PHP PHP is a widely used, general-purpose, open-source scripting language that is especially suited to web development; the name is a recursive acronym for 'PHP: Hypertext Preprocessor'. is Doctrine ORM. The Doctrine documentation says the ORM aims to simplify the translation between database rows and the PHP object model. Another stated aim is a complete separation of business logic from the way data is stored in the database. Technically, Doctrine ORM builds on Doctrine DBAL DBAL A DBAL (database abstraction layer), such as Doctrine DBAL, is a program layer that offers a single interface to databases from different vendors and bridges most of the differences between them. , which can also be used on its own, without the ORM.
Shopware 5
Shopware
Shopware is e-commerce software from shopware AG in Schöppingen, Germany; the vendor says its current product, Shopware 6, is a complete redevelopment of Shopware 5. Read in the glossary → uses Doctrine too, and keeps its Doctrine models in the engine/Shopware/Models directory. Merchants see nothing of this layer. Some extensions, however, listen for the events the ORM uses to announce changes. Whether such an extension learns that the shop's data has changed depends on this layer.
Our Symfony Symfony Symfony is an open-source PHP framework, a ready-made foundation for web applications, released under the MIT licence and developed by its community to a fixed release schedule. Read in the glossary → applications use Doctrine as well. When debugging, we pay attention to how data is written. Shopware 5 showed us why: anything written directly through the DBAL bypasses the ORM and triggers none of its events, so a plugin Plugin A plugin is an add-on that extends software such as a shop system with additional features and can be installed separately from it. Read in the glossary → listening for those events misses the change.
See also
-
Shopware
Shopware is e-commerce software from shopware AG in Schöppingen, Germany; the vendor says its current product, Shopware 6, is a complete redevelopment of Shopware 5.
E-commerce
-
API
An API (application programming interface) is a defined set of functions and rules that lets one piece of software use the features or data of another system or service.
Cross-cutting
-
Symfony
Symfony is an open-source PHP framework, a ready-made foundation for web applications, released under the MIT licence and developed by its community to a fixed release schedule.
Cross-cutting
Sources
-
Doctrine ORM Documentation (current): Architecture (opens in a new tab)
Doctrine Project (doctrine-project.org) accessed
-
Doctrine ORM Documentation (current): Getting Started with Doctrine (opens in a new tab)
Doctrine Project (doctrine-project.org) accessed
-
Doctrine DBAL Documentation (current, 4.6): Introduction (opens in a new tab)
Doctrine Project (doctrine-project.org) accessed
-
Shopware 5 Developer Guides: Plugin quick start guide (opens in a new tab)
SafeFive (offiziell fortgeführte Shopware-5-Dokumentation) accessed