Book Image

OpenFlow Cookbook

Book Image

OpenFlow Cookbook

Overview of this book

Table of Contents (17 chapters)
16
Index

Getting the queue description using multipart messages

When the controller wants to fetch the details of the queues attached to the OpenFlow ports in the switch, they should send the OFPMP_QUEUE_DESC multipart message (ofp_multipart_request) to the switch.

How to do it...

In order to get information about the queue from the switch, the controller should send a multipart request message with the type field set as OFPMP_QUEUE_DESC. The message format that will be used by the controller to form the multipart request message is defined in the Introduction section in Chapter 5, Handling Multipart Statistics Messages (Part 2).

The body field of the multipart request message should be filled with the following structure by the controller:

/* Body for ofp_multipart_request of type OFPMP_QUEUE_DESC. */
struct ofp_queue_desc_request {
uint32_t port_no;  /* All ports if OFPP_ANY. */
uint32_t queue_id; /* All queues if OFPQ_ALL. */
};
How to do it...

The port_no field represents the port on which the queue is attached...