View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0002374 | SymmetricDS | Bug | public | 2015-08-24 17:55 | 2015-09-11 20:14 |
Reporter | dporob79 | Assigned To | chenson | ||
Priority | normal | ||||
Status | closed | Resolution | fixed | ||
Product Version | 3.4.9 | ||||
Target Version | 3.7.21 | Fixed in Version | 3.7.21 | ||
Summary | 0002374: Memory being held up un-necessarily in StagingManager and StagedResource | ||||
Description | The Staging manager does clean up the resources after the TTL. But the memoryBuffer which is being used (in StagedResource) is held up un-necssarily after the state of the resource changes to 'DONE'. I am talking specifically about resources which are first held in memory and then written to file (when the threshold is reached). So, if the TTL is 1 hour, then this memoryBuffer is held in memory for that one hour. I was looking at the code and the implementation of the setState function in StagedResource checks whether a file exists and if yes renames the file else it sets the memoryBuffer to null. Shouldn't it be cleaning up the memory buffer even if the file exists and the state is changed to DONE ? Essentially shouldn't the below code snippet (in setState function of StagedResource) change from : ===================================== } else if (memoryBuffer != null && state == State.DONE) { this.memoryBuffer.setLength(0); this.memoryBuffer = null; } ===================================== TO ===================================== } if (memoryBuffer != null && state == State.DONE) { this.memoryBuffer.setLength(0); this.memoryBuffer = null; } ===================================== I see that the latest trunk code also has the same issue. Why would we need the memoryBuffer after the state has changed to 'DONE' ? | ||||
Steps To Reproduce | While large number of events are being replicated, take a heap dump of the JVM which is hosting the symmetric engine and check the amount of memory which is occupied by the StagingManager. | ||||
Tags | No tags attached. | ||||
Date Modified | Username | Field | Change |
---|---|---|---|
2015-08-24 17:55 | dporob79 | New Issue | |
2015-08-24 20:20 | chenson | Note Added: 0000712 | |
2015-08-24 20:28 | chenson | Assigned To | => chenson |
2015-08-24 20:28 | chenson | Status | new => assigned |
2015-08-24 20:29 | chenson | Fixed in Version | => 3.7.21 |
2015-08-24 20:29 | chenson | Target Version | => 3.7.21 |
2015-08-24 20:29 | chenson | Status | assigned => resolved |
2015-08-24 20:29 | chenson | Resolution | open => fixed |
2015-08-24 21:00 | chenson | Changeset attached | => SymmetricDS 3.7 49fe0a58 |
2015-09-11 20:14 | chenson | Status | resolved => closed |