-
Notifications
You must be signed in to change notification settings - Fork 24
Migration Guide
Mirge-SQL was moved to a new GitHub Organisation https://github.com/mirage-sql , so the artifacts were renamed from:
<dependency>
<groupId>jp.sf.amateras</groupId>
<artifactId>mirage</artifactId>
<version>1.2.5</version>
</dependency>
and
compile 'jp.sf.amateras:mirage:1.2.5'
to:
<dependency>
<groupId>com.miragesql</groupId>
<artifactId>miragesql</artifactId>
<version>1.3.0</version>
</dependency>
and
compile 'com.miragesql:miragesql:1.3.0'
Mirage-SQL sources were refactored to use the new Github Organization package name, so you have to change all you imports from:
import jp.sf.amateras.mirage.*;
to
import com.miragesql.miragesql.*;
Mirage-SQL was refactored to use https://www.slf4j.org/ instead of java.util.logging
(JUL) . If your application is using JUL, you could migrate it to SLF4J as described https://www.slf4j.org/migrator.html
Note the logging levels between JUL and SLF4j:
FINEST -> TRACE
FINER -> DEBUG
FINE -> DEBUG
CONFIG -> INFO
INFO -> INFO
WARNING -> WARN
SEVERE -> ERROR
Mirage-SQL now supports HikariCP. If you were using DBCP, please update your code to use HikariCP. Mirage-SQL has support for all HikariCP configuration properties: https://github.com/brettwooldridge/HikariCP#configuration-knobs-baby .
Deprecated code from Mirage-SQL =<1.2.5 was removed in 2.0.0 .
Methods having an sqlPath
(a String
representhing the path of an sql file) or an SQL itself, were deprecated and replaced with ones using SqlResource
.
method(String sqlPath, ...) -> method(SqlResource resource, ...)
==> method(new ClasspathSqlResource(sqlPath))
method(String sql, ...) -> method(SqlResource resource, ...)
==> use new StringSqlResource(sql)
The following utilities:
com/miragesql/miragesql/util/Base64Util.java
com/miragesql/miragesql/util/ArrayMap.java
miragesql/miragesql/util/CaseInsensitiveMap.java
were removed, since Mirage-SQL wasn't using them anymore. If you were using those utilities, please use Apache Commons libraries, since there is the up to date implementation of them.
Mirage-SQL monolitic JAR was split into several smaller JARs:
-
Mirage-SQL -
miragesql-2.1.0.jar
- the core functionality -
Mirage-SQL Test -
miragesql-test-2.1.0.jar
- the testing functionality -
Mirage-SQL Tools -
miragesql-tools-2.1.0.jar
- the tooling -
Mirage-SQL Integration -
miragesql-integration-2.1.0.jar
- the integration with Spring, Guice and Seasar2
Depending on your use case, the only migration needed is to also include JAR #2, #3 or #4 in your build system.
Package com.miragesql.miragesql.tool
was refactored to com.miragesql.miragesql.tools
for naming consistency.
Several new features from the community wishlist Take the following steps to to migrate your application:
- tbd