[
https://issues.apache.org/jira/browse/GEODE-1238?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Darrel Schneider reopened GEODE-1238:
-------------------------------------
The previous checkin introduced a problem that now causes putall and removeall
on off-heap to fail with:
IllegalStateException: Attempt to access off heap value after the EntryEvent
was released
The problem with the previous change is that it marked getEventForPosition as
@Retained. It really should be @Unretained since the owner of the region is the
put/removeAllData array. That array does its releases in freeOffHeapResources().
> EntryEventImpl creators must be careful to release to prevent off-heap leaks
> ----------------------------------------------------------------------------
>
> Key: GEODE-1238
> URL: https://issues.apache.org/jira/browse/GEODE-1238
> Project: Geode
> Issue Type: Bug
> Components: offheap
> Reporter: Darrel Schneider
> Assignee: Darrel Schneider
> Fix For: 1.0.0-incubating.M3
>
>
> When an instance of EntryEventImpl is created the creator needs to make sure
> release() is called on it or make sure it can not have off-heap references.
> If the method that created the EntryEventImpl always releases it before the
> method completes then it should add the @Released annotation to the local
> variable.
> If the method that created the EntryEventImpl returns it to the caller then
> that method and the local variable should annotated with @Retained.
> If it knows the EntryEventImpl will never have an off-heap reference then a
> comment to the local variable should be added explaining why release is not
> needed.
> If it knows that the EntryEventImpl will be stored in some other object and
> it has responsibility for releasing it then a comment should be added saying
> so.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)