[jboss-jira] [JBoss JIRA] (JGRP-2011) Rsp: optimize in-memory size
Bela Ban (JIRA)
issues at jboss.org
Tue Feb 2 06:42:00 EST 2016
[ https://issues.jboss.org/browse/JGRP-2011?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Bela Ban updated JGRP-2011:
---------------------------
Description:
The in-memory size of {{Rsp}} can be made smaller. Currently, it looks like this:
{noformat}
public class Rsp {
protected boolean received;
protected boolean suspected;
protected boolean unreachable;
protected final Address sender;
protected T retval;
protected Throwable exception;
}
{noformat}
Optimizations:
# received, suspected and unreachable can be compacted into a byte field (flags)
# retval and exception can be merged into {{Object value}}
# sender can be removed: {{RspList}} already has the sender
Size of {{Rsp}} is 32 bytes (used JOL to measure) before, and 24 bytes after the changes.
was:
The in-memory size of {{Rsp}} can be made smaller. Currently, it looks like this:
{noformat}
public class Rsp {
protected boolean received;
protected boolean suspected;
protected boolean unreachable;
protected final Address sender;
protected T retval;
protected Throwable exception;
}
{noformat}
Optimizations:
# received, suspected and unreachable can be compacted into a byte field (flags)
# retval and exception can be merged into {{Object value}}
# sender can be removed: {{RspList}} already has the sender
Size of {{Rsp}} is 32 bytes (used JOL to measure)
> Rsp: optimize in-memory size
> ----------------------------
>
> Key: JGRP-2011
> URL: https://issues.jboss.org/browse/JGRP-2011
> Project: JGroups
> Issue Type: Enhancement
> Reporter: Bela Ban
> Assignee: Bela Ban
> Priority: Minor
> Fix For: 3.6.8, 4.0
>
>
> The in-memory size of {{Rsp}} can be made smaller. Currently, it looks like this:
> {noformat}
> public class Rsp {
> protected boolean received;
> protected boolean suspected;
> protected boolean unreachable;
> protected final Address sender;
> protected T retval;
> protected Throwable exception;
> }
> {noformat}
> Optimizations:
> # received, suspected and unreachable can be compacted into a byte field (flags)
> # retval and exception can be merged into {{Object value}}
> # sender can be removed: {{RspList}} already has the sender
> Size of {{Rsp}} is 32 bytes (used JOL to measure) before, and 24 bytes after the changes.
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
More information about the jboss-jira
mailing list