From c9d75a1ed183d0672dada94327aeae6c41f9b8d7 Mon Sep 17 00:00:00 2001 From: Juanma Rodriguez Escriche Date: Tue, 6 Aug 2024 12:51:55 +0200 Subject: [PATCH] Sync - HPOS: Update checksum fields to consider (#38713) * Change checksum fields for HPOS tables * Changelog * Version bump * Version bump * Version bump --- .../changelog/update-sync-hpos-checksum-fields-to-consider | 4 ++++ projects/packages/sync/composer.json | 2 +- projects/packages/sync/src/class-package-version.php | 2 +- .../packages/sync/src/replicastore/class-table-checksum.php | 6 ++++-- .../changelog/update-sync-hpos-checksum-fields-to-consider | 5 +++++ .../plugins/automattic-for-agencies-client/composer.lock | 4 ++-- .../changelog/update-sync-hpos-checksum-fields-to-consider | 5 +++++ projects/plugins/backup/composer.lock | 4 ++-- .../changelog/update-sync-hpos-checksum-fields-to-consider | 5 +++++ projects/plugins/boost/composer.lock | 4 ++-- .../changelog/update-sync-hpos-checksum-fields-to-consider | 5 +++++ projects/plugins/jetpack/composer.lock | 4 ++-- .../changelog/update-sync-hpos-checksum-fields-to-consider | 5 +++++ projects/plugins/migration/composer.lock | 4 ++-- .../changelog/update-sync-hpos-checksum-fields-to-consider | 5 +++++ projects/plugins/mu-wpcom-plugin/composer.lock | 4 ++-- .../changelog/update-sync-hpos-checksum-fields-to-consider | 5 +++++ projects/plugins/protect/composer.lock | 4 ++-- .../changelog/update-sync-hpos-checksum-fields-to-consider | 5 +++++ projects/plugins/search/composer.lock | 4 ++-- .../changelog/update-sync-hpos-checksum-fields-to-consider | 5 +++++ projects/plugins/social/composer.lock | 4 ++-- .../changelog/update-sync-hpos-checksum-fields-to-consider | 5 +++++ projects/plugins/starter-plugin/composer.lock | 4 ++-- .../changelog/update-sync-hpos-checksum-fields-to-consider | 5 +++++ projects/plugins/videopress/composer.lock | 4 ++-- .../changelog/update-sync-hpos-checksum-fields-to-consider | 5 +++++ projects/plugins/wpcomsh/composer.lock | 4 ++-- 28 files changed, 94 insertions(+), 28 deletions(-) create mode 100644 projects/packages/sync/changelog/update-sync-hpos-checksum-fields-to-consider create mode 100644 projects/plugins/automattic-for-agencies-client/changelog/update-sync-hpos-checksum-fields-to-consider create mode 100644 projects/plugins/backup/changelog/update-sync-hpos-checksum-fields-to-consider create mode 100644 projects/plugins/boost/changelog/update-sync-hpos-checksum-fields-to-consider create mode 100644 projects/plugins/jetpack/changelog/update-sync-hpos-checksum-fields-to-consider create mode 100644 projects/plugins/migration/changelog/update-sync-hpos-checksum-fields-to-consider create mode 100644 projects/plugins/mu-wpcom-plugin/changelog/update-sync-hpos-checksum-fields-to-consider create mode 100644 projects/plugins/protect/changelog/update-sync-hpos-checksum-fields-to-consider create mode 100644 projects/plugins/search/changelog/update-sync-hpos-checksum-fields-to-consider create mode 100644 projects/plugins/social/changelog/update-sync-hpos-checksum-fields-to-consider create mode 100644 projects/plugins/starter-plugin/changelog/update-sync-hpos-checksum-fields-to-consider create mode 100644 projects/plugins/videopress/changelog/update-sync-hpos-checksum-fields-to-consider create mode 100644 projects/plugins/wpcomsh/changelog/update-sync-hpos-checksum-fields-to-consider diff --git a/projects/packages/sync/changelog/update-sync-hpos-checksum-fields-to-consider b/projects/packages/sync/changelog/update-sync-hpos-checksum-fields-to-consider new file mode 100644 index 0000000000000..4268b727bb631 --- /dev/null +++ b/projects/packages/sync/changelog/update-sync-hpos-checksum-fields-to-consider @@ -0,0 +1,4 @@ +Significance: minor +Type: changed + +Sync: Change fields for HPOS checksums diff --git a/projects/packages/sync/composer.json b/projects/packages/sync/composer.json index 8799ba2a01ed2..3b23c37b2007b 100644 --- a/projects/packages/sync/composer.json +++ b/projects/packages/sync/composer.json @@ -59,7 +59,7 @@ "link-template": "https://github.com/Automattic/jetpack-sync/compare/v${old}...v${new}" }, "branch-alias": { - "dev-trunk": "3.4.x-dev" + "dev-trunk": "3.5.x-dev" }, "dependencies": { "test-only": [ diff --git a/projects/packages/sync/src/class-package-version.php b/projects/packages/sync/src/class-package-version.php index 909d809a44d0a..ceaa8233b467c 100644 --- a/projects/packages/sync/src/class-package-version.php +++ b/projects/packages/sync/src/class-package-version.php @@ -12,7 +12,7 @@ */ class Package_Version { - const PACKAGE_VERSION = '3.4.1'; + const PACKAGE_VERSION = '3.5.0-alpha'; const PACKAGE_SLUG = 'sync'; diff --git a/projects/packages/sync/src/replicastore/class-table-checksum.php b/projects/packages/sync/src/replicastore/class-table-checksum.php index 02aec42a2904e..2413a5e9f8014 100644 --- a/projects/packages/sync/src/replicastore/class-table-checksum.php +++ b/projects/packages/sync/src/replicastore/class-table-checksum.php @@ -312,7 +312,8 @@ protected function get_default_tables() { 'table' => "{$wpdb->prefix}wc_orders", 'range_field' => 'id', 'key_fields' => array( 'id' ), - 'checksum_text_fields' => array( 'type', 'status', 'payment_method_title' ), + 'checksum_fields' => array( 'date_updated_gmt', 'total_amount' ), + 'checksum_text_fields' => array( 'type', 'status' ), 'filter_values' => array( 'type' => array( 'operator' => 'IN', @@ -336,7 +337,8 @@ protected function get_default_tables() { 'table' => "{$wpdb->prefix}wc_order_operational_data", 'range_field' => 'order_id', 'key_fields' => array( 'order_id' ), - 'checksum_text_fields' => array( 'order_key', 'cart_hash' ), + 'checksum_fields' => array( 'date_paid_gmt', 'date_completed_gmt' ), + 'checksum_text_fields' => array( 'order_key' ), 'parent_table' => 'wc_orders', 'parent_join_field' => 'id', 'table_join_field' => 'order_id', diff --git a/projects/plugins/automattic-for-agencies-client/changelog/update-sync-hpos-checksum-fields-to-consider b/projects/plugins/automattic-for-agencies-client/changelog/update-sync-hpos-checksum-fields-to-consider new file mode 100644 index 0000000000000..9aa70e3ec1f75 --- /dev/null +++ b/projects/plugins/automattic-for-agencies-client/changelog/update-sync-hpos-checksum-fields-to-consider @@ -0,0 +1,5 @@ +Significance: patch +Type: changed +Comment: Updated composer.lock. + + diff --git a/projects/plugins/automattic-for-agencies-client/composer.lock b/projects/plugins/automattic-for-agencies-client/composer.lock index 3f8db4e218e78..ca048b7091d74 100644 --- a/projects/plugins/automattic-for-agencies-client/composer.lock +++ b/projects/plugins/automattic-for-agencies-client/composer.lock @@ -862,7 +862,7 @@ "dist": { "type": "path", "url": "../../packages/sync", - "reference": "2965d36db9a224b6e142e46c92358b353eca463a" + "reference": "e8ba4ea2e343876391215025258d0454d88bdddc" }, "require": { "automattic/jetpack-connection": "@dev", @@ -895,7 +895,7 @@ "link-template": "https://github.com/Automattic/jetpack-sync/compare/v${old}...v${new}" }, "branch-alias": { - "dev-trunk": "3.4.x-dev" + "dev-trunk": "3.5.x-dev" }, "dependencies": { "test-only": [ diff --git a/projects/plugins/backup/changelog/update-sync-hpos-checksum-fields-to-consider b/projects/plugins/backup/changelog/update-sync-hpos-checksum-fields-to-consider new file mode 100644 index 0000000000000..9aa70e3ec1f75 --- /dev/null +++ b/projects/plugins/backup/changelog/update-sync-hpos-checksum-fields-to-consider @@ -0,0 +1,5 @@ +Significance: patch +Type: changed +Comment: Updated composer.lock. + + diff --git a/projects/plugins/backup/composer.lock b/projects/plugins/backup/composer.lock index 67f5eea68e880..7f3af360f5f98 100644 --- a/projects/plugins/backup/composer.lock +++ b/projects/plugins/backup/composer.lock @@ -1741,7 +1741,7 @@ "dist": { "type": "path", "url": "../../packages/sync", - "reference": "2965d36db9a224b6e142e46c92358b353eca463a" + "reference": "e8ba4ea2e343876391215025258d0454d88bdddc" }, "require": { "automattic/jetpack-connection": "@dev", @@ -1774,7 +1774,7 @@ "link-template": "https://github.com/Automattic/jetpack-sync/compare/v${old}...v${new}" }, "branch-alias": { - "dev-trunk": "3.4.x-dev" + "dev-trunk": "3.5.x-dev" }, "dependencies": { "test-only": [ diff --git a/projects/plugins/boost/changelog/update-sync-hpos-checksum-fields-to-consider b/projects/plugins/boost/changelog/update-sync-hpos-checksum-fields-to-consider new file mode 100644 index 0000000000000..9aa70e3ec1f75 --- /dev/null +++ b/projects/plugins/boost/changelog/update-sync-hpos-checksum-fields-to-consider @@ -0,0 +1,5 @@ +Significance: patch +Type: changed +Comment: Updated composer.lock. + + diff --git a/projects/plugins/boost/composer.lock b/projects/plugins/boost/composer.lock index 5f20441358b9f..e84a2f563cf3c 100644 --- a/projects/plugins/boost/composer.lock +++ b/projects/plugins/boost/composer.lock @@ -1725,7 +1725,7 @@ "dist": { "type": "path", "url": "../../packages/sync", - "reference": "2965d36db9a224b6e142e46c92358b353eca463a" + "reference": "e8ba4ea2e343876391215025258d0454d88bdddc" }, "require": { "automattic/jetpack-connection": "@dev", @@ -1758,7 +1758,7 @@ "link-template": "https://github.com/Automattic/jetpack-sync/compare/v${old}...v${new}" }, "branch-alias": { - "dev-trunk": "3.4.x-dev" + "dev-trunk": "3.5.x-dev" }, "dependencies": { "test-only": [ diff --git a/projects/plugins/jetpack/changelog/update-sync-hpos-checksum-fields-to-consider b/projects/plugins/jetpack/changelog/update-sync-hpos-checksum-fields-to-consider new file mode 100644 index 0000000000000..a1c1831fa1ef7 --- /dev/null +++ b/projects/plugins/jetpack/changelog/update-sync-hpos-checksum-fields-to-consider @@ -0,0 +1,5 @@ +Significance: patch +Type: other +Comment: Updated composer.lock. + + diff --git a/projects/plugins/jetpack/composer.lock b/projects/plugins/jetpack/composer.lock index 82780ce7c1020..83d7e7ea42e59 100644 --- a/projects/plugins/jetpack/composer.lock +++ b/projects/plugins/jetpack/composer.lock @@ -2683,7 +2683,7 @@ "dist": { "type": "path", "url": "../../packages/sync", - "reference": "2965d36db9a224b6e142e46c92358b353eca463a" + "reference": "e8ba4ea2e343876391215025258d0454d88bdddc" }, "require": { "automattic/jetpack-connection": "@dev", @@ -2716,7 +2716,7 @@ "link-template": "https://github.com/Automattic/jetpack-sync/compare/v${old}...v${new}" }, "branch-alias": { - "dev-trunk": "3.4.x-dev" + "dev-trunk": "3.5.x-dev" }, "dependencies": { "test-only": [ diff --git a/projects/plugins/migration/changelog/update-sync-hpos-checksum-fields-to-consider b/projects/plugins/migration/changelog/update-sync-hpos-checksum-fields-to-consider new file mode 100644 index 0000000000000..9aa70e3ec1f75 --- /dev/null +++ b/projects/plugins/migration/changelog/update-sync-hpos-checksum-fields-to-consider @@ -0,0 +1,5 @@ +Significance: patch +Type: changed +Comment: Updated composer.lock. + + diff --git a/projects/plugins/migration/composer.lock b/projects/plugins/migration/composer.lock index 7a23cec711bf6..a42ea2cbab246 100644 --- a/projects/plugins/migration/composer.lock +++ b/projects/plugins/migration/composer.lock @@ -1741,7 +1741,7 @@ "dist": { "type": "path", "url": "../../packages/sync", - "reference": "2965d36db9a224b6e142e46c92358b353eca463a" + "reference": "e8ba4ea2e343876391215025258d0454d88bdddc" }, "require": { "automattic/jetpack-connection": "@dev", @@ -1774,7 +1774,7 @@ "link-template": "https://github.com/Automattic/jetpack-sync/compare/v${old}...v${new}" }, "branch-alias": { - "dev-trunk": "3.4.x-dev" + "dev-trunk": "3.5.x-dev" }, "dependencies": { "test-only": [ diff --git a/projects/plugins/mu-wpcom-plugin/changelog/update-sync-hpos-checksum-fields-to-consider b/projects/plugins/mu-wpcom-plugin/changelog/update-sync-hpos-checksum-fields-to-consider new file mode 100644 index 0000000000000..9aa70e3ec1f75 --- /dev/null +++ b/projects/plugins/mu-wpcom-plugin/changelog/update-sync-hpos-checksum-fields-to-consider @@ -0,0 +1,5 @@ +Significance: patch +Type: changed +Comment: Updated composer.lock. + + diff --git a/projects/plugins/mu-wpcom-plugin/composer.lock b/projects/plugins/mu-wpcom-plugin/composer.lock index d04a4fa94fcf9..d6670b4496573 100644 --- a/projects/plugins/mu-wpcom-plugin/composer.lock +++ b/projects/plugins/mu-wpcom-plugin/composer.lock @@ -1506,7 +1506,7 @@ "dist": { "type": "path", "url": "../../packages/sync", - "reference": "2965d36db9a224b6e142e46c92358b353eca463a" + "reference": "e8ba4ea2e343876391215025258d0454d88bdddc" }, "require": { "automattic/jetpack-connection": "@dev", @@ -1539,7 +1539,7 @@ "link-template": "https://github.com/Automattic/jetpack-sync/compare/v${old}...v${new}" }, "branch-alias": { - "dev-trunk": "3.4.x-dev" + "dev-trunk": "3.5.x-dev" }, "dependencies": { "test-only": [ diff --git a/projects/plugins/protect/changelog/update-sync-hpos-checksum-fields-to-consider b/projects/plugins/protect/changelog/update-sync-hpos-checksum-fields-to-consider new file mode 100644 index 0000000000000..9aa70e3ec1f75 --- /dev/null +++ b/projects/plugins/protect/changelog/update-sync-hpos-checksum-fields-to-consider @@ -0,0 +1,5 @@ +Significance: patch +Type: changed +Comment: Updated composer.lock. + + diff --git a/projects/plugins/protect/composer.lock b/projects/plugins/protect/composer.lock index b5a2ba7b81bd2..3d1e8c5df1094 100644 --- a/projects/plugins/protect/composer.lock +++ b/projects/plugins/protect/composer.lock @@ -1654,7 +1654,7 @@ "dist": { "type": "path", "url": "../../packages/sync", - "reference": "2965d36db9a224b6e142e46c92358b353eca463a" + "reference": "e8ba4ea2e343876391215025258d0454d88bdddc" }, "require": { "automattic/jetpack-connection": "@dev", @@ -1687,7 +1687,7 @@ "link-template": "https://github.com/Automattic/jetpack-sync/compare/v${old}...v${new}" }, "branch-alias": { - "dev-trunk": "3.4.x-dev" + "dev-trunk": "3.5.x-dev" }, "dependencies": { "test-only": [ diff --git a/projects/plugins/search/changelog/update-sync-hpos-checksum-fields-to-consider b/projects/plugins/search/changelog/update-sync-hpos-checksum-fields-to-consider new file mode 100644 index 0000000000000..9aa70e3ec1f75 --- /dev/null +++ b/projects/plugins/search/changelog/update-sync-hpos-checksum-fields-to-consider @@ -0,0 +1,5 @@ +Significance: patch +Type: changed +Comment: Updated composer.lock. + + diff --git a/projects/plugins/search/composer.lock b/projects/plugins/search/composer.lock index 599700e78fef4..a601d6456e717 100644 --- a/projects/plugins/search/composer.lock +++ b/projects/plugins/search/composer.lock @@ -1746,7 +1746,7 @@ "dist": { "type": "path", "url": "../../packages/sync", - "reference": "2965d36db9a224b6e142e46c92358b353eca463a" + "reference": "e8ba4ea2e343876391215025258d0454d88bdddc" }, "require": { "automattic/jetpack-connection": "@dev", @@ -1779,7 +1779,7 @@ "link-template": "https://github.com/Automattic/jetpack-sync/compare/v${old}...v${new}" }, "branch-alias": { - "dev-trunk": "3.4.x-dev" + "dev-trunk": "3.5.x-dev" }, "dependencies": { "test-only": [ diff --git a/projects/plugins/social/changelog/update-sync-hpos-checksum-fields-to-consider b/projects/plugins/social/changelog/update-sync-hpos-checksum-fields-to-consider new file mode 100644 index 0000000000000..9aa70e3ec1f75 --- /dev/null +++ b/projects/plugins/social/changelog/update-sync-hpos-checksum-fields-to-consider @@ -0,0 +1,5 @@ +Significance: patch +Type: changed +Comment: Updated composer.lock. + + diff --git a/projects/plugins/social/composer.lock b/projects/plugins/social/composer.lock index 1e8b714472c29..7d40c72c69ef9 100644 --- a/projects/plugins/social/composer.lock +++ b/projects/plugins/social/composer.lock @@ -1736,7 +1736,7 @@ "dist": { "type": "path", "url": "../../packages/sync", - "reference": "2965d36db9a224b6e142e46c92358b353eca463a" + "reference": "e8ba4ea2e343876391215025258d0454d88bdddc" }, "require": { "automattic/jetpack-connection": "@dev", @@ -1769,7 +1769,7 @@ "link-template": "https://github.com/Automattic/jetpack-sync/compare/v${old}...v${new}" }, "branch-alias": { - "dev-trunk": "3.4.x-dev" + "dev-trunk": "3.5.x-dev" }, "dependencies": { "test-only": [ diff --git a/projects/plugins/starter-plugin/changelog/update-sync-hpos-checksum-fields-to-consider b/projects/plugins/starter-plugin/changelog/update-sync-hpos-checksum-fields-to-consider new file mode 100644 index 0000000000000..9aa70e3ec1f75 --- /dev/null +++ b/projects/plugins/starter-plugin/changelog/update-sync-hpos-checksum-fields-to-consider @@ -0,0 +1,5 @@ +Significance: patch +Type: changed +Comment: Updated composer.lock. + + diff --git a/projects/plugins/starter-plugin/composer.lock b/projects/plugins/starter-plugin/composer.lock index 9fcbdd07466a2..d7caef46710ae 100644 --- a/projects/plugins/starter-plugin/composer.lock +++ b/projects/plugins/starter-plugin/composer.lock @@ -1597,7 +1597,7 @@ "dist": { "type": "path", "url": "../../packages/sync", - "reference": "2965d36db9a224b6e142e46c92358b353eca463a" + "reference": "e8ba4ea2e343876391215025258d0454d88bdddc" }, "require": { "automattic/jetpack-connection": "@dev", @@ -1630,7 +1630,7 @@ "link-template": "https://github.com/Automattic/jetpack-sync/compare/v${old}...v${new}" }, "branch-alias": { - "dev-trunk": "3.4.x-dev" + "dev-trunk": "3.5.x-dev" }, "dependencies": { "test-only": [ diff --git a/projects/plugins/videopress/changelog/update-sync-hpos-checksum-fields-to-consider b/projects/plugins/videopress/changelog/update-sync-hpos-checksum-fields-to-consider new file mode 100644 index 0000000000000..9aa70e3ec1f75 --- /dev/null +++ b/projects/plugins/videopress/changelog/update-sync-hpos-checksum-fields-to-consider @@ -0,0 +1,5 @@ +Significance: patch +Type: changed +Comment: Updated composer.lock. + + diff --git a/projects/plugins/videopress/composer.lock b/projects/plugins/videopress/composer.lock index f0093eba9c199..ee9a3c93634ad 100644 --- a/projects/plugins/videopress/composer.lock +++ b/projects/plugins/videopress/composer.lock @@ -1597,7 +1597,7 @@ "dist": { "type": "path", "url": "../../packages/sync", - "reference": "2965d36db9a224b6e142e46c92358b353eca463a" + "reference": "e8ba4ea2e343876391215025258d0454d88bdddc" }, "require": { "automattic/jetpack-connection": "@dev", @@ -1630,7 +1630,7 @@ "link-template": "https://github.com/Automattic/jetpack-sync/compare/v${old}...v${new}" }, "branch-alias": { - "dev-trunk": "3.4.x-dev" + "dev-trunk": "3.5.x-dev" }, "dependencies": { "test-only": [ diff --git a/projects/plugins/wpcomsh/changelog/update-sync-hpos-checksum-fields-to-consider b/projects/plugins/wpcomsh/changelog/update-sync-hpos-checksum-fields-to-consider new file mode 100644 index 0000000000000..9aa70e3ec1f75 --- /dev/null +++ b/projects/plugins/wpcomsh/changelog/update-sync-hpos-checksum-fields-to-consider @@ -0,0 +1,5 @@ +Significance: patch +Type: changed +Comment: Updated composer.lock. + + diff --git a/projects/plugins/wpcomsh/composer.lock b/projects/plugins/wpcomsh/composer.lock index 134bab13315fc..b3d4c9ec61d52 100644 --- a/projects/plugins/wpcomsh/composer.lock +++ b/projects/plugins/wpcomsh/composer.lock @@ -1705,7 +1705,7 @@ "dist": { "type": "path", "url": "../../packages/sync", - "reference": "2965d36db9a224b6e142e46c92358b353eca463a" + "reference": "e8ba4ea2e343876391215025258d0454d88bdddc" }, "require": { "automattic/jetpack-connection": "@dev", @@ -1738,7 +1738,7 @@ "link-template": "https://github.com/Automattic/jetpack-sync/compare/v${old}...v${new}" }, "branch-alias": { - "dev-trunk": "3.4.x-dev" + "dev-trunk": "3.5.x-dev" }, "dependencies": { "test-only": [