summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorMatthew Sackman <matthew@lshift.net>2009-11-09 17:10:28 +0000
committerMatthew Sackman <matthew@lshift.net>2009-11-09 17:10:28 +0000
commite16ec9889f9c693484013167c65e8454157dbba7 (patch)
tree41e6cab521525e8c8a397edc8d33d0c82a146418 /include
parent5fd1c1493c488631c56d180117c055c2f23ddb7c (diff)
downloadrabbitmq-server-git-e16ec9889f9c693484013167c65e8454157dbba7.tar.gz
Wrote specific test of the case mentioned in previous commit, and fixed code accordingly. Also added some other tests. With the overal test suite, up to 92% code coverage of vq, and 70% on prefetcher. Also factored out common records between those two modules to rabbit_queue.hrl
Diffstat (limited to 'include')
-rw-r--r--include/rabbit_queue.hrl51
1 files changed, 51 insertions, 0 deletions
diff --git a/include/rabbit_queue.hrl b/include/rabbit_queue.hrl
new file mode 100644
index 0000000000..5833b05683
--- /dev/null
+++ b/include/rabbit_queue.hrl
@@ -0,0 +1,51 @@
+%% The contents of this file are subject to the Mozilla Public License
+%% Version 1.1 (the "License"); you may not use this file except in
+%% compliance with the License. You may obtain a copy of the License at
+%% http://www.mozilla.org/MPL/
+%%
+%% Software distributed under the License is distributed on an "AS IS"
+%% basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
+%% License for the specific language governing rights and limitations
+%% under the License.
+%%
+%% The Original Code is RabbitMQ.
+%%
+%% The Initial Developers of the Original Code are LShift Ltd,
+%% Cohesive Financial Technologies LLC, and Rabbit Technologies Ltd.
+%%
+%% Portions created before 22-Nov-2008 00:00:00 GMT by LShift Ltd,
+%% Cohesive Financial Technologies LLC, or Rabbit Technologies Ltd
+%% are Copyright (C) 2007-2008 LShift Ltd, Cohesive Financial
+%% Technologies LLC, and Rabbit Technologies Ltd.
+%%
+%% Portions created by LShift Ltd are Copyright (C) 2007-2009 LShift
+%% Ltd. Portions created by Cohesive Financial Technologies LLC are
+%% Copyright (C) 2007-2009 Cohesive Financial Technologies
+%% LLC. Portions created by Rabbit Technologies Ltd are Copyright
+%% (C) 2007-2009 Rabbit Technologies Ltd.
+%%
+%% All Rights Reserved.
+%%
+%% Contributor(s): ______________________________________.
+%%
+
+-record(alpha,
+ { msg,
+ seq_id,
+ is_delivered,
+ msg_on_disk,
+ index_on_disk
+ }).
+
+-record(beta,
+ { msg_id,
+ seq_id,
+ is_persistent,
+ is_delivered,
+ index_on_disk
+ }).
+
+-record(gamma,
+ { seq_id,
+ count
+ }).