oehme commented on issue #243: [MNG-6633] - Reduce memory usage of excludes URL: https://github.com/apache/maven/pull/243#issuecomment-486401811 The object has a header of 12 bytes, plus 4 bytes for both fields, rounded up to multiples of 8 => 24 bytes per object. The string `commons-lang:commons-lang` has 25 characters, all LATIN-1, which on Java 9 and above is represented with 25 bytes (50 bytes on older Java versions). To that we need to add the array object header (12 bytes). We also have a String object wrapped around it, which has a reference to the char array (4 bytes) plus the `coder` field (4 bytes), plus the `hashCode` field (4 bytes) plus the object header (12 bytes) ==> 61 bytes for that String. It gets worse the longer a groupId/artifactId is. However, an even better solution would be to have a wrapper around the existing `Exclude` object. This is why I asked whether using a new class instead of the existing `ExcludeArtifactFilter` is an option (maybe @hboutemy can comment on that?). If we do that, we reduce the size per exclude to 16 bytes.
---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services