Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ Features and changes [presentation video](https://sapvideoa35699dc5.hana.ondeman

# Requirements

- SAP Commerce (>=1811)
- SAP Commerce (>=2211-jdk21.x)
- Tested with source databases:
- Azure SQL
- MySQL (5.7)
Expand Down
11 changes: 11 additions & 0 deletions REUSE.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
version = 1
SPDX-PackageName = "SAP Commerce DB Sync"
SPDX-PackageSupplier = "[email protected]"
SPDX-PackageDownloadLocation = "https://github.com/SAP/sap-commerce-db-sync"
SPDX-PackageComment = "The code in this project may include calls to APIs (\"API Calls\") of\n SAP or third-party products or services developed outside of this project\n (\"External Products\").\n \"APIs\" means application programming interfaces, as well as their respective\n specifications and implementing code that allows software to communicate with\n other software.\n API Calls to External Products are not licensed under the open source license\n that governs this project. The use of such API Calls and related External\n Products are subject to applicable additional agreements with the relevant\n provider of the External Products. In no event shall the open source license\n that governs this project grant any rights in or to any External Products,or\n alter, expand or supersede any terms of the applicable additional agreements.\n If you have a valid license agreement with SAP for the use of a particular SAP\n External Product, then you may make use of any API Calls included in this\n project's code for that SAP External Product, subject to the terms of such\n license agreement. If you do not have a valid license agreement for the use of\n a particular SAP External Product, then you may only make use of any API Calls\n in this project for that SAP External Product for your internal, non-productive\n and non-commercial test and evaluation of such API Calls. Nothing herein grants\n you any rights to use or access any SAP External Product, or provide any third\n parties the right to use of access any SAP External Product, through API Calls."

[[annotations]]
path = "**"
precedence = "aggregate"
SPDX-FileCopyrightText = "2025 SAP SE or an SAP affiliate company and SAP Commerce DB Sync contributors"
SPDX-License-Identifier = "Apache-2.0"
2 changes: 1 addition & 1 deletion commercedbsync/buildcallbacks.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!--
~ Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
~ Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
~ License: Apache-2.0
~
-->
Expand Down
2 changes: 1 addition & 1 deletion commercedbsync/extensioninfo.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>

<!--
~ Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
~ Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
~ License: Apache-2.0
~
--><extensioninfo xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="extensioninfo.xsd">
Expand Down
2 changes: 1 addition & 1 deletion commercedbsync/external-dependencies.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<!--
~ Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
~ Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
~ License: Apache-2.0
~
-->
Expand Down
9 changes: 8 additions & 1 deletion commercedbsync/project.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# License: Apache-2.0
#
#
Expand Down Expand Up @@ -684,6 +684,13 @@ migration.media.container.prefix=${db.tableprefix}
# @optional true
##
migration.media.container.suffix=
##
# Allow to disable the validation, that source database is not CCv2 managed database
#
# @values true or false
# @optional true
##
migration.disable.source.db.check=false

# Enhanced Logging
log4j2.appender.migrationAppender.type=Console
Expand Down
2 changes: 1 addition & 1 deletion commercedbsync/resources/commercedbsync-beans.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!--
~ Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
~ Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
~ License: Apache-2.0
~
-->
Expand Down
2 changes: 1 addition & 1 deletion commercedbsync/resources/commercedbsync-items.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!--
~ Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
~ Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
~ License: Apache-2.0
~
-->
Expand Down
2 changes: 1 addition & 1 deletion commercedbsync/resources/commercedbsync-spring.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
~ Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
~ Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
~ License: Apache-2.0
~
-->
Expand Down
4 changes: 2 additions & 2 deletions commercedbsync/resources/groovy/MigrationSummaryScript.groovy
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
/*
* Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/

package groovy

import de.hybris.platform.util.Config
import org.apache.commons.lang.StringUtils
import org.apache.commons.lang3.StringUtils

import java.util.stream.Collectors

Expand Down
2 changes: 1 addition & 1 deletion commercedbsync/resources/groovy/ddlaltercreate.groovy
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,18 +38,11 @@ INSERT_UPDATE CompositeEntry;code[unique=true];executableCronJob(code)
;reverseMigrateTableEntry;reverseFullMigrationJob
;reverseMigrateIncrementalEntry;reverseIncrementalMigrationJob

INSERT_UPDATE CompositeCronJob;code[unique=true];job(code);sessionLanguage(isoCode)[default=en];
;compositeDatabaseMigrationJob;compositeJobPerformable;
;compositeTableMigrationJob;compositeJobPerformable;
;compositeIncrementalMigrationJob;compositeJobPerformable;
;compositeReverseTableMigrationJob;compositeJobPerformable;
;compositeReverseIncrementalMigrationJob;compositeJobPerformable;

INSERT_UPDATE CompositeCronJob;code[unique=true];compositeEntries(code)[mode = append]
;compositeDatabaseMigrationJob;prepForDbMigrationEntry,migrateDatabaseEntry
;compositeTableMigrationJob;prepForTableMigrationEntry,migrateTableEntry
;compositeIncrementalMigrationJob;prepForIncrementalMigrationEntry,migrateIncrementalEntry
;compositeReverseTableMigrationjob;prepForReverseTableMigrationEntry,reverseMigrateTableEntry
;compositeReverseIncrementalMigrationJob;prepForReverseIncrementalMigrationEntry,reverseMigrateIncrementalEntry
INSERT_UPDATE CompositeCronJob;code[unique=true];job(code);compositeEntries(code)[mode = append];sessionLanguage(isoCode)[default=en]
;compositeDatabaseMigrationJob;compositeJobPerformable;prepForDbMigrationEntry,migrateDatabaseEntry;
;compositeTableMigrationJob;compositeJobPerformable;prepForTableMigrationEntry,migrateTableEntry;
;compositeIncrementalMigrationJob;compositeJobPerformable;prepForIncrementalMigrationEntry,migrateIncrementalEntry;
;compositeReverseTableMigrationjob;compositeJobPerformable;prepForReverseTableMigrationEntry,reverseMigrateTableEntry;
;compositeReverseIncrementalMigrationJob;compositeJobPerformable;prepForReverseIncrementalMigrationEntry,reverseMigrateIncrementalEntry;


Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# License: Apache-2.0
#
#
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# License: Apache-2.0
#
#
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# License: Apache-2.0
#
#
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# License: Apache-2.0
#
#
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# License: Apache-2.0
#
#
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# License: Apache-2.0
#
#
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# License: Apache-2.0
#
#
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# License: Apache-2.0
#
#
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# License: Apache-2.0
#
#
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
# License: Apache-2.0
#
#
Expand Down
6 changes: 3 additions & 3 deletions commercedbsync/resources/sql/createSchedulerTablesHANA.sql
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,8 @@ CREATE TABLE MIGRATIONTOOLKIT_TABLECOPYBATCHES_PART (
pipelinename NVARCHAR(255) NOT NULL,
lowerBoundary NVARCHAR(255) NOT NULL,
upperBoundary NVARCHAR(255) NULL,
partition VARCHAR(128) NOT NULL,
PRIMARY KEY (migrationid, batchId, pipelinename, partition)
partKey VARCHAR(128) NOT NULL,
PRIMARY KEY (migrationid, batchId, pipelinename, partKey)
);

#
Expand Down Expand Up @@ -344,7 +344,7 @@ WHERE
AND total > completed;

/*
* Copyright: 2022 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/
Expand Down
4 changes: 2 additions & 2 deletions commercedbsync/resources/sql/createSchedulerTablesMSSQL.sql
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ CREATE TABLE MIGRATIONTOOLKIT_TABLECOPYBATCHES_PART (
pipelinename NVARCHAR(255) NOT NULL,
lowerBoundary NVARCHAR(255) NOT NULL,
upperBoundary NVARCHAR(255) NULL,
partition VARCHAR(128) NOT NULL,
PRIMARY KEY (migrationid, batchId, pipelinename, partition)
partKey VARCHAR(128) NOT NULL,
PRIMARY KEY (migrationid, batchId, pipelinename, partKey)
);

DROP TABLE IF EXISTS MIGRATIONTOOLKIT_TABLECOPYSTATUS;
Expand Down
4 changes: 2 additions & 2 deletions commercedbsync/resources/sql/createSchedulerTablesMYSQL.sql
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@ CREATE TABLE MIGRATIONTOOLKIT_TABLECOPYBATCHES_PART
pipelinename VARCHAR(255) NOT NULL,
lowerBoundary VARCHAR(255) NOT NULL,
upperBoundary VARCHAR(255) NULL,
partition VARCHAR(128) NOT NULL,
PRIMARY KEY (migrationid, batchId, pipelinename, partition)
partKey VARCHAR(128) NOT NULL,
PRIMARY KEY (migrationid, batchId, pipelinename, partKey)
);
#
DROP TABLE IF EXISTS MIGRATIONTOOLKIT_TABLECOPYSTATUS;
Expand Down
4 changes: 2 additions & 2 deletions commercedbsync/resources/sql/createSchedulerTablesORACLE.sql
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,8 @@ CREATE TABLE MIGRATIONTOOLKIT_TABLECOPYBATCHES_PART (
pipelinename NVARCHAR2(255) NOT NULL,
lowerBoundary NVARCHAR2(255) NOT NULL,
upperBoundary NVARCHAR2(255) NULL,
partition VARCHAR(128) NOT NULL,
PRIMARY KEY (migrationid, batchId, pipelinename, partition)
partKey VARCHAR(128) NOT NULL,
PRIMARY KEY (migrationid, batchId, pipelinename, partKey)
)
/

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@ CREATE TABLE MIGRATIONTOOLKIT_TABLECOPYBATCHES_PART (
pipelinename VARCHAR(255) NOT NULL,
lowerBoundary VARCHAR(255) NOT NULL,
upperBoundary VARCHAR(255) NULL,
partition VARCHAR(128) NOT NULL,
PRIMARY KEY (migrationid, batchId, pipelinename, partition)
partKey VARCHAR(128) NOT NULL,
PRIMARY KEY (migrationid, batchId, pipelinename, partKey)
);

#
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ CREATE TABLE MIGRATIONTOOLKIT_SCHEMADIFFSTATUS (
completed INT NOT NULL DEFAULT 0,
failed INT NOT NULL DEFAULT 0,
status VARCHAR(255) NOT NULL DEFAULT 'RUNNING',
sqlScript TEXT NULL
sqlScript MEDIUMTEXT NULL
);
#
DROP TRIGGER IF EXISTS MIGRATIONTOOLKIT_SCHEMADIFFSTATUS_Insert;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright: 2023 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright: 2023 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright: 2023 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright: 2023 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright: 2023 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright: 2023 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright: 2023 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright: 2023 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright: 2023 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright: 2023 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright: 2023 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright: 2023 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright: 2023 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright: 2023 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright: 2023 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright: 2023 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright: 2023 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* Copyright: 2025 SAP SE or an SAP affiliate company and commerce-db-synccontributors.
* License: Apache-2.0
*
*/
Expand Down
Loading