Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3
Info
titleNote

This page is being updated with protocol changes introduced in M4 (and are unchanged in release 0.5)

...

Protocol Header

The body segments of management QMF messages are composed of sequences of binary-encoded data fields, in a manner consistent with the 0-10 version of the AMQP specification.

All management QMF messages begin with a message header:

No Format
          octet 0      1         2         3         4         5         6         7
        +---------+---------+---------+---------+---------+---------+---------+---------+
        |   'A'   |   'M'   |   '12'   | op-code |                sequence               |
        +---------+---------+---------+---------+---------+---------+---------+---------+

The first three octets contain the protocol magic number "AM1AM2" which is used to identify the type and version of the message.

The opcode field identifies the operation represented by the message

Mapping QMF Messages to AMQP Messages

QMF messages are carried in the body segments of AMQP messages. An AMQP message body may contain 1 or more QMF messages. QMF messages do not span AMQP messages, each QMF messages must be entirely contained within a single AMQP message body.

Protocol Exchange Patterns

...

Manageable objects are tagged with a unique 64128-bit object identifier. The object identifier space is owned and managed by the management broker. Objects managed by a single management broker shall have unique object identifiers. Objects managed by separate management brokers may have the same object identifier.

If a management console is designed to manage multiple management brokers, it must use the broker identifier as well as the object identifier to ensure global uniqueness.

No Format
first uint64:
         63   6260 59              48 47                   28 27      24 23                    0
        +-------+------------------+-----------------------+-------------------------+
-----+
        |0 flags |     sequence  |   |      broker bank      |    |      agent bank object         |
        +-------+------------------+-----------------------+------------------------------+

second uint64:
       bit  63        - reserved, must be zero
                                   bits 63 .. 48  - broker boot sequence (32K)
        bits 47 .. 24  - bank (16M)
        bits 23 .. 0
   -    object (16M)
  • For persistent IDs, boot-sequence is zero
  • For non-persistent IDs, boot sequence is a constant number which increments each time the management broker is restarted.
  • Bank number:
    • 0 - reserved
    • 1 - broker-persistent objects
    • 2..4 - store-persistent objects
    • > 4 - transient objects

Establishing Communication Between Client and Agent

Communication is established between the management client and management agent using normal AMQP procedures. The client creates a connection to the broker and then establishes a session with its corresponding channel.

Two private queues are then declared (only one if method invocation is not needed). A management queue is declared and bound to the qpid.management exchange. If the binding key is "mgmt.#", all management-related messages sent to the exchange will be received by this client. A more specific binding key will result in a more restricted set of messages being received (see the section on Routing Key Structure below).

If methods are going to be invoked on managed objects, a second private queue must be declared so the client can receive method replies. This queue is bound to the amq.direct exchange using a routing key equal to the name of the queue.

When a client successfully binds to the qpid.management exchange, the management agent schedules a schema broadcast to be sent to the exchange. The agent will publish, via the exchange, a description of the schema for all manageable objects in its control.

No Format

 +---------------------------------------------------------------------------------+
        |        Client                             object                             Broker
        |                                                               |
        | +----- AMQP Connection and Session Setup -----------------------------> |
        |                                                               |
        | --- Queue.declare (private data queue) ---------------------> |
        | --- Bind queue to exchange 'qpid.management' key 'mgmt.#' --> |
        |                                                               |
        | --- Queue.declare (private method-reply queue) --------------------+

Field

Size (bits)

Description

flags

4

Reserved, must be zero

sequence

12

Boot sequence of the agent, or zero for persistent IDs

broker bank

20

Bank number unique to the broker

agent bank

28

Bank number unique to the agent

object

64

Identifier assigned by the agent

  • For persistent IDs, sequence is zero
  • For non-persistent IDs, sequence is a number which increments each time the management broker is restarted.

Establishing Communication Between Client and Agent

Communication is established between the management client and management agent using normal AMQP procedures. The client creates a connection to the broker and then establishes a session with its corresponding channel.

A private (exclusive/auto-delete) queue is then declared and bound to the qpid.management exchange. A binding with key "schema.#" will subscribe to all schema-related information and a second binding with key "console.#" will subscribe to all management data.

A binding must also be established to the "amq.direct" exchange using the queue's name as the binding key. This will be used as a reply-to address for requests sent to the broker and to agents.

When a client successfully binds to the qpid.management exchange, the management agent schedules a schema broadcast to be sent to the exchange. The agent will publish, via the exchange, a description of the schema for all manageable objects in its control.

No Format

      Client         > |
        | --- Bind queue to exchange 'amq.direct' --------------------> |
        |                                                               |
        | --- Broker Request -----------------------------------------> |
        | <---------------------------------------- Broker Response --- |
        |                                            Broker
        |           |
        |                                               |
        | --- AMQP Connection and Session Setup -------------------------> |
        |                                                                  |
        | <--- Queue.declare (private data queue) ------------------------> |
        | --- ManagementBind schemaqueue viato exchange 'qpid.management' key 'schema.#' ---> |
        | --- Bind queue to exchange 'qpid.management' key 'console.#' --> |
        | --- Bind queue to exchange 'amq.direct' -----------------------> |
        |                               |

Broadcast of Configuration and Instrumentation Updates

The management agent will periodically publish updates to the configuration and instrumentation of management objects under its control. Under normal circumstances, these updates are published only if they have changed since the last time they were published. Configuration updates are only published if configuration has changed and instrumentation updates are only published if instrumentation has changed. The exception to this rule is that after a management client binds to the qpid.management exchange, all configuration and instrumentation records are published as though they had changed whether or not they actually did.

No Format

         Client                          |
                                Broker
   | --- Broker Request --------------------------------------------> |
        | <------------------------------------------- Broker Response --- |
        |                                                  |
        | <------------------ Object properties via 'mgmt.*.prop.#' --- | |
        | <------------------ Object statistics via 'mgmt.*.stat.#' --- | |
        |                                                               | |
        |                                                               | | Publish Interval|
        | <---------- Management schema via exchange 'qpid.management' --- |
                                                       | |
        |                                                               |

Broadcast of Configuration and Instrumentation Updates

The management agent will periodically publish updates to the configuration and instrumentation of management objects under its control. Under normal circumstances, these updates are published only if they have changed since the last time they were published. Configuration updates are only published if configuration has changed and instrumentation updates are only published if instrumentation has changed. The exception to this rule is that after a management client binds to the qpid.management exchange, all configuration and instrumentation records are published as though they had changed whether or not they actually did.

No Format

  Client |
        |                                                               | V
    Broker
    | <------------------ Object properties via 'mgmt.*.prop.#' --- |
        | <------------------ Object statistics via 'mgmt.*.stat.#' --- |
        |                                                 |
    | <--- Object properties via 'console.obj.1.<agent-bank>.<package>.<class>' --- | |
    |

Invoking a Method on a Managed Object

When the management client wishes to invoke a method on a managed object, it sends a method request message to the qpid.management exchange. The routing key contains the object class and method name (refer to Routing Key Structure below). The method request must have a header entry (reply-to) that contains the name of the method-reply queue so that the method response can be properly routed back to the requestor.

The method request contains a sequence number that is copied to the method reply. This number is opaque to the management agent and may be used by the management client to correlate the reply to the request. The asynchronous nature of requests and replies allows any number of methods to be in-flight at a time. Note that there is no guarantee that methods will be replied to in the order in which they were requested.

No Format

 <--- Object statistics via 'console.obj.1.<agent-bank>.<package>.<class>' --- | |
    |                  Client                                                          Broker
   | |
    |                                                                |
        | --- Method Request (to exchange 'qpid.management') ---------> | | Publish
    |        |                                                                       | | Interval
    |    |                                                                    |
       | | <--------------- Method Reply (via exchange 'amq.direct') --- |

    |                |                                                               |

Messages for the Basic Scenario

The principals in a management exchange are the management client and the management agent. The management agent is integrated into the QPID broker and the management client is a remote entity. A management agent may be managed by zero or more management clients at any given time. Additionally, a management client may manage multiple management agents at the same time.

For authentication and access control, management relies on the mechanisms supplied by the AMQP protocol.

Basic Opcodes

opcode

message

description

'B'

Broker Request

This message contains a broker request, sent from the management console to the broker to initiate a management session.

'b'

Broker Response

This message contains a broker response, sent from the broker in response to a broker request message.

'z'

Command Completion

This message is sent to indicate the completion of a request.

'Q'

Class Query

Class query messages are used by a management console to request a list of schema classes that are known by the management broker.

'q'

Class Indication

Sent by the management broker, a class indication notifies the peer of the existence of a schema class.

'S'

Schema Request

Schema request messages are used to request the full schema details for a class.

's'

Schema Response

Schema response message contain a full description of the schema for a class.

'h'

Heartbeat Indication

This message is published once per publish-interval. It can be used by a client to positively determine which objects did not change during the interval (since updates are not published for objects with no changes).

'c', 'i', 'g'

Content Indication

This message contains a content record. Content records contain the values of all properties or statistics in an object. Such records are broadcast on a periodic interval if 1) a change has been made in the value of one of the elements, or 2) if a new management client has bound a queue to the management exchange.

'G'

Get Query

Sent by a management console, a get query requests that the management broker provide content indications for all objects that match the query criteria.

'M'

Method Request

This message contains a method request.

'm'

Method Response

This message contains a method result.

Broker Request Message

When a management client first establishes contact with the broker, it sends a Hello message to initiate the exchange.

 V
    | <--- Object properties via 'console.obj.1.<agent-bank>.<package>.<class>' --- |
    | <--- Object statistics via 'console.obj.1.<agent-bank>.<package>.<class>' --- |
    |                                                                               |

Invoking a Method on a Managed Object

When the management client wishes to invoke a method on a managed object, it sends a method request message to the qpid.management exchange. The routing key contains the object class and method name (refer to Routing Key Structure below). The method request must have a header entry (reply-to) that contains the name of the method-reply queue so that the method response can be properly routed back to the requestor.

The method request contains a sequence number that is copied to the method reply. This number is opaque to the management agent and may be used by the management client to correlate the reply to the request. The asynchronous nature of requests and replies allows any number of methods to be in-flight at a time. Note that there is no guarantee that methods will be replied to in the order in which they were requested.

No Format

      Client        
No Format

        +-----+-----+-----+-----+-----------------------+
        | 'A' | 'M' | '1' | 'B' |           0           |
        +-----+-----+    Broker
        |                                                               |
        | --- Method Request (to exchange 'qpid.management') --------+-----+-----------------------+

The Broker Request message has no payload.

Broker Response Message

When the broker receives a Broker Request message, it responds with a Broker Response message. This message contains an identifier unique to the broker.

No Format

-> |
        |              +-----+-----+-----+-----+-----------------------+
        | 'A' | 'M' | '1' | 'b' |           0           |
        +-----+-----+-----+-----+-----------------------+----------------------------+   |
        |  brokerId (uuid)                                                            |
        +| <----------------------------------------------------------------------------+

Command Completion Message

No Format

 Method Reply (via exchange 'amq.direct') --- |
        |                   +-----+-----+-----+-----+-----------------------+
        | 'A' | 'M' | '1' | 'z' |          seq          |
        +-----+-----+-----+-----+-----------------------+
        |  Completion Code      |
        +-----------------------+-----------------------------------------+
        |  Completion Text                                                |
        +-----------------------------------------------------------------+

Class Query

No Format

        +-----+-----+-----+-----+-----------------------+
        | 'A' | 'M' | '1' | 'Q' |          seq          |
        +-----+-----+-----+-----+-----------------------+----------+
        |  package name (str8)                                     |
        +----------------------------------------------------------+

Class Indication

|

Details of QMF Message Types

opcode

message

handled by

description

'B'

Broker Request

broker

This message contains a broker request, sent from the management console to the broker to initiate a management session.

'b'

Broker Response

console

This message contains a broker response, sent from the broker in response to a broker request message.

'z'

Command Completion

all

This message is sent to indicate the completion of a request.

'Q'

Class Query

broker, agent

Class query messages are used by a management console to request a list of schema classes that are known by the management broker.

'q'

Class Indication

console, broker

Sent by the management broker, a class indication notifies the peer of the existence of a schema class.

'S'

Schema Request

broker, agent

Schema request messages are used to request the full schema details for a class.

's'

Schema Response

console, broker

Schema response message contain a full description of the schema for a class.

'h'

Heartbeat Indication

console

This message is published once per publish-interval. It can be used by a client to positively determine which objects did not change during the interval (since updates are not published for objects with no changes).

'c', 'i', 'g'

Content Indication

console

This message contains a content record. Content records contain the values of all properties or statistics in an object. Such records are broadcast on a periodic interval if 1) a change has been made in the value of one of the elements, or 2) if a new management client has bound a queue to the management exchange.

'e'

Event Indication

console

This message contains an event indication, sent by an agent to the topic exchange qpid.management.

'G'

Get Query

agent

Sent by a management console, a get query requests that the management broker provide content indications for all objects that match the query criteria.

'M'

Method Request

agent

This message contains a method request.

'm'

Method Response

console

This message contains a method result.

'P'

Package Query

broker, agent

This message contains a schema package query request, requesting that the broker dump the list of known packages

'p'

Package Indication

console, broker

This message contains a schema package indication, identifying a package known by the broker

'A'

Agent Attach Request

broker

This message is sent by a remote agent when it wishes to attach to a management broker

'a'

Agent Attach Response

agent

The management broker sends this response if an attaching remote agent is permitted to join

'x'

Console Added Indication

agent

This message is sent to all remote agents by the management broker when a new console binds to the management exchange

Broker Request Message

When a management console first establishes contact with the broker, it sends a Broker Request message to initiate the exchange.

No Format

        routing_key: broker
        +-----+-----+
No Format

        +-----+-----+-----+-----+-----------------------+
        | 'A' | 'M' | '12' | 'qB' |           seq0           |
        +-----+-----+-----+-----+-----------------------+----------+
      

The Broker Request message has no payload.

Broker Response Message

When the broker receives a Broker Request message, it responds with a Broker Response message. This message contains an identifier unique to the broker.

No Format

    |  package name (str8)      routing_key: <reply_to                              |from request>
        +-----+-----+-----+-----+--------------------------------------+
        | 'A' class| name (str8)    'M' | '2' | 'b' |               0                    |
        +-----+-----+-----+-----+-----------------------+----------------+------------+
        |  schema hash (bin128) brokerId (uuid)                                                            |
        +----------------------------------------------------------------------------+

...

Command Completion Message

