Update from 6.1.x to 6.2.0

This document describes the update from OXID eShop 6.1.0 and higher to OXID eShop 6.2.0. It differs from a standard update mainly in that the module configurations are taken from the database.

schritt Updating the shop

  1. In the file composer.json, which is located in the main directory of the shop, version must be changed. This concerns the section “require” and “require-dev”.

OXID eShop Community Edition 6.2.0

"require": {
   "oxid-esales/oxideshop-metapackage-ce": "v6.2.0"
},
"require-dev": {
   "oxid-esales/testing-library": "^v7.1.0",
   "incenteev/composer-parameter-handler": "^v2.0.0",
   "oxid-esales/oxideshop-ide-helper": "^v3.1.2",
   "oxid-esales/azure-theme": "^v1.4.2"
},

OXID eShop Professional Edition 6.2.0

"require": {
   "oxid-esales/oxideshop-metapackage-pe": "v6.2.0"
},
"require-dev": {
   "oxid-esales/testing-library": "^v7.1.0",
   "incenteev/composer-parameter-handler": "^v2.0.0",
   "oxid-esales/oxideshop-ide-helper": "^v3.1.2",
   "oxid-esales/azure-theme": "^v1.4.2"
},

OXID eShop Enterprise Edition 6.2.0

"require": {
   "oxid-esales/oxideshop-metapackage-ee": "v6.2.0"
},
"require-dev": {
   "oxid-esales/testing-library": "^v7.1.0",
   "incenteev/composer-parameter-handler": "^v2.0.0",
   "oxid-esales/oxideshop-ide-helper": "^v3.1.2",
   "oxid-esales/azure-theme": "^v1.4.2"
},
  1. Clear the directory with the temporary files of the shop, for example by calling a shell in the main directory of the shop and entering the following command:
rm -rf source/tmp/*
  1. Execute the following Composer command in the shell to update dependencies. The --no-dev parameter is specified when the development-related files are not needed.
composer update --no-plugins --no-scripts --no-dev
  1. Now copy the file overridablefunctions.php from the directory /vendor of the shop into the directory /source.
cp vendor/oxid-esales/oxideshop-ce/source/overridablefunctions.php source/
  1. With a second Composer command all scripts are executed to get the new compilation. For shop files, themes and modules it must be confirmed that the update will overwrite existing files. If you have included your own modules with type": "path" in your composer.json file, please answer the question for overwriting with No.
composer update --no-dev
  1. The third and last Composer command performs the migration of the database.
vendor/bin/oe-eshop-db_migrate migrations:migrate

schritt Updating the module configurations

In this step, settings and activation status of the modules belonging to the shop are transferred from the database to configuration files *.yaml.

  1. With the following Composer commands, which are called in the main directory of the shop, you install the OXID eShop update component.
composer require --no-update oxid-esales/oxideshop-update-component:"^1.0"
composer update --no-dev --no-interaction
  1. Clear the directory with the temporary files of the shop, for example by calling a shell in the main directory of the shop and entering the following command:
rm -rf source/tmp/*
  1. A default configuration is created for all modules located in the source/modules directory. To do this, the new OXID eShop Console is called with the following command:
vendor/bin/oe-console oe:oxideshop-update-component:install-all-modules
  1. The existing module data (module settings, class extension chains, activation status) are transferred from the database to the configuration files *.yaml.
vendor/bin/oe-console oe:oxideshop-update-component:transfer-module-data

After this step the option configured = true should be in the configuration file of all previously active modules. The configuration file now also contains the module settings. They are the same as those defined for the module in the administration panel.

  1. To avoid data redundancy and problems when activating modules, their status and settings are removed from the database.
vendor/bin/oe-console oe:oxideshop-update-component:delete-module-data-from-database
  1. All modules that were previously active are activated and the module settings are restored.
vendor/bin/oe-console oe:module:apply-configuration

Hint

In an Enterprise Edition environment with at least two shops and active legacy modules the command may trigger an error. The workaround is to run the command per individual shop by using parameter –shop-id.

Example:

vendor/bin/oe-console oe:module:apply-configuration --shop-id=1
vendor/bin/oe-console oe:module:apply-configuration --shop-id=2
  1. Uninstall the OXID eShop update component
composer remove --no-update oxid-esales/oxideshop-update-component
composer update --no-dev --no-interaction

schritt Removing old files

The file xd_receiver.htm from the /source directory is no longer needed and should be deleted.


Troubleshooting

Hints on possible problems with the transfer of status and settings of the modules can be found in the document Update from 6.1.x to 6.2.0 of the developer documentation.