class LavinMQ::Queue

Included Modules

Direct Known Subclasses

Defined in:

lavinmq/queue/message_store.cr
lavinmq/queue/queue.cr

Constructors

Class Method Summary

Instance Method Summary

Instance methods inherited from module LavinMQ::SortableJSON

details_tuple details_tuple, to_json(json : JSON::Builder) to_json

Instance methods inherited from module Observable

notify_observers(event : Symbol, data : Object | Nil = nil) notify_observers, register_observer(observer : Observer) register_observer, unregister_observer(observer : Observer) unregister_observer

Instance methods inherited from module LavinMQ::PolicyTarget

apply_policy(policy : Policy | Nil, operator_policy : OperatorPolicy | Nil) apply_policy, clear_policy clear_policy, operator_policy : OperatorPolicy | Nil operator_policy, policy : Policy | Nil policy

Constructor Detail

def self.new(vhost : VHost, name : String, exclusive : Bool = false, auto_delete : Bool = false, arguments : AMQ::Protocol::Table = AMQP::Table.new) #

[View source]

Class Method Detail

def self.generate_name #

[View source]

Instance Method Detail

def ack(sp : SegmentPosition) : Nil #

[View source]
def ack_count : UInt64 #

Creates @[x]_count and @[x]_rate and @[y]_log


def add_consumer(consumer : Client::Channel::Consumer) #

[View source]
def apply_policy(policy : Policy | Nil, operator_policy : OperatorPolicy | Nil) #

[View source]
def arguments : AMQ::Protocol::Table #

[View source]
def auto_delete? : Bool #

[View source]
def basic_get(no_ack, force = false, & : Envelope -> Nil) : Bool #

[View source]
def bindings #

[View source]
def close : Bool #

[View source]
def closed? : Bool #

[View source]
def confirm_count : UInt64 #

Creates @[x]_count and @[x]_rate and @[y]_log


def consume_get(consumer, & : Envelope -> Nil) : Bool #

If nil is returned it means that the delivery limit is reached


[View source]
def consumer_count #

[View source]
def consumer_timeout : UInt64 | Nil #

[View source]

[View source]
def current_stats_details #

Like stats_details but without log


[View source]
def delete : Bool #

[View source]
def deliver_count : UInt64 #

Creates @[x]_count and @[x]_rate and @[y]_log


def details_tuple #

[View source]
def durable? #

[View source]
def empty? : Bool #

[View source]
def empty_change : Channel(Bool) #

[View source]
def exclusive? : Bool #

[View source]
def get_count : UInt64 #

Creates @[x]_count and @[x]_rate and @[y]_log


def get_no_ack_count : UInt64 #

Creates @[x]_count and @[x]_rate and @[y]_log


def has_exclusive_consumer? : Bool #

[View source]
def has_priority_consumers? : Bool #

[View source]
def immediate_delivery? #

[View source]
def in_use? #

[View source]
def inspect(io : IO) #
Description copied from class Reference

Appends a String representation of this object which includes its class name, its object address and the values of all instance variables.

class Person
  def initialize(@name : String, @age : Int32)
  end
end

Person.new("John", 32).inspect # => #<Person:0x10fd31f20 @name="John", @age=32>

[View source]
def last_get_time : Time::Span #

[View source]
def match?(durable, exclusive, auto_delete, arguments) #

[View source]
def match?(frame) #

[View source]
def message_count #

[View source]
def message_count_log : Deque(UInt32) #

Creates @[x]_count and @[x]_rate and @[y]_log


def name : String #

[View source]
def operator_policy : OperatorPolicy | Nil #

[View source]
def pause! #

[View source]
def paused? : Bool #

[View source]
def paused_change : Channel(Bool) #

[View source]
def policy : Policy | Nil #

[View source]
def publish(msg : Message) : Bool #

[View source]
def publish_count : UInt64 #

Creates @[x]_count and @[x]_rate and @[y]_log


def purge(max_count : Int = UInt32::MAX) : UInt32 #

[View source]
def purge_and_close_consumers : UInt32 #

[View source]
def read(sp : SegmentPosition) : Envelope #

Used for when channel recovers without requeue eg. redelivers messages it already has unacked


[View source]
def redeclare #

[View source]
def redeliver_count : UInt64 #

Creates @[x]_count and @[x]_rate and @[y]_log


def reject(sp : SegmentPosition, requeue : Bool) #

[View source]
def reject_count : UInt64 #

Creates @[x]_count and @[x]_rate and @[y]_log


def resume! #

[View source]
def return_unroutable_count : UInt64 #

Creates @[x]_count and @[x]_rate and @[y]_log


def rm_consumer(consumer : Client::Channel::Consumer) #

[View source]
def single_active_consumer : Client::Channel::Consumer | Nil #

[View source]
def single_active_consumer_change : Channel(LavinMQ::Client::Channel::Consumer) #

[View source]
def state : LavinMQ::QueueState #

[View source]
def stats_details #

Creates @[x]_count and @[x]_rate and @[y]_log


[View source]
def to_json(json : JSON::Builder, consumer_limit : Int32 = -1) #

[View source]
def unacked_bytesize : UInt64 #

[View source]
def unacked_count : UInt32 #

[View source]
def unacked_count_log : Deque(UInt32) #

Creates @[x]_count and @[x]_rate and @[y]_log


def update_rates : Nil #

Creates @[x]_count and @[x]_rate and @[y]_log


[View source]
def vhost : LavinMQ::VHost #

[View source]