You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@geode.apache.org by "Mario Ivanac (Jira)" <ji...@apache.org> on 2022/09/19 06:19:00 UTC

[jira] [Resolved] (GEODE-10331) DistributionImpl.destroyMember keeps cache alive for some number of seconds

     [ https://issues.apache.org/jira/browse/GEODE-10331?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mario Ivanac resolved GEODE-10331.
----------------------------------
    Fix Version/s: 1.16.0
       Resolution: Fixed

> DistributionImpl.destroyMember keeps cache alive for some number of seconds
> ---------------------------------------------------------------------------
>
>                 Key: GEODE-10331
>                 URL: https://issues.apache.org/jira/browse/GEODE-10331
>             Project: Geode
>          Issue Type: Bug
>          Components: membership
>            Reporter: Darrel Schneider
>            Assignee: Mario Ivanac
>            Priority: Major
>              Labels: blocks-1.16.0, pull-request-available
>             Fix For: 1.16.0
>
>
> org.apache.geode.distributed.internal.DistributionImpl.destroyMember creates a thread that will hold onto the DIstributesSystem/Cache through the DirectChannel it has for 3 seconds by default. It could be even longer if p2p.disconnectDelay is set to a value > 3000.
> This can be a problem if the JVM is trying to reconnect since this old cache uses memory.
> Instead of creating a new thread for every call of destroyMember, we should just have a single ScheduledExecutor that we schedule the background "closeEndpoint" with.
> Also since all this code interacts with the DirectChannel all the logic about the executor and scheduling it should belong to DirectChannel, not the DistributionImpl.
> When the DirectChannel has disconnect called on it, then it should get rid of all the tasks scheduled in the executor since they are no longer needed.
> I think this issue has been around for a long time because the creation of the thread refers to fixing "Bug 37944" which is on old bug system that is not longer used for geode.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)