increase average size overhead of a message to 500 bytes

git-svn-id: https://svn.apache.org/repos/asf/incubator/activemq/trunk@499758 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Robert Davies 2007-01-25 12:19:40 +00:00
parent 0552f4a1b0
commit 1b8148cd37
1 changed files with 2 additions and 2 deletions

View File

@ -41,7 +41,7 @@ import org.apache.activemq.wireformat.WireFormat;
*/
abstract public class Message extends BaseCommand implements MarshallAware, MessageReference {
public static final int AVERAGE_MESSAGE_SIZE_OVERHEAD = 300;
public static final int AVERAGE_MESSAGE_SIZE_OVERHEAD = 500;
protected MessageId messageId;
protected ActiveMQDestination originalDestination;
@ -604,7 +604,7 @@ abstract public class Message extends BaseCommand implements MarshallAware, Mess
}
public int getSize() {
if( size == 0 ) {
if( size <=AVERAGE_MESSAGE_SIZE_OVERHEAD ) {
size = AVERAGE_MESSAGE_SIZE_OVERHEAD;
if( marshalledProperties!=null )
size += marshalledProperties.getLength();