terpal-sql icon indicating copy to clipboard operation
terpal-sql copied to clipboard

What is the need for the sqlite-jdbc dependency?

Open cies opened this issue 6 months ago • 0 comments

I found that terpal-sql has a dependency on sqlite-jdbc. Since I do not use sqlite, I excluded it:

  api("io.exoquery:terpal-sql-jdbc:$terpalSqlVersion") {
    exclude(group = "org.xerial", module = "sqlite-jdbc")
  }

My whole app stack is 11MB after excluding this dependency, which clocked in at a whopping 13MB.

So I wondered: is there a reason this is a dependency and do I do something stoopid by excluding it? Or should it not be a terpal-sql dependency at all?

I've searched this repository for the "xerial" and only found the dependency in 2 places where, both as test dependencies... So I'm not sure why it is a transient dependency of my project.

Here an excerpt of the output of ./gradlew -q dependencies --configuration runtimeClasspath without excluding sqlite-jdbc:

...
|         +--- org.jetbrains.kotlin:kotlin-stdlib:2.1.20 (*)
|         \--- org.jetbrains.kotlinx:kotlinx-serialization-core:1.8.1 (*)
+--- io.exoquery:terpal-sql-jdbc:2.0.0.PL-1.2.0
|    \--- io.exoquery:terpal-sql-jdbc-jvm:2.0.0.PL-1.2.0
|         +--- io.exoquery:terpal-runtime:2.1.0-2.0.0.PL -> 2.1.20-2.0.0.PL
|         |    \--- io.exoquery:terpal-runtime-jvm:2.1.20-2.0.0.PL
|         |         \--- org.jetbrains.kotlin:kotlin-stdlib:2.1.20 (*)
|         +--- io.exoquery:terpal-sql-core:2.0.0.PL-1.2.0
|         |    \--- io.exoquery:terpal-sql-core-jvm:2.0.0.PL-1.2.0
|         |         +--- io.exoquery:terpal-runtime:2.1.0-2.0.0.PL -> 2.1.20-2.0.0.PL (*)
|         |         +--- org.jetbrains.kotlinx:kotlinx-serialization-core:1.6.2 -> 1.8.1 (*)
|         |         +--- org.jetbrains.kotlinx:kotlinx-serialization-json:1.6.2 -> 1.8.1 (*)
|         |         +--- org.jetbrains.kotlinx:kotlinx-coroutines-core:1.8.1
|         |         |    \--- org.jetbrains.kotlinx:kotlinx-coroutines-core-jvm:1.8.1
|         |         |         +--- org.jetbrains:annotations:23.0.0 -> 24.1.0
|         |         |         +--- org.jetbrains.kotlinx:kotlinx-coroutines-bom:1.8.1
|         |         |         |    +--- org.jetbrains.kotlinx:kotlinx-coroutines-core-jvm:1.8.1 (c)
|         |         |         |    \--- org.jetbrains.kotlinx:kotlinx-coroutines-core:1.8.1 (c)
|         |         |         \--- org.jetbrains.kotlin:kotlin-stdlib:1.9.21 -> 2.1.20 (*)
|         |         +--- org.jetbrains.kotlinx:kotlinx-datetime:0.6.0
|         |         |    \--- org.jetbrains.kotlinx:kotlinx-datetime-jvm:0.6.0
|         |         |         \--- org.jetbrains.kotlin:kotlin-stdlib:1.9.21 -> 2.1.20 (*)
|         |         +--- org.jetbrains.kotlin:kotlin-stdlib:2.1.0 -> 2.1.20 (*)
|         |         \--- org.jetbrains.kotlinx:atomicfu:0.23.1
|         |              \--- org.jetbrains.kotlinx:atomicfu-jvm:0.23.1
|         |                   +--- org.jetbrains.kotlin:kotlin-stdlib:1.9.21 -> 2.1.20 (*)
|         |                   \--- org.jetbrains.kotlin:kotlin-stdlib-common:1.9.21 -> 2.1.20
|         |                        \--- org.jetbrains.kotlin:kotlin-stdlib:2.1.20 (*)
|         +--- org.jetbrains.kotlinx:kotlinx-serialization-core:1.6.2 -> 1.8.1 (*)
|         +--- org.jetbrains.kotlinx:kotlinx-serialization-json:1.6.2 -> 1.8.1 (*)
|         +--- org.jetbrains.kotlinx:kotlinx-coroutines-core:1.8.1 (*)
|         +--- org.jetbrains.kotlin:kotlin-stdlib:2.1.0 -> 2.1.20 (*)
|         +--- com.zaxxer:HikariCP:5.0.1 -> 5.1.0
|         |    \--- org.slf4j:slf4j-api:1.7.36 -> 2.0.17
|         +--- com.typesafe:config:1.4.1
|         +--- org.xerial:sqlite-jdbc:3.42.0.1     // <-- here it is!
|         \--- org.jetbrains:annotations:24.1.0
+--- io.exoquery:terpal-runtime:2.1.20-2.0.0.PL (*)
+--- org.jetbrains.kotlin:kotlin-stdlib:2.1.20 (*)
+--- org.http4k:http4k-bom:6.9.2.0
...

cies avatar Jun 24 '25 07:06 cies