[ 
https://issues.apache.org/jira/browse/OOZIE-3250?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16475528#comment-16475528
 ] 

Andras Piros commented on OOZIE-3250:
-------------------------------------

[~gezapeti] using now {{==}} instead of {{Arrays.equals()}} to show that all 
interned {{byte[]}} instances are the same. Also introduced another test case 
to show that interning a huge {{byte[]}} many times doesn't increase heap in 
any significant way, and is fast (1000 x 1MB in 1.5 seconds on my machine). So 
I don't think we have a performance problem here. I'm also sure the contents of 
the interned {{byte[]}} instances aren't changing without modifying the 
underlying arrays. I'm planning another round of Oozie heap analysis with 
multiple running coordinators before and after the fix.

[[email protected]] added a similar check before to show that copied 
{{byte[]}} point to another instances, for better maintainability.

> Reduce heap waste by reducing duplicate byte[] count
> ----------------------------------------------------
>
>                 Key: OOZIE-3250
>                 URL: https://issues.apache.org/jira/browse/OOZIE-3250
>             Project: Oozie
>          Issue Type: Improvement
>          Components: core
>    Affects Versions: 5.0.0
>            Reporter: Andras Piros
>            Assignee: Andras Piros
>            Priority: Major
>         Attachments: OOZIE-3250.001.patch, OOZIE-3250.002.patch
>
>
> Similar to OOZIE-3232, we also need to intern the {{byte[]}} field values 
> within 
> [*{{BinaryBlob}}*|https://github.com/apache/oozie/blob/master/core/src/main/java/org/apache/oozie/BinaryBlob.java#L32-L33]
>  and 
> [*{{StringBlob}}*|https://github.com/apache/oozie/blob/master/core/src/main/java/org/apache/oozie/StringBlob.java#L34]
>  to reduce heap waste caused by duplicate {{byte[]}} entries.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to