Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

h2 database adapter #5

Open
wants to merge 21 commits into
base: master
Choose a base branch
from
Open

h2 database adapter #5

wants to merge 21 commits into from

Conversation

jcai
Copy link

@jcai jcai commented Jun 9, 2015

h2 database adapter.

jcai and others added 21 commits June 9, 2015 14:20
Change-Id: If9b6dde6576c5b26d2e5a5044f4a28c6ee463af8
If sbt is upgraded to 0.13.0 then the build fails, so force sbt to use
version 0.12.4.

Change-Id: Iae450a5fcdb81a5ead54d3dca8aeb6f8c2d9d26f
Change-Id: Idb82fdc10e95013eb69d9bdfcacc3a40c104e6ab
Change-Id: I85ec919b58c582dd0c4e44ce5aa20c40b4cef636
Change-Id: I167a73e65944873f7a67318faa8eb8d3877293e5
Change-Id: I8e34044239995e81e109c8c490666ca53301b82b
The sbt-scalariform needed to be updated to 1.2.0 to build.

Change-Id: I554f04692194cd8a24295cb8f97fce0efe88b17d
The addition of this file makes it easier to read the github.com
project pages.

Change-Id: Ibb08e431fcbceae5b8692f6bc170c90369d9e159
Change-Id: I2d3b28d9b2b00d5721d840c6958d67529a7d616f
Compiling against Derby 10.11.1.1 generates this compile error:

[info] Compiling 23 Scala sources to /var/lib/jenkins/tomcat7/jenkins/jobs/scala-migrations-gerrit/workspace/target/scala-2.9.0/test-classes...
[error] /var/lib/jenkins/tomcat7/jenkins/jobs/scala-migrations-gerrit/workspace/src/test/scala/com/imageworks/migration/tests/TestDatabase.scala:169: type EmbedSQLException is not a member of package org.apache.derby.impl.jdbc
[error]     case _: org.apache.derby.impl.jdbc.EmbedSQLException =>
[error]                                        ^
[error] one error found

This appears to be due to the removal of EmbedSQLException in
10.11.1.1 [1].  Given that EmbedSQLException is only used in JDBC 3
version of the driver and JDBC 4 was released with JDK 1.6 which is
now a deprecated Java version, remove JDBC 3 support.

[1] https://issues.apache.org/jira/browse/DERBY-6488 .

Change-Id: I5cd6383a73d933e22718b998d7b914f6af31fecc
Change-Id: I3d0434b3c13c756a6c6dcfd2eb10ab26e14b1bcb
Change-Id: I0bfd06b42e2c83b30f655eb5f231e80e94f6f78f
Change-Id: I76987befc3e79b083f9d898e40dfd6731e555645
Change-Id: Ib161775bc1fb449866011acd8e760207896b7586
SLF4J 1.7.8 added JSR 305's @nonnull annotation to LoggerFactory [1]
and added an optional dependency on com.google.code.findbugs's jsr305
artifact version 2.0.1 [2], but optional dependencies are not used in
dependent projects [3], so add an explicit dependency on jsr305, but
use version 2.0.3, which is the latest in the 2.0.x series [4].

$ sbt +compile
[info] Loading project definition from project
[info] Set current project to scala-migrations (in build file:)
[info] Setting version to 2.9.0
[info] Reapplying settings...
[info] Set current project to scala-migrations (in build file:)
[info] Updating {file:}scala-migrations...
[info] Resolving org.fusesource.jansi#jansi;1.4 ...
[info] Done updating.
[info] Compiling 27 Scala sources to target/scala-2.9.0/classes...
[error] error while loading LoggerFactory, Missing dependency 'class javax.annotation.Nonnull', required by /home/blair/.ivy2/cache/org.slf4j/slf4j-api/jars/slf4j-api-1.7.8.jar(org/slf4j/LoggerFactory.class)
[error] src/main/scala/com/imageworks/migration/ColumnDefinition.scala:87: value getLogger is not a member of object org.slf4j.LoggerFactory
[error]   private final val logger = LoggerFactory.getLogger(this.getClass)
[error]                                            ^
[error] src/main/scala/com/imageworks/migration/DatabaseAdapter.scala:81: value getLogger is not a member of object org.slf4j.LoggerFactory
[error]   protected final val logger = LoggerFactory.getLogger(this.getClass)
[error]                                              ^
[error] src/main/scala/com/imageworks/migration/Migration.scala:69: value getLogger is not a member of object org.slf4j.LoggerFactory
[error]   private final val logger = LoggerFactory.getLogger(this.getClass)
[error]                                            ^
[error] src/main/scala/com/imageworks/migration/Migrator.scala:399: value getLogger is not a member of object org.slf4j.LoggerFactory
[error]   private final val logger = LoggerFactory.getLogger(this.getClass)
[error]                                            ^
[error] src/main/scala/com/imageworks/migration/With.scala:53: value getLogger is not a member of object org.slf4j.LoggerFactory
[error]   private final val logger = LoggerFactory.getLogger(this.getClass)
[error]                                            ^
[error] 6 errors found
[error] (compile:compile) Compilation failed

[1] http://www.slf4j.org/news.html
[2] http://repo1.maven.org/maven2/org/slf4j/slf4j-api/1.7.8/slf4j-api-1.7.8.pom
[3] http://maven.apache.org/guides/introduction/introduction-to-optional-and-excludes-dependencies.html
[4] http://mvnrepository.com/artifact/com.google.code.findbugs/jsr305

Change-Id: Ibe40bd4ab236745b17611cee1e7ed5dc394307cb
Change-Id: I6bafa02027903c6cd0ef953a25314a95763db1ae
Change-Id: Ia407c4133d0b6406353a8473d0544be9880ca861
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants