ARTEMIS-3604 Fixing size adjustment

This commit is contained in:
franz1981 2021-12-11 08:23:33 +01:00 committed by clebertsuconic
parent af13d90c57
commit 03b61c5da0
1 changed files with 3 additions and 3 deletions

View File

@ -67,8 +67,8 @@ public class ThresholdActor<T> extends ProcessorBase<Object> {
listener.onMessage(theTask);
} finally {
if (estimateSize > 0) {
SIZE_UPDATER.getAndAdd(this, -size);
} else {
SIZE_UPDATER.getAndAdd(this, -estimateSize);
} else if (logger.isDebugEnabled()) {
logger.debug("element " + theTask + " returned an invalid size over the Actor during release");
}
}
@ -81,7 +81,7 @@ public class ThresholdActor<T> extends ProcessorBase<Object> {
if (size > maxSize) {
flush();
}
} else {
} else if (logger.isDebugEnabled()) {
logger.debug("element " + message + " returned an invalid size over the Actor");
}
task(message);