[jboss-jira] [JBoss JIRA] (WFLY-1709) NotSerializableException when using jdbc binary-keyed cache

Paul Ferraro (JIRA) jira-events at lists.jboss.org
Fri Aug 9 11:05:26 EDT 2013


     [ https://issues.jboss.org/browse/WFLY-1709?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Paul Ferraro closed WFLY-1709.
------------------------------

    Fix Version/s: No Release
       Resolution: Rejected


Aha!  This is just a matter of misconfiguration.  To use a cache container with web session clustering, you must set the module property appropriately.

e.g.

  <cache-container name="test" module="org.wildfly.clustering.web.infinispan">
     <!-- ... -->
  </cache-container>

                
> NotSerializableException when using jdbc binary-keyed cache
> -----------------------------------------------------------
>
>                 Key: WFLY-1709
>                 URL: https://issues.jboss.org/browse/WFLY-1709
>             Project: WildFly
>          Issue Type: Bug
>          Components: Clustering
>    Affects Versions: 8.0.0.Alpha2, 8.0.0.Alpha3
>            Reporter: Tomas Remes
>            Assignee: Paul Ferraro
>             Fix For: No Release
>
>         Attachments: jdbcStore.war
>
>
> Using following cache container configuration:
> {noformat}
>  <cache-container name="test" default-cache="jdbc">
>                 <transport lock-timeout="60000"/>
>                 <replicated-cache name="jdbc" mode="SYNC" batching="true">
>                     <binary-keyed-jdbc-store datasource="java:jboss/datasources/ExampleDS" preload="true" passivation="false" purge="false">
>                         <binary-keyed-table prefix="binarybased">
>                             <id-column name="id" type="VARCHAR(255)"/>
>                             <data-column name="datum" type="VARBINARY(10000)"/>
>                             <timestamp-column name="version" type="BIGINT"/>
>                         </binary-keyed-table>
>                     </binary-keyed-jdbc-store>
>                 </replicated-cache>
>             </cache-container>
> {noformat}
> and referencing it from jboss-web.xml is causing following exception and session is not stored.
> {noformat}
> 14:11:30,786 ERROR [org.infinispan.interceptors.InvocationContextInterceptor] (default task-1) ISPN000136: Execution error: org.infinispan.marshall.NotSerializableException: org.wildfly.clustering.web.infinispan.session.coarse.CoarseSessionCacheEntry
> Caused by: an exception which occurred:
> 	in object org.wildfly.clustering.web.infinispan.session.coarse.CoarseSessionCacheEntry at 39afa079
> 	in object org.infinispan.container.entries.ImmortalCacheEntry at d5bfdb7e
> 	in object org.infinispan.loaders.bucket.Bucket at 5c4400e6
> 14:11:30,786 ERROR [org.infinispan.transaction.TransactionCoordinator] (default task-1) ISPN000097: Error while processing a prepare in a single-phase transaction: org.infinispan.marshall.NotSerializableException: org.wildfly.clustering.web.infinispan.session.coarse.CoarseSessionCacheEntry
> Caused by: an exception which occurred:
> 	in object org.wildfly.clustering.web.infinispan.session.coarse.CoarseSessionCacheEntry at 39afa079
> 	in object org.infinispan.container.entries.ImmortalCacheEntry at d5bfdb7e
> 	in object org.infinispan.loaders.bucket.Bucket at 5c4400e6
> 14:11:30,788 ERROR [org.infinispan.transaction.tm.DummyTransaction] (default task-1) ISPN000111: afterCompletion() failed for SynchronizationAdapter{localTransaction=LocalTransaction{remoteLockedNodes=null, isMarkedForRollback=false, lockedKeys=null, backupKeyLocks=null, topologyId=0, isFromStateTransfer=false} org.infinispan.transaction.synchronization.SyncLocalTransaction at 4} org.infinispan.transaction.synchronization.SynchronizationAdapter at 23: org.infinispan.CacheException: Could not commit.
> 	at org.infinispan.transaction.synchronization.SynchronizationAdapter.afterCompletion(SynchronizationAdapter.java:83)
> 	at org.infinispan.transaction.tm.DummyTransaction.notifyAfterCompletion(DummyTransaction.java:285)
> 	at org.infinispan.transaction.tm.DummyTransaction.runCommitTx(DummyTransaction.java:334)
> 	at org.infinispan.transaction.tm.DummyTransaction.commit(DummyTransaction.java:91)
> 	at org.infinispan.transaction.tm.DummyBaseTransactionManager.commit(DummyBaseTransactionManager.java:102)
> 	at org.infinispan.batch.BatchContainer.resolveTransaction(BatchContainer.java:123)
> 	at org.infinispan.batch.BatchContainer.endBatch(BatchContainer.java:105)
> 	at org.infinispan.batch.BatchContainer.endBatch(BatchContainer.java:86)
> 	at org.infinispan.CacheImpl.endBatch(CacheImpl.java:793)
> 	at org.infinispan.AbstractDelegatingCache.endBatch(AbstractDelegatingCache.java:80)
> 	at org.wildfly.clustering.web.infinispan.session.InfinispanSessionManager.endBatch(InfinispanSessionManager.java:120)
> 	at org.wildfly.clustering.web.undertow.session.SessionFacade.requestDone(SessionFacade.java:58)
> 	at io.undertow.servlet.spec.ServletContextImpl.updateSessionAccessTime(ServletContextImpl.java:682) [undertow-servlet-1.0.0.Alpha21.jar:1.0.0.Alpha21]
> 	at io.undertow.servlet.spec.HttpServletResponseImpl.responseDone(HttpServletResponseImpl.java:494) [undertow-servlet-1.0.0.Alpha21.jar:1.0.0.Alpha21]
> 	at io.undertow.servlet.handlers.ServletInitialHandler.handleFirstRequest(ServletInitialHandler.java:161) [undertow-servlet-1.0.0.Alpha21.jar:1.0.0.Alpha21]
> 	at io.undertow.servlet.handlers.ServletInitialHandler.dispatchRequest(ServletInitialHandler.java:114) [undertow-servlet-1.0.0.Alpha21.jar:1.0.0.Alpha21]
> 	at io.undertow.servlet.handlers.ServletInitialHandler.access$000(ServletInitialHandler.java:47) [undertow-servlet-1.0.0.Alpha21.jar:1.0.0.Alpha21]
> 	at io.undertow.servlet.handlers.ServletInitialHandler$1.handleRequest(ServletInitialHandler.java:90) [undertow-servlet-1.0.0.Alpha21.jar:1.0.0.Alpha21]
> 	at io.undertow.server.HttpHandlers.executeRootHandler(HttpHandlers.java:36) [undertow-core-1.0.0.Alpha21.jar:1.0.0.Alpha21]
> 	at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:607) [undertow-core-1.0.0.Alpha21.jar:1.0.0.Alpha21]
> 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_21]
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_21]
> 	at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0_21]
> Caused by: javax.transaction.xa.XAException
> 	at org.infinispan.transaction.TransactionCoordinator.handleCommitFailure(TransactionCoordinator.java:231)
> 	at org.infinispan.transaction.TransactionCoordinator.commit(TransactionCoordinator.java:179)
> 	at org.infinispan.transaction.synchronization.SynchronizationAdapter.afterCompletion(SynchronizationAdapter.java:81)
> 	... 22 more
> {noformat}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the jboss-jira mailing list