Skip to content

Commit

Permalink
Fix v1.2.2.5
Browse files Browse the repository at this point in the history
  • Loading branch information
sinattieng committed Jul 14, 2022
1 parent a869668 commit d506dc2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/META-INF/ra.xml
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ This source code is being made available to the public under the terms specified
<config-property>
<config-property-name>transactionTimeout</config-property-name>
<config-property-type>java.lang.Integer</config-property-type>
<config-property-value>60</config-property-value>
<config-property-value>0</config-property-value>
</config-property>
<config-property>
<config-property-name>enableRemoteInvocations</config-property-name>
Expand Down
3 changes: 2 additions & 1 deletion src/org/xadisk/filesystem/workers/GatheringDiskWriter.java
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,7 @@ private void addInMemoryBufferToTransaction(TransactionInformation xid, Buffer b

public void submitBuffer(Buffer logEntry, TransactionInformation xid) {
logEntry.flushByteBufferChanges();
int bufferSizeToAdd = logEntry.getBuffer().remaining();
ConcurrentLinkedQueue<Buffer> txnBuffers = transactionSubmittedBuffers.get(xid);
if (txnBuffers == null) {
txnBuffers = new ConcurrentLinkedQueue<Buffer>();
Expand All @@ -206,7 +207,7 @@ public void submitBuffer(Buffer logEntry, TransactionInformation xid) {
} else {
txnBuffers.add(logEntry);
}
int currentCumulativeSize = cumulativeBufferSize.addAndGet(logEntry.getBuffer().remaining());
int currentCumulativeSize = cumulativeBufferSize.addAndGet(bufferSizeToAdd);
raiseEventThreadSafely(currentCumulativeSize);
}

Expand Down

0 comments on commit d506dc2

Please sign in to comment.