[JBoss JIRA] Created: (ISPN-569) IllegalMonitorStateException thrown when releasing the lock
by Galder Zamarreno (JIRA)
IllegalMonitorStateException thrown when releasing the lock
-----------------------------------------------------------
Key: ISPN-569
URL: https://jira.jboss.org/browse/ISPN-569
Project: Infinispan
Issue Type: Bug
Components: Locking and Concurrency
Affects Versions: 4.1.0.CR2, 4.0.0.Final
Reporter: Galder Zamarreno
Assignee: Galder Zamarreno
Fix For: 4.1.0.Final
This simple test case:
public class SkipLockingTest extends SingleCacheManagerTest {
private AdvancedCache advancedCache;
@Override
protected EmbeddedCacheManager createCacheManager() throws Exception {
Configuration c = new Configuration();
c.setCacheMode(Configuration.CacheMode.LOCAL);
EmbeddedCacheManager cacheManager = new DefaultCacheManager(c);
advancedCache = cacheManager.getCache().getAdvancedCache();
return cacheManager;
}
public void testExistsInContextPut(Method m) {
String name = m.getName();
advancedCache.put("k-" + name, "v-" + name);
advancedCache.withFlags(Flag.SKIP_LOCKING).put("k-" + name, "v2-" + name);
}
}
throws:
java.lang.IllegalMonitorStateException
at java.util.concurrent.locks.ReentrantLock$Sync.tryRelease(ReentrantLock.java:127)
at java.util.concurrent.locks.AbstractQueuedSynchronizer.release(AbstractQueuedSynchronizer.java:1175)
at java.util.concurrent.locks.ReentrantLock.unlock(ReentrantLock.java:431)
at org.infinispan.util.concurrent.locks.containers.AbstractStripedLockContainer.releaseLock(AbstractStripedLockContainer.java:98)
at org.infinispan.util.concurrent.locks.LockManagerImpl.unlock(LockManagerImpl.java:100)
at org.infinispan.interceptors.LockingInterceptor.cleanupLocks(LockingInterceptor.java:289)
at org.infinispan.interceptors.LockingInterceptor.doAfterCall(LockingInterceptor.java:243)
at org.infinispan.interceptors.LockingInterceptor.visitPutKeyValueCommand(LockingInterceptor.java:200)
at org.infinispan.commands.write.PutKeyValueCommand.acceptVisitor(PutKeyValueCommand.java:76)
at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:118)
at org.infinispan.interceptors.base.CommandInterceptor.handleDefault(CommandInterceptor.java:132)
at org.infinispan.commands.AbstractVisitor.visitPutKeyValueCommand(AbstractVisitor.java:57)
at org.infinispan.commands.write.PutKeyValueCommand.acceptVisitor(PutKeyValueCommand.java:76)
at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:118)
at org.infinispan.interceptors.TxInterceptor.enlistWriteAndInvokeNext(TxInterceptor.java:183)
at org.infinispan.interceptors.TxInterceptor.visitPutKeyValueCommand(TxInterceptor.java:132)
at org.infinispan.commands.write.PutKeyValueCommand.acceptVisitor(PutKeyValueCommand.java:76)
at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:118)
at org.infinispan.interceptors.InvocationContextInterceptor.handleAll(InvocationContextInterceptor.java:58)
at org.infinispan.interceptors.InvocationContextInterceptor.handleDefault(InvocationContextInterceptor.java:39)
at org.infinispan.commands.AbstractVisitor.visitPutKeyValueCommand(AbstractVisitor.java:57)
at org.infinispan.commands.write.PutKeyValueCommand.acceptVisitor(PutKeyValueCommand.java:76)
at org.infinispan.interceptors.InterceptorChain.invoke(InterceptorChain.java:271)
at org.infinispan.CacheDelegate.put(CacheDelegate.java:426)
at org.infinispan.CacheSupport.put(CacheSupport.java:28)
at org.infinispan.api.SkipLockingTest.testExistsInContextPut(SkipLockingTest.java:41)
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 4 months
[JBoss JIRA] Created: (ISPN-574) Marshaller to stop before Transport to avoid NullPointerException
by Galder Zamarreno (JIRA)
Marshaller to stop before Transport to avoid NullPointerException
-----------------------------------------------------------------
Key: ISPN-574
URL: https://jira.jboss.org/browse/ISPN-574
Project: Infinispan
Issue Type: Bug
Components: Marshalling, RPC
Affects Versions: 4.1.0.CR2, 4.0.0.Final
Reporter: Galder Zamarreno
Assignee: Galder Zamarreno
Fix For: 4.1.0.Final
Currently both the marshaller and transport have the same stop priority.
Marshaller should stop *after* transport, otherwise the marshaller could have been stopped but something might still be received in the transport channel and you could get an NPE like this:
Exception in thread "Scarlet/Lucene service thread index reopening thread-1" java.lang.NullPointerException
at org.infinispan.marshall.jboss.ConstantObjectTable.readObject(ConstantObjectTable.java:253)
at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:357)
at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:207)
at org.jboss.marshalling.AbstractUnmarshaller.readObject(AbstractUnmarshaller.java:85)
at org.infinispan.marshall.jboss.GenericJBossMarshaller.objectFromObjectStream(GenericJBossMarshaller.java:163)
at org.infinispan.marshall.VersionAwareMarshaller.objectFromByteBuffer(VersionAwareMarshaller.java:111)
at org.infinispan.marshall.AbstractStreamingMarshaller.objectFromInputStream(AbstractStreamingMarshaller.java:24)
at org.infinispan.loaders.jdbc.JdbcUtil.unmarshall(JdbcUtil.java:88)
at org.infinispan.loaders.jdbc.binary.JdbcBinaryCacheStore.loadBucket(JdbcBinaryCacheStore.java:220)
at org.infinispan.loaders.bucket.BucketBasedCacheStore.loadLockSafe(BucketBasedCacheStore.java:36)
at org.infinispan.loaders.LockSupportCacheStore.load(LockSupportCacheStore.java:96)
at org.infinispan.loaders.decorators.AbstractDelegatingStore.load(AbstractDelegatingStore.java:86)
at org.infinispan.interceptors.CacheLoaderInterceptor.loadIfNeeded(CacheLoaderInterceptor.java:133)
at org.infinispan.interceptors.CacheLoaderInterceptor.loadIfNeededAndUpdateStats(CacheLoaderInterceptor.java:195)
at org.infinispan.interceptors.CacheLoaderInterceptor.visitGetKeyValueCommand(CacheLoaderInterceptor.java:86)
at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:58)
at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:118)
at org.infinispan.interceptors.base.CommandInterceptor.handleDefault(CommandInterceptor.java:132)
at org.infinispan.commands.AbstractVisitor.visitGetKeyValueCommand(AbstractVisitor.java:87)
at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:58)
at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:118)
at org.infinispan.interceptors.TxInterceptor.enlistReadAndInvokeNext(TxInterceptor.java:171)
at org.infinispan.interceptors.TxInterceptor.visitGetKeyValueCommand(TxInterceptor.java:162)
at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:58)
at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:118)
at org.infinispan.interceptors.CacheMgmtInterceptor.visitGetKeyValueCommand(CacheMgmtInterceptor.java:83)
at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:58)
at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:118)
at org.infinispan.interceptors.InvocationContextInterceptor.handleAll(InvocationContextInterceptor.java:58)
at org.infinispan.interceptors.InvocationContextInterceptor.handleDefault(InvocationContextInterceptor.java:39)
at org.infinispan.commands.AbstractVisitor.visitGetKeyValueCommand(AbstractVisitor.java:87)
at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:58)
at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:118)
at org.infinispan.interceptors.BatchingInterceptor.handleDefault(BatchingInterceptor.java:76)
at org.infinispan.commands.AbstractVisitor.visitGetKeyValueCommand(AbstractVisitor.java:87)
at org.infinispan.commands.read.GetKeyValueCommand.acceptVisitor(GetKeyValueCommand.java:58)
at org.infinispan.interceptors.InterceptorChain.invoke(InterceptorChain.java:271)
at org.infinispan.CacheDelegate.get(CacheDelegate.java:199)
at org.infinispan.lucene.InfinispanDirectory.getFileList(InfinispanDirectory.java:235)
at org.infinispan.lucene.InfinispanDirectory.list(InfinispanDirectory.java:102)
at org.infinispan.lucene.InfinispanDirectory.listAll(InfinispanDirectory.java:287)
at org.apache.lucene.index.SegmentInfos$FindSegmentsFile.run(SegmentInfos.java:564)
at org.apache.lucene.index.SegmentInfos$FindSegmentsFile.run(SegmentInfos.java:517)
at org.apache.lucene.index.SegmentInfos.read(SegmentInfos.java:306)
at org.apache.lucene.index.SegmentInfos.readCurrentVersion(SegmentInfos.java:408)
at org.apache.lucene.index.DirectoryReader.isCurrent(DirectoryReader.java:797)
at org.apache.lucene.index.DirectoryReader.doReopenNoWriter(DirectoryReader.java:407)
at org.apache.lucene.index.DirectoryReader.doReopen(DirectoryReader.java:386)
at org.apache.lucene.index.DirectoryReader.reopen(DirectoryReader.java:348)
at com.sourcesense.scarlet.index.lucenetuning.ReaderPooler$ReopenReaderRunnable.run(ReaderPooler.java:254)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 4 months