You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ignite.apache.org by "Roman Shtykh (JIRA)" <ji...@apache.org> on 2017/06/28 10:37:00 UTC
[jira] [Commented] (IGNITE-5601) WriteBehind mode hide
SQLExceptions
[ https://issues.apache.org/jira/browse/IGNITE-5601?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16066313#comment-16066313 ]
Roman Shtykh commented on IGNITE-5601:
--------------------------------------
Running your tests I get
{noformat}
重大: Unable to update underlying store: CacheJdbcPojoStore []
javax.cache.integration.CacheWriterException: Failed to write entries in database
at org.apache.ignite.cache.store.jdbc.CacheAbstractJdbcStore.writeAll(CacheAbstractJdbcStore.java:1151)
at org.apache.ignite.internal.processors.cache.store.GridCacheWriteBehindStore.updateStore(GridCacheWriteBehindStore.java:804)
at org.apache.ignite.internal.processors.cache.store.GridCacheWriteBehindStore.applyBatch(GridCacheWriteBehindStore.java:720)
at org.apache.ignite.internal.processors.cache.store.GridCacheWriteBehindStore.access$2400(GridCacheWriteBehindStore.java:75)
at org.apache.ignite.internal.processors.cache.store.GridCacheWriteBehindStore$Flusher.flushCacheCoalescing(GridCacheWriteBehindStore.java:1135)
at org.apache.ignite.internal.processors.cache.store.GridCacheWriteBehindStore$Flusher.body(GridCacheWriteBehindStore.java:1006)
at org.apache.ignite.internal.util.worker.GridWorker.run(GridWorker.java:110)
at java.lang.Thread.run(Thread.java:748)
Caused by: java.sql.SQLSyntaxErrorException: 'UNEXISTING_COLUMN' is not a column in table or VTI 'DERBY.FOO'.
at org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(Unknown Source)
at org.apache.derby.impl.jdbc.Util.generateCsSQLException(Unknown Source)
at org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(Unknown Source)
at org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(Unknown Source)
at org.apache.derby.impl.jdbc.EmbedConnection.handleException(Unknown Source)
at org.apache.derby.impl.jdbc.ConnectionChild.handleException(Unknown Source)
at org.apache.derby.impl.jdbc.EmbedPreparedStatement.<init>(Unknown Source)
at org.apache.derby.impl.jdbc.EmbedPreparedStatement42.<init>(Unknown Source)
at org.apache.derby.jdbc.Driver42.newEmbedPreparedStatement(Unknown Source)
at org.apache.derby.impl.jdbc.EmbedConnection.prepareStatement(Unknown Source)
at org.apache.derby.impl.jdbc.EmbedConnection.prepareStatement(Unknown Source)
at org.apache.ignite.cache.store.jdbc.CacheAbstractJdbcStore.writeAll(CacheAbstractJdbcStore.java:1131)
... 7 more
Caused by: ERROR 42X14: 'UNEXISTING_COLUMN' is not a column in table or VTI 'DERBY.FOO'.
at org.apache.derby.iapi.error.StandardException.newException(Unknown Source)
at org.apache.derby.iapi.error.StandardException.newException(Unknown Source)
at org.apache.derby.impl.sql.compile.ResultColumn.bindResultColumnByName(Unknown Source)
at org.apache.derby.impl.sql.compile.ResultColumnList.bindResultColumnsByName(Unknown Source)
at org.apache.derby.impl.sql.compile.InsertNode.bindStatement(Unknown Source)
at org.apache.derby.impl.sql.GenericStatement.prepMinion(Unknown Source)
at org.apache.derby.impl.sql.GenericStatement.prepare(Unknown Source)
at org.apache.derby.impl.sql.conn.GenericLanguageConnectionContext.prepareInternalStatement(Unknown Source)
... 13 more
6 28, 2017 7:34:32 午後 org.apache.ignite.logger.java.JavaLogger warning
警告: Failed to update store (value will be lost as current buffer size is greater than 'cacheCriticalSize' or node has been stopped before store was repaired) [key=test.WriteBehindIssueTest$FooKey [idHash=1079871273, hash=-1388553726, id=1], val=test.WriteBehindIssueTest$Foo [idHash=1996018097, hash=574522785, value1=abcd, value2=1234], op=PUT]
{noformat}
> WriteBehind mode hide SQLExceptions
> -----------------------------------
>
> Key: IGNITE-5601
> URL: https://issues.apache.org/jira/browse/IGNITE-5601
> Project: Ignite
> Issue Type: Improvement
> Components: jdbc
> Affects Versions: 2.0
> Environment: Ignite 2.0.0
> Oracle JDK 1.8.0_121
> Derby 10.13.1.1
> Reporter: Benjamin Garaude
>
> If an exception, e.g. SQLException occurs during a wite-behind operation, the exception is lost and appears nowhere in the logs.
> The logs basically say:
> [2017-06-28 10:48:52] SEVERE: Unable to update underlying store: CacheJdbcPojoStore []
> [2017-06-28 10:48:52] WARNING: Failed to update store (value will be lost as current buffer size is greater than 'cacheCriticalSize' or node has been stopped before store was repaired) [key=test.WriteBehindIssue$FooKey [idHash=524852907, hash=-1388553726, id=1], val=test.WriteBehindIssue$Foo [idHash=323347362, hash=574522785, value1=abcd, value2=1234], op=PUT]
> If we do the same with write-through mode, it fails by throwing an exception with the SQLException as cause, deep in the trace.
> Would it be possible the write-behind operation logs the SQLException, and other exception?
> You can find a test case showing that here: https://github.com/bgaraude/IgniteTest
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)