[
https://issues.apache.org/jira/browse/GEODE-3314?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16113740#comment-16113740
]
ASF GitHub Bot commented on GEODE-3314:
---------------------------------------
Github user galen-pivotal commented on a diff in the pull request:
https://github.com/apache/geode/pull/683#discussion_r131290383
--- Diff:
geode-core/src/main/java/org/apache/geode/distributed/internal/locks/DLockToken.java
---
@@ -302,14 +302,14 @@ boolean checkForExpiration() {
* @param remoteThread identity of the leasing thread
* @return true if lease for this lock token is successfully granted
*/
- synchronized boolean grantLock(long newLeaseExpireTime, int newLeaseId,
int newRecursion,
+ synchronized void grantLock(long newLeaseExpireTime, int newLeaseId, int
newRecursion,
RemoteThread remoteThread) {
Assert.assertTrue(remoteThread != null);
Assert.assertTrue(newLeaseId > -1, "Invalid attempt to grant lock with
leaseId " + newLeaseId);
checkDestroyed();
- checkForExpiration();
+ checkForExpiration(); // TODO: this should throw.
--- End diff --
yeah, that's probably a good idea. It looks like `checkForExpiration` is
being used for the side effect of expiring the lock if it's run out of time.
This method could be made clearer.
> OldGen heap usage grows without increase in data size, large number of
> DLockTokens
> ----------------------------------------------------------------------------------
>
> Key: GEODE-3314
> URL: https://issues.apache.org/jira/browse/GEODE-3314
> Project: Geode
> Issue Type: Bug
> Components: distributed lock service
> Reporter: Udo Kohlmeyer
> Assignee: Galen O'Sullivan
> Fix For: 1.2.1
>
>
> When using Global Replicate regions, the DLockTokens are not correctly
> cleaned up, causing a memory leak.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)