No Format
        routing_key: <reply_to from request>
        +-----+-----+-----+-----+-----------------------+
        | 'A' | 'M' | '12' | 'Sz' |          seq          |
        +-----+-----+-----+-----+----+-------------------+----------+
        |  Completion              packageName (str8Code (uint32)  |
                      |
        ++----------------------------+------------------------------------+
        |  Completion Text (str8)              className (str8)                          |
        +-----------------------------------------------------------------+

Class Query

No Format
        | routing_key: broker
        +-----+-----+-----+-----+-----------------------+
         schema-hash (bin128)  | 'A' | 'M' | '2' | 'Q' |          seq          |
        +-----+-----+-----+-----+-----------------------+---------------+

Schema Response

No Format

+
        |   +-----+-----+-----+-----+-----------------------+
package name (str8)         | 'A' | 'M' | '1' | 's' |          seq          |
        +-----+----------+-----+-----+-----------------------+----------+

Class Indication

No Format

        |         routing_key: <reply_to from request> (if in reply to a request)
       packageName (str8)             schema.package          (if |unsolicited)
        +-----+-----+-----+----------+---------------------------------+
        | 'A' | 'M' | '2' | 'q' |        className (str8) seq          |
        +-----+-----+-----+-----+---------------+-------+
        | class kind (uint8) 1=Object, 2=Event  |
        +----------------------------------------+------------------+
        | package name (str8)               schema-hash (bin128)                      |
        +------------+--------------+-----------+-----------+----------+
        | propCnt   | statCntclass name (str8)                                   | methodCnt | eventCnt  |
        +-----------+-----------+-----------+-----------+----------------------------+
        | propCntschema property records   hash (bin128)                                                |
        +---------------------------------------------------------------------+

Schema Request

No Format
-------+
        | statCnt statistic recordsrouting_key: broker
         +-----+-----+-----+-----+-----------------------+
        | 'A' | 'M' | '2' | 'S' |          seq                 |
        +-----+-----+-----+-----+-----------------------+---------------------------------+
        | methodCnt method recordspackageName (str8)                                                   |
        +----------------------------------------------------------------------------+
        | eventCntclassName event(str8) records                                                     |
        +----------------------------------------------------------+
        | schema-hash (bin128)                                     |
        +---------------------+

Each property record is an AMQP map with the following fields. Optional fields may optionally be omitted from the map.

field name

optional

description

name

no

Name of the property

type

no

Type code for the property

access

no

Access code for the property

index

no

1 = index element, 0 = not an index element

optional

no

1 = optional element (may be not present), 0 = mandatory (always present)

unit

yes

Units for numeric values (i.e. seconds, bytes, etc.)

min

yes

Minimum value for numerics

max

yes

Maximum value for numerics

maxlen

yes

Maximum length for strings

desc

yes

Description of the property

Each statistic record is an AMQP map with the following fields:

field name

optional

description

name

no

Name of the statistic

type

no

Type code for the statistic

unit

yes

Units for numeric values (i.e. seconds, bytes, etc.)

desc

yes

Description of the statistic

method and event records contain a main map that describes the method or header followed by zero or more maps describing arguments. The main map contains the following fields:

field name

optional

description

name

no

Name of the method or event

argCount

no

Number of argument records to follow

desc

yes

Description of the method or event

Argument maps contain the following fields:

field name

method

event

optional

description

name

yes

yes

no

Argument name

type

yes

yes

no

Type code for the argument

dir

yes

no

yes

Direction code for method arguments

unit

yes

yes

yes

Units for numeric values (i.e. seconds, bytes, etc.)

min

yes

no

yes

Minimum value for numerics

max

yes

no

yes

Maximum value for numerics

maxlen

yes

no

yes

Maximum length for strings

desc

yes

yes

yes

Description of the argument

default

yes

no

yes

Default value for the argument

type codes are numerics with the following values:

value

type

1

uint8

2

uint16

3

uint32

4

uint64

6

str8

7

str16

8

absTime(uint64)

9

deltaTime(uint64)

10

objectReference(uint64)

11

boolean(uint8)

12

float

13

double

14

uuid

15

map

16

int8

17

int16

18

int32

19

int64

access codes are numerics with the following values:

value

access

1

Read-Create access

2

Read-Write access

3

Read-Only access

direction codes are numerics with the following values:

value

direction

1

Input (from client to broker)

2

Output (from broker to client)

3

IO (bidirectional)

Heartbeat Indication

No Format

        +-----+-----+-----+-----+-----------------------+
        | 'A' | 'M' | '1' | 'h' |           0           |
        +-----+-----+-----+-----+-----------------------+
        | timestamp of current interval (datetime)      |
        +-----------------------------------------------+

Configuration and Instrumentation Content Messages

Content messages are published when changes are made to the values of properties or statistics or when new management clients bind a queue to the management exchange.

-------------------------------------+

Schema Response

No Format

        routing_key: <reply_to from request> (if in reply to a request)
                     schema.package          (if unsolicited)
        +-----+-----+-----+-----+-----------------------+
        | 'A' | 'M' | '2' | 's' |          seq          |
        +-----+-----+-----+-----+------------+----------+
        | kind (uint8) 1=Object, 2=Event     |
        +------------------------------------+---------------------+
        | packageName (str8)                                       |
        +----------------------------------------------------------+
        | className (str8)                                         |
        +----------------------------------------------------------+
        | schema-hash (bin128)                                     |
        +-----------------------------------------------+----------+
        | propCount (uint16)                            |
        +-----------------------------------------------+
        | statCount (uint16)                            |
        +-----------------------------------------------+
        | methodCount (uint16)                          |
        +-----------------------------------------------+----------------------------+
        | propCount property records                                                 |
        +----------------------------------------------------------------------------+
        | statCount statistic records                                                |
        +----------------------------------------------------------------------------+
        | methodCount method records                                                 |
        +----------------------------------------------------------------------------+

Each property record is an AMQP map with the following fields. Optional fields may optionally be omitted from the map.

field name

optional

description

name

no

Name of the property

type

no

Type code for the property

refPackage

yes

Name of referenced package (for objectReference and object types)

refClass

yes

Name of referenced class (for objectReference and object types)

access

no

Access code for the property

index

no

1 = index element, 0 = not an index element

optional

no

1 = optional element (may be not present), 0 = mandatory (always present)

unit

yes

Units for numeric values (i.e. seconds, bytes, etc.)

min

yes

Minimum value for numerics

max

yes

Maximum value for numerics

maxlen

yes

Maximum length for strings

desc

yes

Description of the property

Each statistic record is an AMQP map with the following fields:

field name

optional

description

name

no

Name of the statistic

type

no

Type code for the statistic

unit

yes

Units for numeric values (i.e. seconds, bytes, etc.)

desc

yes

Description of the statistic

method records contain a main map that describes the method or header followed by zero or more maps describing arguments. The main map contains the following fields:

field name

optional

description

name

no

Name of the method or event

argCount

no

Number of argument records to follow

desc

yes

Description of the method or event

Argument maps contain the following fields:

field name

optional

description

name

no

Argument name

type

no

Type code for the argument

refPackage

yes

Name of referenced package (for objectReference and object types)

refClass

yes

Name of referenced class (for objectReference and object types)

dir

yes

Direction code for method arguments

unit

yes

Units for numeric values (i.e. seconds, bytes, etc.)

min

yes

Minimum value for numerics

max

yes

Maximum value for numerics

maxlen

yes

Maximum length for strings

desc

yes

Description of the argument

default

yes

Default value for the argument

type codes are numerics with the following values:

value

type

Encoding

1

uint8

uint8

2

uint16

uint16

3

uint32

uint32

4

uint64

uint64

6

str8

str8

7

str16

str16

8

absTime

uint64

9

deltaTime

uint64

10

objectReference

bin128

11

boolean

boolean

12

float

float

13

double

double

14

uuid

uuid

15

map

map

16

int8

int8

17

int16

int16

18

int32

int32

19

int64

int64

20

object

package-name(str8) + class-name(str8) + hash(bin128) + object-indication-encoding

21

list

list

22

array

array

access codes are numerics with the following values:

value

access

1

Read-Create access

2

Read-Write access

3

Read-Only access

direction codes are strings with the following values:

value

direction

"I"

Input (from client to broker)

"O"

Output (from broker to client)

"IO"

IO (bidirectional)

Heartbeat Indication

No Format

        routing_key: console.heartbeat.1.<agent_bank>
        +-----+-----+-----+-----+-----------------------+
        | 'A' | 'M' | '2' | 'h' |           0           |
        +-----+-----+-----+-----+-----------------------+
        | timestamp of current interval (datetime)      |
        +-----------------------------------------------+

Configuration and Instrumentation Content Messages

Content messages are published when changes are made to the values of properties or statistics or when new management clients bind a queue to the management exchange.

No Format

        for 'g':     routing_key: <reply_to from request>
        for 'c','i': routing_key: console.obj.1.<agent_bank>.<package_name>.<class_name>
        +-----+-----+-----+-------+-----------------------+
        | 'A' | 'M' | '2' |'g/c/i'|          seq          |
        +-----+-----+-----+-------+-----------------------+--------+
        |                packageName (str8)                        |
        +----------------------------------------------------------+
        |                className (str8)                          |
        +----------------------------------------------------------+
        |                class hash (bin128)                       |
        +-----+-----+-----+-----+-----+-----+-----+-----+----------+
        | timestamp of current sample (datetime)        |
        +-----+-----+-----+-----+-----+-----+-----+-----+
        | time object was created (datetime)            |
        +-----+-----+-----+-----+-----+-----+-----+-----+
        | time object was deleted (datetime)            |
        +-----+-----+-----+-----+-----+-----+-----+-----+
        | objectId (bin128)                             |
        +-----+-----+-----+-----+-----+-----+-----+-----+
        | presence bitmasks (0 or more uint8 fields)    |
        +-----+-----+-----+-----+-----+-----+-----+-----+------------------------+
        | config/inst values (in schema order)                                   |
        +------------------------------------------------------------------------+

All timestamps are uint64 values representing nanoseconds since the epoch (January 1, 1970). The objectId is a bin128 value that uniquely identifies this object instance.

If any of the properties in the object are defined as optional, there will be 1 or more "presence bitmask" octets. There are as many octets as are needed to provide one bit per optional property. The bits are assigned to the optional properties in schema order (first octet first, lowest order bit first).

For example: If there are two optional properties in the schema called "option1" and "option2" (defined in that order), there will be one presence bitmask octet and the bits will be assigned as bit 0 controls option1 and bit 1 controls option2.

If the bit for a particular optional property is set (1), the property will be encoded normally in the "values" portion of the message. If the bit is clear (0), the property will be omitted from the list of encoded values and will be considered "NULL" or "not present".

The element values are encoded by their type into the message in the order in which they appeared in the schema message.

Event Indication Message

No Format

        routing_key: console.event.1.<agent_bank>.<package_name>.<event_name>
No Format
        +-----+-----+-----+-------+-----------------------+
        | 'A' | 'M' | '12' | 'g/c/ie' |          seq          |
        +-----+-----+-----+-----+--+---------------------+--+--------+
        | packageName (str8)              packageName (str8)                        |
        +----------------------------------------------------------+
        | eventName (str8)              className (str8)                          |
        +----------------------------------------------------------+
        | class hash (bin128)             class hash (bin128)                       |
        +----------+-------+-----+-----+-----+-----+-----+-----+----------+
        | timestamp of currentevent sample (datetime)                 |
        +-----+--------+-----+-----+-----+--------+-----+-----+
        | time object was created (datetimeseverity (uint8)      |
      |
        +  +-----------------------+-------+-----------+-----+-----+-----+-----+-----+-----+
        | timeevent argument objectvalues was(in deletedschema (datetime)order)                                |
        +-----+-------------------------------------+-----+-----+-----+-----+-----+-----+
        | objectId (uint64)      

Get Query Message

A Get Request may be sent by the management console to cause a management agent to immediately send content information for objects of a class.

No Format

                       |routing_key: agent.1.<agent_bank>
        +-----+-----+-----+-----+-----+--------+-----+-----+
        | presence bitmasks (0 or more uint8 fields)'A' | 'M' | '2' | 'G' |          seq          |
        +-----+-----+-----+-----+-----+-----+-----+-----+---+---------------------+
        | config/instGet valuesrequest (infield schematable order)     (map)                              |
        +------------------------------------------------------------------------+

All timestamps are uint64 values representing nanoseconds since the epoch (January 1, 1970). The objectId is a uint64 value that uniquely identifies this object instance.

If any of the properties in the object are defined as optional, there will be 1 or more "presence bitmask" octets. There are as many octets as are needed to provide one bit per optional property. The bits are assigned to the optional properties in schema order (first octet first, lowest order bit first).

For example: If there are two optional properties in the schema called "option1" and "option2" (defined in that order), there will be one presence bitmask octet and the bits will be assigned as bit 0 controls option1 and bit 1 controls option2.

If the bit for a particular optional property is set (1), the property will be encoded normally in the "values" portion of the message. If the bit is clear (0), the property will be omitted from the list of encoded values and will be considered "NULL" or "not present".

The element values are encoded by their type into the message in the order in which they appeared in the schema message.

Get Query Message

The content of a get request is a field table that specifies what objects are being requested. Most of the fields are optional and are available for use in more extensive deployments.

Field Key

Type

Description

"_class"

str8

The name of the class of objects being requested.

"_package"

str8

The name of the extension package the class belongs to. If omitted, the package defaults to "qpid" for access to objects in the connected broker.

_objectid

bin128

The object ID of the object being requested

When the management agent receives a get request, it sends content messages describing the requested objects. Once the last content message is sent, it then sends a Command Completion message with the same sequence number supplied in the request to indicate to the requestor that there are no more messages coming.

Method Request

Method request messages have the following structure. The sequence number is opaque to the management agent. It is returned unchanged in the method reply so the calling client can correctly associate the reply to the request. The objectId is the unique ID of the object on which the method is to be executedA Get Request may be sent by the management console to cause a management agent to immediately send content information for objects of a class.

No Format
        +-----+-----+-----+-----+-----------------------+
        | 'A' | 'M' | '1' | 'G' |          seq          |routing_key: agent.1.<agent_bank>
        +-----+-----+-----+-----+-----+-----+-------------+----------+
        | Get'A' request| field'M' table| '2' | 'M' |            seq                  |
        +----------------------------------------------------------+

The content of a get request is a field table that specifies what objects are being requested. Most of the fields are optional and are available for use in more extensive deployments.

Field Key

Mandatory

Type

Description

"_class"

yes

short-string

The name of the class of objects being requested.

"_package"

no

short-string

The name of the extension package the class belongs to. If omitted, the package defaults to "qpid" for access to objects in the connected broker.

"_agent"

no

uuid

The management agent that is the target of the request. If omitted, agent defaults to the connected broker.

When the management agent receives a get request, it sends content messages describing the requested objects. Once the last content message is sent, it then sends a Command Completion message with the same sequence number supplied in the request to indicate to the requestor that there are no more messages coming.

Method Request

Method request messages have the following structure. The sequence number is opaque to the management agent. It is returned unchanged in the method reply so the calling client can correctly associate the reply to the request. The objectId is the unique ID of the object on which the method is to be executed.

No Format
+-----+-----+-----+-----------------------+
        |  objectId (bin128)                            |
        +-----+---------+-----+-----+-----------------------+
        | 'A' | 'M' | '1' | 'M' |  package name (str8)                          |
        +-----------------------------------------------+
        |  class name (str8)                  seq          |
        +------+--------+-----+-----+-----------------------+
        |  objectIdclass hash (uint64bin128)                            |
        +-----------------------------------------------+
        |  methodName (str8)                            |
        +-----------------------------------------------+------------------------+
        |  input and bidirectional argument values (in schema order)             |
        +------------------------------------------------------------------------+

...

Method reply messages have the following structure. The sequence number is identical to that supplied in the method request. The status code (and text) indicate whether or not the method was successful and if not, what the error was. Output and bidirectional arguments are only included if the status code was 0 (STATUS_OK).

No Format

        routing_key: <reply_to from request>
        +-----+-----+-----+-----+-----------------------+
        | 'A' | 'M' | '12' | 'm' |          seq          |
        +-----+-----+-----+-----+-----------------------+
        |  status code          (uint32) |
        +-----------------------+----------------------------------+
        |  status text (str8str16)                                      |
        +-----------------------+----------------------------------+-------------+
        |  output and bidirectional argument values (in schema order)            |
        +------------------------------------------------------------------------+

status code values are:

value

description

0

STATUS_OK - successful completion

1

STATUS_UNKNOWN_OBJECT - objectId not found in the agent

2

STATUS_UNKNOWN_METHOD - method is not known by the object type

3

STATUS_NOT_IMPLEMENTED - method is not currently implemented

4

STATUS_INVALID_PARAMETER - input argument is invalid

5

STATUS_FEATURE_NOT_IMPLEMENTED

6

STATUS_FORBIDDEN - operation is forbidden by Access Control List

7

STATUS_EXCEPTION - exception caught during method execution

8

STATUS_UNKNOWN_PACKAGE - package name not found

9

STATUS_UNKNOWN_CLASS - class name not found in package

Messages for Extended Scenario

...

No Format
      Broker                                                       Remote Agent
        |                                                               |
        | <----------------------------------------- Attach Request --- |
        | --- Attach Response ----------------------------------------> |
        |                                                               |
        | <------------------------------------- Package Indication --- |
        | <------------------------------------- Package Indication --- |
        |                                                               |
        | <--------------------------------------- Class Indication --- |
        | <--------------------------------------- Class Indication --- |
        | <--------------------------------------- Class Indication --- |
        | <--------------------------------------- Class Indication --- |
        | <--------------------------------------- Class Indication --- |
        |                                                               |
        | --- Schema Request (class key) -----------------------------> |
        | <---------------------------------------- Schema Response --- |
        |                                                               |
        | --- Schema Request (class key) -----------------------------> |
        | <---------------------------------------- Schema Response --- |
        |                                                               |
        |                                                               |

Extended Opcodes

...

opcode

...

message

...

description

...

'P'

...

Package Query

...

This message contains a schema package query request, requesting that the broker dump the list of known packages

...

'p'

...

Package Indication

...

This message contains a schema package indication, identifying a package known by the broker

...

'A'

...

Agent Attach Request

...

This message is sent by a remote agent when it wishes to attach to a management broker

...

'a'

...

Agent Attach Response

...

The management broker sends this response if an attaching remote agent is permitted to join

...

'x'

...

Console Added Indication

...

                  |

Package Query

No Format
        routing_key: agent.1.<agent_bank>
        +-----+-----+-----+-----+-----------------------+
        | 'A' | 'M' | '12' | 'P' |          seq          |
        +-----+-----+-----+-----+-----------------------------+

Package Indication

--------+

Package Indication

No Format

        routing_key: <reply_to from request> (if in reply to a request)
                     schema.package          (if unsolicited)
No Format

        +-----+-----+-----+-----+-----------------------+
        | 'A' | 'M' | '12' | 'p' |          seq          |
        +-----+-----+-----+-----+-----------------------+----------+
        |  package name (str8)                                     |
        +----------------------------------------------------------+

Agent Attach Request

No Format
        routing_key: broker
        +-----+-----+-----+-----+-----------------------+
        | 'A' | 'M' | '12' | 'A' |          seq          |
        +-----+-----+-----+-----+-----------------------+----------+
        |  label (str8)                                            |
        +------------------------+----------------------------------+
        |  system-id (uuid)                                        |
        +---------------------------------+------------------------+
        |  requested broker bank (uint32)  |
        +-----------------------+----------------------------------+
        |  requested objIdagent bank (uint32)  |
        +---------------------------------+

Agent Attach Response (success)

No Format
        routing_key: <reply_to from request>
        +-----+-----+-----+-----+-----------------------+
        | 'A' | 'M' | '12' | 'a' |          seq          |
        +-----+-----+-----+-----+--------+---------------+
        |  assigned broker bank (uint32) |
        +--------------------------------+
        |  assigned objIdagent bank (uint32)  |
        +--------------------------------+

Console Added Indication

No Format

        routing_key: agent.1.<agent_bank>
        +-----+-----+-----+-----+-----------------------+
        | 'A' | 'M' | '12' | 'x' |          seq          |
        +-----+-----+-----+-----+-----------------------+