From ae27661a10b8330db5e24476da4637e9f93b7505 Mon Sep 17 00:00:00 2001 From: SamB440 Date: Sat, 1 Feb 2025 17:26:27 +0000 Subject: [PATCH] Database migration fix --- rpgregions/build.gradle.kts | 4 ++-- rpgregions/src/main/resources/config.yml | 2 +- .../db/migration/V4__Create_TimedDiscoveries_Table.sql | 2 +- rpgregions/src/main/resources/plugin.yml | 4 ++-- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/rpgregions/build.gradle.kts b/rpgregions/build.gradle.kts index c259239..5f4bc68 100644 --- a/rpgregions/build.gradle.kts +++ b/rpgregions/build.gradle.kts @@ -53,8 +53,8 @@ dependencies { exclude("org.bukkit") exclude("org.spigotmc") } - compileOnly("org.flywaydb:flyway-core:11.1.0") // IMPLEMENTED VIA LIBRARIES - db migration - compileOnly("org.flywaydb:flyway-mysql:11.1.0") // IMPLEMENTED VIA LIBRARIES + compileOnly("org.flywaydb:flyway-core:11.3.0") // IMPLEMENTED VIA LIBRARIES - db migration + compileOnly("org.flywaydb:flyway-mysql:11.3.0") // IMPLEMENTED VIA LIBRARIES //compileOnly 'com.zaxxer:HikariCP:2.4.1' // IMPLEMENTED VIA LIBRARIES - database compileOnly("me.clip:placeholderapi:2.11.6") // PAPI compileOnly("com.github.MilkBowl:VaultAPI:1.7") { // vault diff --git a/rpgregions/src/main/resources/config.yml b/rpgregions/src/main/resources/config.yml index 60626d3..458e355 100644 --- a/rpgregions/src/main/resources/config.yml +++ b/rpgregions/src/main/resources/config.yml @@ -31,7 +31,7 @@ settings: permission-based-cost: true storage: cache-expiry-time: 180 # Time in seconds after a cached account is considered invalid and must be saved - mode: file # Storage mode to use: sqlite, file, mysql. If you are dealing with lots of players, please use a mysql database. + mode: file # Storage mode to use: sqlite, file, sql. If you are dealing with lots of players, please use a mysql database. sql: # SQL settings host: localhost # If you are in a docker container, please use the docker IP. Should be something like 172.18.0.1 for pterodactyl users. port: 3306 diff --git a/rpgregions/src/main/resources/db/migration/V4__Create_TimedDiscoveries_Table.sql b/rpgregions/src/main/resources/db/migration/V4__Create_TimedDiscoveries_Table.sql index e241c8f..5c63cc4 100644 --- a/rpgregions/src/main/resources/db/migration/V4__Create_TimedDiscoveries_Table.sql +++ b/rpgregions/src/main/resources/db/migration/V4__Create_TimedDiscoveries_Table.sql @@ -1 +1 @@ -CREATE TABLE IF NOT EXISTS rpgregions_timed_discoveries (uuid varchar(32) NOT NULL, region varchar(32) NOT NULL, start bigint(9223372036854775807) NOT NULL, latest bigint(9223372036854775807), PRIMARY KEY(uuid, region)); +CREATE TABLE IF NOT EXISTS rpgregions_timed_discoveries (uuid varchar(32) NOT NULL, region varchar(32) NOT NULL, start bigint NOT NULL, latest bigint, PRIMARY KEY(uuid, region)); diff --git a/rpgregions/src/main/resources/plugin.yml b/rpgregions/src/main/resources/plugin.yml index f950cbc..7940018 100644 --- a/rpgregions/src/main/resources/plugin.yml +++ b/rpgregions/src/main/resources/plugin.yml @@ -8,8 +8,8 @@ libraries: - "net.kyori:adventure-text-minimessage:4.14.0" - "com.github.ben-manes.caffeine:caffeine:3.1.8" - "org.xerial:sqlite-jdbc:3.47.2.0" - - "org.flywaydb:flyway-core:11.1.0" # db migration - - "org.flywaydb:flyway-mysql:11.1.0" + - "org.flywaydb:flyway-core:11.3.0" # db migration + - "org.flywaydb:flyway-mysql:11.3.0" softdepend: [Hyperverse, Multiverse-Core, UltraRegions, WorldGuard, PlaceholderAPI, HeadDatabase, Residence, Plan, GriefPrevention, GriefDefender, Vault, MythicMobs, AlonsoLevels, dynmap, ProtocolLib, Quests, BetonQuest, Lands, MMOCore, CustomStructures] authors: [SamB440] description: Utilise your protection plugin to create discoverable regions