msgstore

package
v0.0.0-...-72a54ad Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 13, 2018 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var MESSAGE_CONTENT_BUCKET = []byte("message_content")
View Source
var MESSAGE_INDEX_BUCKET = []byte("message_index")

Functions

This section is empty.

Types

type IndexMessageFactory

type IndexMessageFactory struct{}

func (*IndexMessageFactory) New

type MessageContentFactory

type MessageContentFactory struct{}

func (*MessageContentFactory) New

type MessageStore

type MessageStore struct {
	// contains filtered or unexported fields
}

func NewMessageStore

func NewMessageStore(fileName string) (*MessageStore, error)

func (*MessageStore) AddMessage

func (ms *MessageStore) AddMessage(msg *amqp.Message, queues []string) (map[string][]*amqp.QueueMessage, error)

func (*MessageStore) AddTxMessages

func (ms *MessageStore) AddTxMessages(msgs []*amqp.TxMessage) (map[string][]*amqp.QueueMessage, error)

func (*MessageStore) Fsck

func (ms *MessageStore) Fsck() ([]int64, []int64)

func (*MessageStore) Get

func (*MessageStore) GetAndDecrRef

func (ms *MessageStore) GetAndDecrRef(qm *amqp.QueueMessage, queueName string, rhs []amqp.MessageResourceHolder) (*amqp.Message, error)

func (*MessageStore) GetIndex

func (ms *MessageStore) GetIndex(id int64) (msg *amqp.IndexMessage, found bool)

func (*MessageStore) GetNoChecks

func (ms *MessageStore) GetNoChecks(id int64) (msg *amqp.Message, found bool)

func (*MessageStore) IncrDeliveryCount

func (ms *MessageStore) IncrDeliveryCount(queueName string, qm *amqp.QueueMessage) (err error)

func (*MessageStore) IndexCount

func (ms *MessageStore) IndexCount() int

func (*MessageStore) LoadMessages

func (ms *MessageStore) LoadMessages() error

func (*MessageStore) LoadQueueFromDisk

func (ms *MessageStore) LoadQueueFromDisk(queueName string) (*list.List, error)

func (*MessageStore) MessageCount

func (ms *MessageStore) MessageCount() int

func (*MessageStore) RemoveRef

func (ms *MessageStore) RemoveRef(qm *amqp.QueueMessage, queueName string, rhs []amqp.MessageResourceHolder) error

func (*MessageStore) Start

func (ms *MessageStore) Start()

type PersistKey

type PersistKey struct {
	// contains filtered or unexported fields
}

type QueueMessageFactory

type QueueMessageFactory struct{}

func (*QueueMessageFactory) New

type TestResourceHolder

type TestResourceHolder struct {
}

func (*TestResourceHolder) AcquireResources

func (trh *TestResourceHolder) AcquireResources(qm *amqp.QueueMessage) bool

func (*TestResourceHolder) ReleaseResources

func (trh *TestResourceHolder) ReleaseResources(qm *amqp.QueueMessage)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL