Connector for SAP Commerce Cloud Manual / Version 2107
Table Of ContentsConfiguring the Commerce Adapter
The physical connection to the Hybris Commerce system is configured in the Commerce Adapter. The Commerce Adapter itself communicates via SAP REST API calls with the Hybris system.
The Commerce Adapter comes along with a set of configuration properties. Most of them have defaults and need no further customization.
For basic configuration you should set the following properties:
hybris.host
hybris.store-front-host
hybris.store-front-url
hybris.asset-url
hybris.user
hybris.password
For more details and the full set of configuration properties see Chapter 9, Commerce Adapter Properties.
Sine version 1.2.0
, the commerce-adapter-hybris
expects to be connected
to SAP Commerce Cloud version 2005 by default. To connect to an older SAP Commerce Cloud version, the adapter must
be started with the Spring profile hybris-1905
activated.
Starting the Commerce Adapter
This guide describes how to build and run the commerce-adapter-hybris
Docker container.
Prerequisites to be installed:
Maven
Docker
Docker Compose (optional)
CoreMedia provides a Docker setup for the SAP Commerce Cloud Connector. It is part of a dedicated CoreMedia SAP Commerce Cloud Connector Contributions Repository.
After cloning the workspace, a coremedia/commerce-adapter-hybris
Docker image
can be build via mvn clean install
command.
To run the commerce-adapter-hybris
Docker container, the configuration properties for the adapter
must be set (see above). Spring Boot offers several ways to set the configuration properties, see
Spring Boot Reference Guide - 24. Externalized Configuration.
When starting the Docker container, this will probably lead
to setting either environment variables (using the Docker option --env
or --env-file
)
or mounting a configuration file (using the Docker option --volume
).
The Docker container can be started with the command
docker run \ --detach \ --rm \ --name commerce-adapter-hybris \ --publish 44265:6565 \ --publish 44281:8081 \ [--env ...|--env-file ...|--volume] \ coremedia/commerce-adapter-hybris:${ADAPTER_VERSION}
To run the commerce-adapter-hybris
Docker container with the CoreMedia CMCC Docker environment,
add the commerce-adapter-hybris.yml
compose file that is provided with the CoreMedia Blueprint Workspace
to the COMPOSE_FILE
variable in the Docker Compose .env
file. Ensure that the environment
variables that are passed to the Docker container are also defined in the .env
file:
COMPOSE_FILE=compose/default.yml:compose/commerce-adapter-hybris.yml HYBRIS_HOST=... ...
The commerce-adapter-hybris
container
is started with the CoreMedia CMCC Docker environment when running
docker compose up --detach
Detailed information about how to set up the CoreMedia CMCC Docker environment can be found in Chapter 3, Docker Setup in Deployment Manual.