Documentation
¶
Index ¶
- Variables
- func CheckExchangeOrQueueName(s string) error
- func EquivalentTables(t1 *Table, t2 *Table) bool
- func ReadLong(buf io.Reader) (data uint32, err error)
- func ReadLonglong(buf io.Reader) (data uint64, err error)
- func ReadLongstr(buf io.Reader) ([]byte, error)
- func ReadOctet(buf io.Reader) (data byte, err error)
- func ReadShort(buf io.Reader) (data uint16, err error)
- func ReadShortstr(buf io.Reader) (string, error)
- func ReadTimestamp(buf io.Reader) (uint64, error)
- func WriteFrame(buf io.Writer, frame *WireFrame)
- func WriteFrameEnd(buf io.Writer) error
- func WriteLong(buf io.Writer, i uint32) error
- func WriteLonglong(buf io.Writer, i uint64) error
- func WriteLongstr(buf io.Writer, bytes []byte) (err error)
- func WriteOctet(buf io.Writer, b byte) error
- func WriteProtocolHeader(buf io.Writer) error
- func WriteShort(buf io.Writer, i uint16) error
- func WriteShortstr(buf io.Writer, s string) error
- func WriteStringChar(buf io.Writer, b byte) error
- func WriteTable(writer io.Writer, table *Table) error
- func WriteTimestamp(buf io.Writer, timestamp uint64) error
- func WriteVersion(buf io.Writer) error
- type AMQPError
- type Frame
- type MessageResourceHolder
- type MethodFrame
Constants ¶
This section is empty.
Variables ¶
var AccessRefused = 403
The client attempted to work with a server entity to which it has no access due to security settings.
var ChannelError = 504
The client attempted to work with a channel that had not been correctly opened. This most likely indicates a fault in the client layer.
var ClassIdBasic uint16 = 60
var ClassIdChannel uint16 = 20
var ClassIdConfirm uint16 = 85
var ClassIdConnection uint16 = 10
var ClassIdExchange uint16 = 40
var ClassIdQueue uint16 = 50
var ClassIdTx uint16 = 90
var CommandInvalid = 503
The client sent an invalid sequence of frames, attempting to perform an operation that was considered invalid by the server. This usually implies a programming error in the client.
var ConnectionForced = 320
An operator intervened to close the connection for some reason. The client may retry at some later date.
var ContentTooLarge = 311
The client attempted to transfer content larger than the server could accept at the present time. The client may retry at a later time.
var FrameBody = 3
var FrameEnd = 206
var FrameError = 501
The sender sent a malformed frame that the recipient could not decode. This strongly implies a programming error in the sending peer.
var FrameHeader = 2
var FrameHeartbeat = 8
var FrameMethod = 1
var FrameMinSize = 4096
var InternalError = 541
The server could not complete the method because of an internal error. The server may require intervention by an operator in order to resume normal operations.
var InvalidPath = 402
The client tried to work with an unknown virtual host.
var MaskAppId uint16 = 0x0008
var MaskContentEncoding uint16 = 0x4000
var MaskContentType uint16 = 0x8000
var MaskCorrelationId uint16 = 0x0400
var MaskDeliveryMode uint16 = 0x1000
var MaskExpiration uint16 = 0x0100
var MaskHeaders uint16 = 0x2000
var MaskMessageId uint16 = 0x0080
var MaskPriority uint16 = 0x0800
var MaskReplyTo uint16 = 0x0200
var MaskReserved uint16 = 0x0004
var MaskTimestamp uint16 = 0x0040
var MaskType uint16 = 0x0020
var MaskUserId uint16 = 0x0010
var MaxShortStringLength uint8 = 255
var MethodIdBasicAck uint16 = 80
************************ BasicAck ************************
var MethodIdBasicCancel uint16 = 30
************************ BasicCancel ************************
var MethodIdBasicCancelOk uint16 = 31
************************ BasicCancelOk ************************
var MethodIdBasicConsume uint16 = 20
************************ BasicConsume ************************
var MethodIdBasicConsumeOk uint16 = 21
************************ BasicConsumeOk ************************
var MethodIdBasicDeliver uint16 = 60
************************ BasicDeliver ************************
var MethodIdBasicGet uint16 = 70
************************ BasicGet ************************
var MethodIdBasicGetEmpty uint16 = 72
************************ BasicGetEmpty ************************
var MethodIdBasicGetOk uint16 = 71
************************ BasicGetOk ************************
var MethodIdBasicNack uint16 = 120
************************ BasicNack ************************
var MethodIdBasicPublish uint16 = 40
************************ BasicPublish ************************
var MethodIdBasicQos uint16 = 10
************************ BasicQos ************************
var MethodIdBasicQosOk uint16 = 11
************************ BasicQosOk ************************
var MethodIdBasicRecover uint16 = 110
************************ BasicRecover ************************
var MethodIdBasicRecoverAsync uint16 = 100
************************ BasicRecoverAsync ************************
var MethodIdBasicRecoverOk uint16 = 111
************************ BasicRecoverOk ************************
var MethodIdBasicReject uint16 = 90
************************ BasicReject ************************
var MethodIdBasicReturn uint16 = 50
************************ BasicReturn ************************
var MethodIdChannelClose uint16 = 40
************************ ChannelClose ************************
var MethodIdChannelCloseOk uint16 = 41
************************ ChannelCloseOk ************************
var MethodIdChannelFlow uint16 = 20
************************ ChannelFlow ************************
var MethodIdChannelFlowOk uint16 = 21
************************ ChannelFlowOk ************************
var MethodIdChannelOpen uint16 = 10
************************ ChannelOpen ************************
var MethodIdChannelOpenOk uint16 = 11
************************ ChannelOpenOk ************************
var MethodIdConfirmSelect uint16 = 10
************************ ConfirmSelect ************************
var MethodIdConfirmSelectOk uint16 = 11
************************ ConfirmSelectOk ************************
var MethodIdConnectionBlocked uint16 = 60
************************ ConnectionBlocked ************************
var MethodIdConnectionClose uint16 = 50
************************ ConnectionClose ************************
var MethodIdConnectionCloseOk uint16 = 51
************************ ConnectionCloseOk ************************
var MethodIdConnectionOpen uint16 = 40
************************ ConnectionOpen ************************
var MethodIdConnectionOpenOk uint16 = 41
************************ ConnectionOpenOk ************************
var MethodIdConnectionSecure uint16 = 20
************************ ConnectionSecure ************************
var MethodIdConnectionSecureOk uint16 = 21
************************ ConnectionSecureOk ************************
var MethodIdConnectionStart uint16 = 10
************************ ConnectionStart ************************
var MethodIdConnectionStartOk uint16 = 11
************************ ConnectionStartOk ************************
var MethodIdConnectionTune uint16 = 30
************************ ConnectionTune ************************
var MethodIdConnectionTuneOk uint16 = 31
************************ ConnectionTuneOk ************************
var MethodIdConnectionUnblocked uint16 = 61
************************ ConnectionUnblocked ************************
var MethodIdExchangeBind uint16 = 30
************************ ExchangeBind ************************
var MethodIdExchangeBindOk uint16 = 31
************************ ExchangeBindOk ************************
var MethodIdExchangeDeclare uint16 = 10
************************ ExchangeDeclare ************************
var MethodIdExchangeDeclareOk uint16 = 11
************************ ExchangeDeclareOk ************************
var MethodIdExchangeDelete uint16 = 20
************************ ExchangeDelete ************************
var MethodIdExchangeDeleteOk uint16 = 21
************************ ExchangeDeleteOk ************************
var MethodIdExchangeUnbind uint16 = 40
************************ ExchangeUnbind ************************
var MethodIdExchangeUnbindOk uint16 = 51
************************ ExchangeUnbindOk ************************
var MethodIdQueueBind uint16 = 20
************************ QueueBind ************************
var MethodIdQueueBindOk uint16 = 21
************************ QueueBindOk ************************
var MethodIdQueueDeclare uint16 = 10
************************ QueueDeclare ************************
var MethodIdQueueDeclareOk uint16 = 11
************************ QueueDeclareOk ************************
var MethodIdQueueDelete uint16 = 40
************************ QueueDelete ************************
var MethodIdQueueDeleteOk uint16 = 41
************************ QueueDeleteOk ************************
var MethodIdQueuePurge uint16 = 30
************************ QueuePurge ************************
var MethodIdQueuePurgeOk uint16 = 31
************************ QueuePurgeOk ************************
var MethodIdQueueUnbind uint16 = 50
************************ QueueUnbind ************************
var MethodIdQueueUnbindOk uint16 = 51
************************ QueueUnbindOk ************************
var MethodIdTxCommit uint16 = 20
************************ TxCommit ************************
var MethodIdTxCommitOk uint16 = 21
************************ TxCommitOk ************************
var MethodIdTxRollback uint16 = 30
************************ TxRollback ************************
var MethodIdTxRollbackOk uint16 = 31
************************ TxRollbackOk ************************
var MethodIdTxSelect uint16 = 10
************************ TxSelect ************************
var MethodIdTxSelectOk uint16 = 11
************************ TxSelectOk ************************
var NoConsumers = 313
When the exchange cannot deliver to a consumer when the immediate flag is set. As a result of pending data on the queue or the absence of any consumers of the queue.
var NotAllowed = 530
The client tried to work with some entity in a manner that is prohibited by the server, due to security settings or by some other criteria.
var NotFound = 404
The client attempted to work with a server entity that does not exist.
var NotImplemented = 540
The client tried to use functionality that is not implemented in the server.
var PreconditionFailed = 406
The client requested a method that was not allowed because some precondition failed.
var ReadClassId = ReadShort
var ReadConsumerTag = ReadShortstr
var ReadDeliveryTag = ReadLonglong
var ReadExchangeName = ReadShortstr
var ReadMessageCount = ReadLong
var ReadMethodId = ReadShort
var ReadPath = ReadShortstr
var ReadPeerProperties = ReadTable
var ReadQueueName = ReadShortstr
var ReadReplyCode = ReadShort
var ReadReplyText = ReadShortstr
var ReplySuccess = 200
Indicates that the method completed successfully. This reply code is reserved for future use - the current protocol design does not use positive confirmation and reply codes are sent only in case of an error.
var ResourceError = 506
The server could not complete the method because it lacked sufficient resources. This may be due to the client creating too many of some type of entity.
var ResourceLocked = 405
The client attempted to work with a server entity to which it has no access because another client is working with it.
var SyntaxError = 502
The sender sent a frame that contained illegal values for one or more fields. This strongly implies a programming error in the sending peer.
var UnexpectedFrame = 505
The peer sent a frame that was not expected, usually in the context of a content header and body. This strongly indicates a fault in the peer's content processing.
var WriteClassId = WriteShort
var WriteConsumerTag = WriteShortstr
var WriteDeliveryTag = WriteLonglong
var WriteExchangeName = WriteShortstr
var WriteMessageCount = WriteLong
var WriteMethodId = WriteShort
var WritePath = WriteShortstr
var WritePeerProperties = WriteTable
var WriteQueueName = WriteShortstr
var WriteReplyCode = WriteShort
var WriteReplyText = WriteShortstr
Functions ¶
func EquivalentTables ¶
func EquivalentTables(t1 *Table, t2 *Table) bool
func ReadTimestamp ¶
Can't get coverage on this easily since I can't currently generate timestamp values in Tables because protobuf doesn't give me a type that is different from uint64
func WriteFrame ¶
func WriteFrameEnd ¶
func WriteProtocolHeader ¶
func WriteTable ¶
func WriteVersion ¶
Types ¶
type AMQPError ¶
func NewHardError ¶
type MessageResourceHolder ¶
type MessageResourceHolder interface { AcquireResources(qm *QueueMessage) bool ReleaseResources(qm *QueueMessage) }
A message resource is something which has limits on the count of messages it can handle as well as the cumulative size of the messages it can handle.
type MethodFrame ¶
type MethodFrame interface { MethodName() string MethodIdentifier() (uint16, uint16) Read(reader io.Reader, strictMode bool) (err error) Write(writer io.Writer) (err error) FrameType() byte }
func ReadMethod ¶
func ReadMethod(reader io.Reader, strictMode bool) (MethodFrame, error)