[
https://issues.apache.org/jira/browse/ARTEMIS-1357?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16135318#comment-16135318
]
ASF GitHub Bot commented on ARTEMIS-1357:
-----------------------------------------
GitHub user franz1981 opened a pull request:
https://github.com/apache/activemq-artemis/pull/1478
ARTEMIS-1357 TypedProperties encode/decode improvement
Several improvements are made on the encode/decode paths:
- fixed load factor on properties to avoid resizing/rehashing and reduce GC
pressure
- cached BooleanValue/NullValue instances to reduce GC pressure
- used internal iteration throught lamda while encoding properties to
reduce GC pressure and allows loop unrolling
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/franz1981/activemq-artemis
improve_typed_properties_decode
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/activemq-artemis/pull/1478.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 #1478
----
commit 5c386a857206c3bf3b19909c33f9c670ec7ded80
Author: Francesco Nigro <[email protected]>
Date: 2017-08-21T14:29:22Z
ARTEMIS-1357 TypedProperties encode/decode improvement
----
> TypedProperties encode/decode improvement
> -----------------------------------------
>
> Key: ARTEMIS-1357
> URL: https://issues.apache.org/jira/browse/ARTEMIS-1357
> Project: ActiveMQ Artemis
> Issue Type: Improvement
> Components: Broker
> Reporter: Francesco Nigro
> Assignee: Francesco Nigro
>
> In the TypedProperties decode path are possible several improvements:
> * avoid resizing (with rehashing) of the properties map
> * avoid any allocation of BooleanValue and NullValue
> In the TypedProperties encode path is possible to use internal looping using
> Java 8 lambdas:
> * to avoid the allocation of the Entries collection + iterator
> * to increase the chance of loop unrolling during the iteration
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)