AMQP_1.0_PR2学习笔记

本文深入解析了AMQP(高级消息队列协议)的核心概念,包括消息、节点、链接、信用机制、容器、会话及交易等内容,阐述了AMQP如何确保消息在网络中可靠有序地传输。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

Message

bare message:发送端发送的消息。

annotated message:接收端接收的消息。

A Node is a named source and/or sink of Messages

Links may be “destructive”, or “non-destructive”.

Links may have entry criteria (Filters)。

Duplicate deliveries should be discarded.

If the node at either end of the link is deleted, so is the link itself.

 

Credit

A link with no credit is impassable.

Sending a message irrevocably consumes the credit.

Receivers of messages can add or remove multiple units of credit at any time.

Credit is used to ensure that nodes do not receive more messages than they can physically store.

 

Containers

Nodes within the AMQP network exist within Containers.

A container is a physical or logical process to which network connections can be established.

 

Sessions

A Session is a named interaction between two containers providing for a pair of reliable ordered command streams (one in each direction).

 

Containers and Sessions form an underlay network, nodes and links an overlay network atop them.

 

Commands

 

Sessions are a transport for commands.

Commands are the atomic units of work of the AMQP transport protocol.

Commands are used to create links between nodes in the source and destination containers, to transfer message data, and to issue and revoke credit.

Should a command fail for some reason, then the sender of the command will be notified as to the last successfully executed command.

No command after the failed command will be executed.

 

Transactions

The AMQP specification defines a transactional container as one that is capable of performing addition/removal of multiple messages to/from nodes in a single atomic action.

In any given session, at most one peer may act as the transactional container. The other peer is the transaction controller.

The transaction mode is controlled at the session level, set at the time of session creation, and cannot thereafter be modified.

Container, controller. coordinator

Only the addition/removal of messages to/from nodes are affected by transactions, other state changes such as the creation or deletion of links, and the issuance of credit, are not.

转载于:https://www.cnblogs.com/shuaifeng/archive/2010/04/09/1707929.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值