[
https://issues.apache.org/jira/browse/AMQ-6933?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Martin Lichtin updated AMQ-6933:
--------------------------------
Affects Version/s: 5.18.6
> Re-use buffer in DataByteArrayOutputStream.restart() to avoid unnecessary GC
> ----------------------------------------------------------------------------
>
> Key: AMQ-6933
> URL: https://issues.apache.org/jira/browse/AMQ-6933
> Project: ActiveMQ Classic
> Issue Type: Improvement
> Affects Versions: 5.18.6
> Reporter: Martin Lichtin
> Priority: Major
>
> Re-use buffer in DataByteArrayOutputStream.restart(int size) to avoid
> unnecessary GC.
> The buf[] array only needs to be reallocated in case the requested size is
> larger than the existing buffer size.
>
> {noformat}
> Stack Trace TLABs Total TLAB Size(bytes) Pressure(%)
> org.apache.activemq.util.DataByteArrayOutputStream.restart(int) 1'398
> 516'041'504 9.413
> org.apache.activemq.util.DataByteArrayOutputStream.restart() 1'398
> 516'041'504 9.413
> org.apache.activemq.openwire.OpenWireFormat.marshal(Object, DataOutput)
> 1'398 516'041'504 9.413
> {noformat}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information, visit: https://activemq.apache.org/contact