You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@geode.apache.org by "Swapnil Bawaskar (JIRA)" <ji...@apache.org> on 2016/10/25 07:18:05 UTC
[jira] [Closed] (GEODE-1813) Queued events are not removed when
using an AsyncEventListener with a fixed partitioned region
[ https://issues.apache.org/jira/browse/GEODE-1813?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Swapnil Bawaskar closed GEODE-1813.
-----------------------------------
> Queued events are not removed when using an AsyncEventListener with a fixed partitioned region
> ----------------------------------------------------------------------------------------------
>
> Key: GEODE-1813
> URL: https://issues.apache.org/jira/browse/GEODE-1813
> Project: Geode
> Issue Type: Bug
> Components: wan
> Reporter: Dan Smith
> Assignee: Dan Smith
> Fix For: 1.0.0-incubating
>
>
> Using an AsyncEventListener with a fixed partitioned region results in IllegalStateExceptions in the log and events not getting removed.
> {noformat}
> [vm_1][warn 2016/08/23 09:51:35.871 PDT <Event Processor for GatewaySender_AsyncEventQueue_ln_0> tid=0x3d] An Exception occurred. The dispatcher will continue.
> [vm_1]java.lang.IllegalStateException: For FixedPartitionedRegion "AsyncEventQueue_ln_PARALLEL_GATEWAY_SENDER_QUEUE", FixedPartitionResolver is not available (neither through the partition attribute partition-resolver nor key/callbackArg implementing FixedPartitionResolver)
> [vm_1] at com.gemstone.gemfire.internal.cache.PartitionedRegionHelper.getHashKey(PartitionedRegionHelper.java:626)
> [vm_1] at com.gemstone.gemfire.internal.cache.PartitionedRegionHelper.getHashKey(PartitionedRegionHelper.java:546)
> [vm_1] at com.gemstone.gemfire.internal.cache.PartitionedRegion.getKeyInfo(PartitionedRegion.java:10133)
> [vm_1] at com.gemstone.gemfire.internal.cache.EntryEventImpl.<init>(EntryEventImpl.java:237)
> [vm_1] at com.gemstone.gemfire.internal.cache.EntryEventImpl.create(EntryEventImpl.java:394)
> [vm_1] at com.gemstone.gemfire.internal.cache.EntryEventImpl.create(EntryEventImpl.java:328)
> [vm_1] at com.gemstone.gemfire.internal.cache.LocalRegion.newDestroyEntryEvent(LocalRegion.java:1167)
> [vm_1] at com.gemstone.gemfire.internal.cache.BucketRegionQueue.destroyKey(BucketRegionQueue.java:502)
> [vm_1] at com.gemstone.gemfire.internal.cache.wan.parallel.ParallelGatewaySenderQueue.destroyEventFromQueue(ParallelGatewaySenderQueue.java:1128)
> [vm_1] at com.gemstone.gemfire.internal.cache.wan.parallel.ParallelGatewaySenderQueue.remove(ParallelGatewaySenderQueue.java:1109)
> [vm_1] at com.gemstone.gemfire.internal.cache.wan.parallel.ParallelGatewaySenderQueue.remove(ParallelGatewaySenderQueue.java:1543)
> [vm_1] at com.gemstone.gemfire.internal.cache.wan.AbstractGatewaySenderEventProcessor.eventQueueRemove(AbstractGatewaySenderEventProcessor.java:238)
> [vm_1] at com.gemstone.gemfire.internal.cache.wan.AbstractGatewaySenderEventProcessor.handleSuccessfulBatchDispatch(AbstractGatewaySenderEventProcessor.java:910)
> [vm_1] at com.gemstone.gemfire.internal.cache.wan.AbstractGatewaySenderEventProcessor.processQueue(AbstractGatewaySenderEventProcessor.java:635)
> [vm_1] at com.gemstone.gemfire.internal.cache.wan.AbstractGatewaySenderEventProcessor.run(AbstractGatewaySenderEventProcessor.java:1058){noformat}
> Analysis from [~barry.oglesby]:
> This issue happens after the event has been processed by the AsyncEventListener. When the event is removed from the BucketRegionQueue, an EntryEventImpl is created. The EntryEventImpl constructor attempts to get the appropriate bucket from which to remove the entry even though this has already been decided by the data PR. For fixed partitioning, the getHashKey method requires a FixedPartitionResolver, and since one has not been set in the BucketRegionQueue, an exception is thrown. In the non-fixed partitioning case, no PartitionResolver is necessary, so the fact that there isn't one set doesn't matter.
> The reason the getHashKey method goes down the fixed partitioning code path is the colocated BucketRegionQueue's fixed partitioning attributes are set in the PartitionedRegion constructor based on the parent's fixed partitioning attributes. This is unnecessary in the BucketRegionQueue case.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)