diff options
| author | Martin Ritchie <ritchiem@apache.org> | 2009-03-06 12:30:20 +0000 |
|---|---|---|
| committer | Martin Ritchie <ritchiem@apache.org> | 2009-03-06 12:30:20 +0000 |
| commit | 7d72d608659fc8b77f0eb0410500c3072b8f3ba1 (patch) | |
| tree | 676cfcefb21c3440f1995f703f02710fa7fc24b8 /java/broker/src/main | |
| parent | f59c9a4595b90ae73a0b8801fc1ad33b38d7b5d4 (diff) | |
| download | qpid-python-7d72d608659fc8b77f0eb0410500c3072b8f3ba1.tar.gz | |
QPID-949, QPID-1633 : Set default Maximum Memory Usage for a queue to 100Meg. Future work would be to have the broker split Xmx between VirtualHost and for the Vhost then to use its housekeeping thread to spread the memory between the current queues. It could of course be clever and give more memory to queues in high use.
Mistype in AMQQueueFactory resulted in it setting the Max Queue Size alert rather than the Max Memory value
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@750875 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'java/broker/src/main')
| -rw-r--r-- | java/broker/src/main/java/org/apache/qpid/server/configuration/QueueConfiguration.java | 2 | ||||
| -rw-r--r-- | java/broker/src/main/java/org/apache/qpid/server/queue/AMQQueueFactory.java | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/java/broker/src/main/java/org/apache/qpid/server/configuration/QueueConfiguration.java b/java/broker/src/main/java/org/apache/qpid/server/configuration/QueueConfiguration.java index 30bf8aba5d..e6c5dee90d 100644 --- a/java/broker/src/main/java/org/apache/qpid/server/configuration/QueueConfiguration.java +++ b/java/broker/src/main/java/org/apache/qpid/server/configuration/QueueConfiguration.java @@ -114,7 +114,7 @@ public class QueueConfiguration public long getMemoryUsageMaximum() { - return _config.getLong("maximumMemoryUsage", -1); + return _config.getLong("maximumMemoryUsage", 100 * 1024 * 1024); //100Meg } public long getMemoryUsageMinimum() diff --git a/java/broker/src/main/java/org/apache/qpid/server/queue/AMQQueueFactory.java b/java/broker/src/main/java/org/apache/qpid/server/queue/AMQQueueFactory.java index a2b514af68..6ba22321f1 100644 --- a/java/broker/src/main/java/org/apache/qpid/server/queue/AMQQueueFactory.java +++ b/java/broker/src/main/java/org/apache/qpid/server/queue/AMQQueueFactory.java @@ -89,7 +89,7 @@ public class AMQQueueFactory "Queue create request with negative size:" + queueSize, null); } - q.setMaximumMessageSize(queueSize); + q.setMemoryUsageMaximum(queueSize); } else { |
