diff --git a/db/knex_init_db.js b/db/knex_init_db.js index f45fdda4..7ce1bb48 100644 --- a/db/knex_init_db.js +++ b/db/knex_init_db.js @@ -493,8 +493,11 @@ ALTER TABLE monitor await knex.schema.table("monitor", function (table) { table.string("kafka_producer_topic", 255); table.text("kafka_producer_brokers"); - table.integer("kafka_producer_ssl"); - table.string("kafka_producer_allow_auto_topic_creation", 255); + + // patch-fix-kafka-producer-booleans.sql + table.boolean("kafka_producer_ssl").defaultTo(0).notNullable(); + table.boolean("kafka_producer_allow_auto_topic_creation").defaultTo(0).notNullable(); + table.text("kafka_producer_sasl_options"); table.text("kafka_producer_message"); }); diff --git a/db/patch-fix-kafka-producer-booleans.sql b/db/old_migrations/patch-fix-kafka-producer-booleans.sql similarity index 100% rename from db/patch-fix-kafka-producer-booleans.sql rename to db/old_migrations/patch-fix-kafka-producer-booleans.sql diff --git a/server/database.js b/server/database.js index eb248ca5..0bcbedee 100644 --- a/server/database.js +++ b/server/database.js @@ -103,8 +103,8 @@ class Database { "patch-monitor-oauth-cc.sql": true, "patch-add-timeout-monitor.sql": true, "patch-add-gamedig-given-port.sql": true, - "patch-notification-config.sql": true, // The last file so far converted to a knex migration file - "patch-fix-kafka-producer-booleans.sql": true, + "patch-notification-config.sql": true, + "patch-fix-kafka-producer-booleans.sql": true, // The last file so far converted to a knex migration file }; /**