Skip to content

Commit fe6ce41

Browse files
marc0derclaude
andcommitted
Revert commits from 9b0d0b5 to 5c6dcdd
This reverts all commits related to flyway migrations and compilation fixes. Co-Authored-By: Claude <noreply@anthropic.com>
1 parent 5c6dcdd commit fe6ce41

8 files changed

Lines changed: 0 additions & 136 deletions

File tree

build.gradle.kts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,8 +69,6 @@ dependencies {
6969
implementation("com.zaxxer:HikariCP:5.1.0")
7070
implementation("com.typesafe:config:1.4.3")
7171
implementation("ch.qos.logback:logback-classic:1.4.14")
72-
implementation("org.flywaydb:flyway-core:11.10.2")
73-
implementation("org.flywaydb:flyway-database-postgresql:11.10.2")
7472

7573
// Testing
7674
testImplementation("io.kotest:kotest-runner-junit5:$kotestVersion")

prompts/08-flyway_db_migrations-oneshot.md

Lines changed: 0 additions & 75 deletions
This file was deleted.

prompts/08-flyway_db_migrations-todo.md

Lines changed: 0 additions & 22 deletions
This file was deleted.

src/main/kotlin/io/sdkman/broker/App.kt

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ import io.sdkman.broker.application.service.VersionServiceImpl
2222
import io.sdkman.broker.config.DefaultAppConfig
2323
import kotlinx.serialization.ExperimentalSerializationApi
2424
import kotlinx.serialization.json.Json
25-
import org.flywaydb.core.Flyway
2625

2726
object App {
2827
@JvmStatic
@@ -37,16 +36,6 @@ object App {
3736
val postgresConnectivity = PostgresConnectivity(config)
3837
val postgresDataSource = postgresConnectivity.dataSource()
3938

40-
// Run Flyway migrations
41-
val flyway =
42-
Flyway.configure()
43-
.dataSource(config.flywayUrl, config.flywayUsername, config.flywayPassword)
44-
.locations("classpath:db/migration")
45-
.baselineOnMigrate(true)
46-
.validateOnMigrate(true)
47-
.load()
48-
flyway.migrate()
49-
5039
// Initialize repositories
5140
val applicationRepository = MongoApplicationRepository(database)
5241
val versionRepository = MongoVersionRepository(database)

src/main/kotlin/io/sdkman/broker/config/AppConfig.kt

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
package io.sdkman.broker.config
22

33
import arrow.core.Option
4-
import arrow.core.getOrElse
54
import com.typesafe.config.Config
65
import com.typesafe.config.ConfigFactory
76

@@ -18,9 +17,6 @@ interface AppConfig {
1817
val postgresPassword: Option<String>
1918
val serverPort: Int
2019
val serverHost: String
21-
val flywayUrl: String
22-
val flywayUsername: String
23-
val flywayPassword: String
2420
}
2521

2622
class DefaultAppConfig : AppConfig {
@@ -43,9 +39,4 @@ class DefaultAppConfig : AppConfig {
4339
// Server settings
4440
override val serverPort: Int = config.getIntOrDefault("server.port", 8080)
4541
override val serverHost: String = config.getStringOrDefault("server.host", "127.0.0.1")
46-
47-
// Flyway settings - use postgres credentials
48-
override val flywayUrl: String = "jdbc:postgresql://$postgresHost:$postgresPort/$postgresDatabase"
49-
override val flywayUsername: String = postgresUsername.getOrElse { "postgres" }
50-
override val flywayPassword: String = postgresPassword.getOrElse { "postgres" }
5142
}

src/main/resources/db/migration/V1__Initial_audit_table.sql

Lines changed: 0 additions & 11 deletions
This file was deleted.

src/test/kotlin/io/sdkman/broker/adapter/secondary/persistence/MongoConnectivityIntegrationSpec.kt

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,6 @@ class MongoConnectivityIntegrationSpec : ShouldSpec({
2929
override val postgresPassword: Option<String> = None
3030
override val serverPort: Int = 8080
3131
override val serverHost: String = "127.0.0.1"
32-
override val flywayUrl: String = "jdbc:postgresql://$postgresHost:$postgresDatabase"
33-
override val flywayUsername: String = "postgres"
34-
override val flywayPassword: String = "postgres"
3532
}
3633
val connectivity = MongoConnectivity(config)
3734

src/test/kotlin/io/sdkman/broker/adapter/secondary/persistence/PostgresConnectivityIntegrationSpec.kt

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,6 @@ class PostgresConnectivityIntegrationSpec : ShouldSpec({
3030
override val postgresPassword: Option<String> = PostgresTestListener.password.some()
3131
override val serverPort: Int = 8080
3232
override val serverHost: String = "127.0.0.1"
33-
override val flywayUrl: String = "jdbc:postgresql://$postgresHost:$postgresDatabase"
34-
override val flywayUsername: String = "postgres"
35-
override val flywayPassword: String = "postgres"
3633
}
3734
val connectivity = PostgresConnectivity(config)
3835

0 commit comments

Comments
 (0)