[ https://issues.apache.org/jira/browse/FLINK-5002?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15695114#comment-15695114 ]
ASF GitHub Bot commented on FLINK-5002: --------------------------------------- GitHub user MayerRoman opened a pull request: https://github.com/apache/flink/pull/2865 [FLINK-5002] Renamed getNumberOfUsedBuffers() method to bestEffortGetNumOfUsedBuffers(), add a test to check that it does not return a negative value [FLINK-5002] Lack of synchronization in LocalBufferPool#getNumberOfUsedBuffers According to Stefan proposal, I renamed the method and added test to make sure that the method does not return a negative value. You can merge this pull request into a Git repository by running: $ git pull https://github.com/MayerRoman/flink FLINK_5002 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/flink/pull/2865.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #2865 ---- commit 5b7a17f54d37ac028335343742ba7021e047ca64 Author: Roman Maier <roman_ma...@epam.com> Date: 2016-11-18T13:51:58Z [FLINK-5002] Renamed getNumberOfUsedBuffers() method to bestEffortGetNumOfUsedBuffers(), add a test to check that it does not return a negative value. ---- > Lack of synchronization in LocalBufferPool#getNumberOfUsedBuffers > ----------------------------------------------------------------- > > Key: FLINK-5002 > URL: https://issues.apache.org/jira/browse/FLINK-5002 > Project: Flink > Issue Type: Bug > Reporter: Ted Yu > Assignee: Roman Maier > Priority: Minor > Labels: easyfix, starter > > {code} > public int getNumberOfUsedBuffers() { > return numberOfRequestedMemorySegments - availableMemorySegments.size(); > } > {code} > Access to availableMemorySegments should be protected with proper > synchronization as other methods do. -- This message was sent by Atlassian JIRA (v6.3.4#6332)