[CDO][4.6] Request with lower cased Table Name gives an error [message #1777337] |
Tue, 28 November 2017 15:42 |
Mickael GAUVIN Messages: 39 Registered: July 2009 |
Member |
|
|
Hello,
From a new schema empty of any tables and with a MySQL database which is case sensisitive for table names on linux, we have this error at cdo-server start up :
[user@host~]$ [ERROR] Rollback in DBStore: org.eclipse.net4j.db.DBException: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Table 'myschema.cdo_commit_infos' doesn't exist
at org.eclipse.emf.cdo.server.internal.db.CommitInfoTable.writeCommitInfo(CommitInfoTable.java:112)
at org.eclipse.emf.cdo.server.internal.db.DBStoreAccessor.writeCommitInfo(DBStoreAccessor.java:525)
at org.eclipse.emf.cdo.spi.server.StoreAccessor.doWrite(StoreAccessor.java:84)
at org.eclipse.emf.cdo.server.internal.db.DBStoreAccessor.doWrite(DBStoreAccessor.java:888)
at org.eclipse.emf.cdo.spi.server.StoreAccessorBase.write(StoreAccessorBase.java:138)
at org.eclipse.emf.cdo.internal.server.TransactionCommitContext.writeAccessor(TransactionCommitContext.java:1612)
at org.eclipse.emf.cdo.internal.server.TransactionCommitContext.write(TransactionCommitContext.java:737)
at org.eclipse.emf.cdo.internal.server.Repository.initRootResource(Repository.java:2247)
at org.eclipse.emf.cdo.internal.server.Repository.doActivate(Repository.java:2451)
at org.eclipse.net4j.util.lifecycle.Lifecycle.internalActivate(Lifecycle.java:76)
at org.eclipse.net4j.util.lifecycle.ShareableLifecycle.internalActivate(ShareableLifecycle.java:43)
at org.eclipse.net4j.util.lifecycle.Lifecycle.activate(Lifecycle.java:162)
at org.eclipse.net4j.util.lifecycle.LifecycleUtil.activate(LifecycleUtil.java:127)
at org.eclipse.net4j.util.lifecycle.LifecycleUtil.activate(LifecycleUtil.java:117)
at org.eclipse.emf.cdo.server.CDOServerUtil.addRepository(CDOServerUtil.java:295)
at org.eclipse.emf.cdo.spi.server.RepositoryConfigurator.configure(RepositoryConfigurator.java:138)
at org.eclipse.emf.cdo.spi.server.RepositoryConfigurator.configure(RepositoryConfigurator.java:107)
at org.eclipse.emf.cdo.internal.server.bundle.CDOServerApplication.doStart(CDOServerApplication.java:61)
at org.eclipse.net4j.util.om.OSGiApplication.start(OSGiApplication.java:63)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
at org.eclipse.equinox.internal.app.AnyThreadAppLauncher.run(AnyThreadAppLauncher.java:26)
at java.lang.Thread.run(Thread.java:745)
Caused by: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Table 'myschema.cdo_commit_infos' doesn't exist
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:422)
at com.mysql.jdbc.Util.handleNewInstance(Util.java:425)
at com.mysql.jdbc.Util.getInstance(Util.java:408)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:943)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3973)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3909)
at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:2527)
at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2680)
at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2487)
at com.mysql.jdbc.PreparedStatement.executeInternal(PreparedStatement.java:1858)
at com.mysql.jdbc.PreparedStatement.executeUpdateInternal(PreparedStatement.java:2079)
at com.mysql.jdbc.PreparedStatement.executeUpdateInternal(PreparedStatement.java:2013)
at com.mysql.jdbc.PreparedStatement.executeLargeUpdate(PreparedStatement.java:5104)
at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1998)
at org.eclipse.net4j.db.jdbc.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:81)
at org.eclipse.net4j.db.DBUtil.update(DBUtil.java:966)
at org.eclipse.emf.cdo.server.internal.db.CommitInfoTable.writeCommitInfo(CommitInfoTable.java:108)
... 21 more
Note that table name is in lower case. But the table is created in UPPER CASE.
I think there is a problem in org.eclipse.emf.cdo.server.internal.db.CommitInfoTable#loadCommitInfos(L149) which uses the constant COMMIT_INFOS which is in lower case .
org.eclipse.emf.cdo.server.internal.db.CommitInfoTable (L52)
private static final String COMMIT_INFOS = "cdo_commit_infos"; //$NON-NLS-1$
This is not the case for usually used DBNamedElement that transforms all provided names in UPPER CASE.
Am I Right ?
Best regards.
Mickaël.
[Updated on: Wed, 29 November 2017 07:46] Report message to a moderator
|
|
|
Powered by
FUDForum. Page generated in 0.03290 seconds