0
この質問は、このQuestionと同じエラーメッセージに関連しています。しかし私はそこに与えられた答えを使って私の問題を解決することができました。HsqlException:クライアントのバージョン
Imを使用してHSQLサーバをローカルに開始します。
java-cp lib/hsqldb.jar org.hsqldb.server.Server --database.0 file:MasterListMain --bname.0 MasterListMain
私は私が手にサーバーに接続する場合:
[[email protected]]: [Thread[main,5,main]]: checkRunning(false) entered
[[email protected]]: [Thread[main,5,main]]: checkRunning(false) exited
[[email protected]]: Startup sequence initiated from main() method
[[email protected]]: Could not load properties from file
[[email protected]]: Using cli/default properties only
[[email protected]]: Initiating startup sequence...
[[email protected]]: Server socket opened successfully in 0 ms.
[[email protected]]: Database [index=0, id=0, db=file:MasterListMain, alias=mastelistmain] opened successfully in 391 ms.
[[email protected]]: Startup sequence completed in 391 ms.
[[email protected]]: 2016-08-30 18:55:54.144 HSQLDB server 2.3.4 is online on por 9001
[[email protected]]: To close normally, connect and execute SHUTDOWN SQL
[[email protected]]: From command line, use [Ctrl]+[C] to abort abruptly
org.hsqldb.HsqlException: Client driver version greater than '2.1.0.0' is requied. HSQLDB server version is '2.3.4'
at org.hsqldb.error.Error.error(Unknown Source)
at org.hsqldb.server.ServerConnection.init(Unknown Source)
at org.hsqldb.server.ServerConnection.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
org.hsqldb.HsqlException: Client driver version greater than '2.1.0.0' is requied. HSQLDB server version is '2.3.4'
at org.hsqldb.error.Error.error(Unknown Source)
at org.hsqldb.server.ServerConnection.init(Unknown Source)
at org.hsqldb.server.ServerConnection.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
これは私がまた私のクライアントは、バージョン2.3.4を使用していることを期待していたことから、予想外です。
apply plugin: 'eclipse'
apply plugin: 'application'
import groovy.sql.Sql
repositories {
mavenCentral()
}
mainClassName = "gui.MasterListMain"
configurations {
mail
junit
jdbc
sqllite
}
dependencies {
compile group: 'junit', name: 'junit', version: '4+'
// compile group: 'org.xerial', name: 'sqlite-jdbc', version: '3.8.11.2'
// hsqldb
compile 'org.hsqldb:hsqldb:2.3.4'
// JAR
compile 'org.hibernate.javax.persistence:hibernate-jpa-2.1-api:1.0.0.Final'
// Hibernate
compile 'org.hibernate:hibernate-entitymanager:4.3.10.Final'
compile 'org.apache.commons:commons-lang3:3.3.2'
compile 'commons-io:commons-io:2.4'
compile 'org.apache.commons:commons-collections4:4.0'
compile group: 'org.apache.logging.log4j', name: 'log4j-api', version: '2.0.2'
compile group: 'org.apache.logging.log4j', name: 'log4j-core', version: '2.0.2'
compile 'com.google.guava:guava:18.0'
compile 'commons-lang:commons-lang:2.6'
compile 'log4j:log4j:1.2.14'
compile group: 'org.slf4j', name: 'slf4j-api', version: '1.6.0'
compile group: 'org.slf4j', name: 'slf4j-log4j12', version: '1.6.0'
compile group: 'com.googlecode.log4jdbc', name: 'log4jdbc', version: '1.2'
}
もgradle dependencies
は私が見つける私のクライアント側のログで
default - Configuration for default artifacts.
+--- junit:junit:4+ -> 4.12
| \--- org.hamcrest:hamcrest-core:1.3
+--- org.hsqldb:hsqldb:2.3.4
+--- org.hibernate.javax.persistence:hibernate-jpa-2.1-api:1.0.0.Final
+--- org.hibernate:hibernate-entitymanager:4.3.10.Final
| +--- org.jboss.logging:jboss-logging:3.1.3.GA
| +--- org.jboss.logging:jboss-logging-annotations:1.2.0.Beta1
| +--- org.hibernate:hibernate-core:4.3.10.Final
| | +--- org.jboss.logging:jboss-logging:3.1.3.GA
| | +--- org.jboss.logging:jboss-logging-annotations:1.2.0.Beta1
| | +--- org.jboss.spec.javax.transaction:jboss-transaction-api_1.2_spec:1.0.0.Final
| | +--- dom4j:dom4j:1.6.1
| | | \--- xml-apis:xml-apis:1.0.b2
| | +--- org.hibernate.common:hibernate-commons-annotations:4.0.5.Final
| | | +--- org.jboss.logging:jboss-logging:3.1.3.GA
| | | \--- org.jboss.logging:jboss-logging-annotations:1.2.0.Beta1
| | +--- org.hibernate.javax.persistence:hibernate-jpa-2.1-api:1.0.0.Final
| | +--- org.javassist:javassist:3.18.1-GA
| | +--- antlr:antlr:2.7.7
| | \--- org.jboss:jandex:1.1.0.Final
| +--- dom4j:dom4j:1.6.1 (*)
| +--- org.hibernate.common:hibernate-commons-annotations:4.0.5.Final (*)
| +--- org.hibernate.javax.persistence:hibernate-jpa-2.1-api:1.0.0.Final
| +--- org.jboss.spec.javax.transaction:jboss-transaction-api_1.2_spec:1.0.0.Final
| \--- org.javassist:javassist:3.18.1-GA
+--- org.apache.commons:commons-lang3:3.3.2
+--- commons-io:commons-io:2.4
+--- org.apache.commons:commons-collections4:4.0
+--- org.apache.logging.log4j:log4j-api:2.0.2
+--- org.apache.logging.log4j:log4j-core:2.0.2
| \--- org.apache.logging.log4j:log4j-api:2.0.2
+--- com.google.guava:guava:18.0
+--- commons-lang:commons-lang:2.6
+--- log4j:log4j:1.2.14
+--- org.slf4j:slf4j-api:1.6.0
+--- org.slf4j:slf4j-log4j12:1.6.0
| +--- org.slf4j:slf4j-api:1.6.0
| \--- log4j:log4j:1.2.14
\--- com.googlecode.log4jdbc:log4jdbc:1.2
\--- org.slf4j:slf4j-api:1.6.0
OKのように見える:
WARN 2016-08-30 19:24:02,314 501 org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl [main] HHH000402: Using Hibernate built-in connection pool (not for production use!)
INFO 2016-08-30 19:24:02,314 501 org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl [main] HHH000401: using driver [org.hsqldb.jdbcDriver] at URL [jdbc:hsqldb:hsql://localhost/MasterListMain]
INFO 2016-08-30 19:24:02,314 501 org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl [main] HHH000046: Connection properties: {user=SA}
INFO 2016-08-30 19:24:02,314 501 org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl [main] HHH000006: Autocommit mode: false
INFO 2016-08-30 19:24:02,314 501 org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl [main] HHH000115: Hibernate connection pool size: 20 (min=1)
DEBUG 2016-08-30 19:24:02,314 501 org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl [main] Initializing Connection pool with 1 Connections
DEBUG 2016-08-30 19:24:03,439 1626 org.hibernate.jpa.HibernatePersistenceProvider [main] Unable to build entity manager factory
org.hibernate.exception.JDBCConnectionException: Error calling Driver#connect
at org.hibernate.exception.internal.SQLStateConversionDelegate.convert(SQLStateConversionDelegate.java:132)
at
[...]
Caused by: java.sql.SQLTransientConnectionException: java.net.ConnectException: Connection refused: connect
at org.hsqldb.jdbc.JDBCUtil.sqlException(Unknown Source)
at org.hsqldb.jdbc.JDBCUtil.sqlException(Unknown Source)
at org.hsqldb.jdbc.JDBCConnection.<init>(Unknown Source)
at org.hsqldb.jdbc.JDBCDriver.getConnection(Unknown Source)
at org.hsqldb.jdbc.JDBCDriver.connect(Unknown Source)
にする任意のアイデア、
gradle.build
はとして読み込みます正しいバージョンを定義しますか?
ありがとう、BerndGit