From ec3eb297f59996daff9015d475f8ff8a2db0ad7d Mon Sep 17 00:00:00 2001 From: Imri Paran Date: Tue, 27 Feb 2024 08:41:55 +0100 Subject: [PATCH] add migration for MongoDB supportsProfiler = true (#15254) * add migration for MongoDB supportsProfiler = true --- bootstrap/sql/migrations/native/1.4.0/mysql/schemaChanges.sql | 4 ++++ .../sql/migrations/native/1.4.0/postgres/schemaChanges.sql | 4 ++++ 2 files changed, 8 insertions(+) create mode 100644 bootstrap/sql/migrations/native/1.4.0/mysql/schemaChanges.sql create mode 100644 bootstrap/sql/migrations/native/1.4.0/postgres/schemaChanges.sql diff --git a/bootstrap/sql/migrations/native/1.4.0/mysql/schemaChanges.sql b/bootstrap/sql/migrations/native/1.4.0/mysql/schemaChanges.sql new file mode 100644 index 00000000000..06035180588 --- /dev/null +++ b/bootstrap/sql/migrations/native/1.4.0/mysql/schemaChanges.sql @@ -0,0 +1,4 @@ +-- Add the supportsProfiler field to the MongoDB connection configuration +UPDATE dbservice_entity +SET json = JSON_INSERT(json, '$.connection.config.supportsProfiler', TRUE) +WHERE serviceType = 'MongoDB'; \ No newline at end of file diff --git a/bootstrap/sql/migrations/native/1.4.0/postgres/schemaChanges.sql b/bootstrap/sql/migrations/native/1.4.0/postgres/schemaChanges.sql new file mode 100644 index 00000000000..c8b6830c129 --- /dev/null +++ b/bootstrap/sql/migrations/native/1.4.0/postgres/schemaChanges.sql @@ -0,0 +1,4 @@ +-- Add the supportsProfiler field to the MongoDB connection configuration +UPDATE dbservice_entity +SET json = jsonb_set(json::jsonb, '{connection,config,supportsProfiler}', 'true'::jsonb) +WHERE serviceType = 'MongoDB'; \ No newline at end of file