CompoundPacketQueue

Package: inet.queueing.queue

CompoundPacketQueue

compound module

This compound module serves as a base module for complex packet queues formed by combining several queueing components.

Inheritance diagram

The following diagram shows inheritance relationships for this type. Unresolved types are missing from the diagram.

Known subclasses

Name Type Description
CompoundPendingQueue compound module (no description)
DiffservQueue compound module

This is an example queue, that can be used in interfaces of DS core and edge nodes to support the AFxy (RFC 2597) and EF (RFC 3246) PHBs.

EtherQosQueue compound module

Queue module that gives the PAUSE frames a higher priority, and can be parametrized with an IPacketQueue for serving the data frames.

EtherQosRedQueue compound module

Queue module that gives the PAUSE frames a higher priority, and using Random Early Detection algorithm on data frames, and can be parametrized with an IPacketQueue for serving the data frames.

PriorityQueue compound module

This module implements a priority queue with multiple inner queues and an optional shared memory buffer.

RedDropperQueue compound module

Combines a packet queue with random early detection (RED) dropper.

Extends

Name Type Description
PacketQueueBase simple module

This is a base module for various packet queue modules which maintains a few statistics.

Parameters

Name Type Default value Description
displayStringTextFormat string "contains %p pk (%l) pushed %u created %c\n popped %o removed %r dropped %d"

determines display string text above the submodule

packetCapacity int -1

maximum number of packets in the queue, no limit by default

dataCapacity int -1b

maximum total length of packets in the queue, no limit by default

Properties

Name Value Description
display i=block/queue
class CompoundPacketQueue

Gates

Name Direction Size Description
in input
out output

Signals

Name Type Unit
packetRemoved inet::Packet
packetPushed inet::Packet
packetDropped inet::Packet
packetPopped inet::Packet

Statistics

Name Title Source Record Unit Interpolation Mode
packetRemoved packets removed localSignal(packetRemoved) count, sum(packetBytes), vector(packetBytes) none
queueLength queue length count(localSignal(packetPushed)) - count(localSignal(packetPopped)) - count(localSignal(packetRemoved)) - count(packetDropped) max, timeavg, vector sample-hold
queueingTime queueing times queueingTime(packetPopped) histogram, vector s none
packetPushed packets pushed localSignal(packetPushed) count, sum(packetBytes), vector(packetBytes) none
packetDropQueueOverflow packets dropped: queue overflow packetDropReasonIsQueueOverflow(packetDropped) count, sum(packetBytes), vector(packetBytes) none
packetPopped packets popped localSignal(packetPopped) count, sum(packetBytes), vector(packetBytes) none

Source code

//
// This compound module serves as a base module for complex packet queues formed
// by combining several queueing components.
//
module CompoundPacketQueue extends PacketQueueBase like IPacketQueue
{
    parameters:
        int packetCapacity = default(-1); // maximum number of packets in the queue, no limit by default
        int dataCapacity @unit(b) = default(-1b); // maximum total length of packets in the queue, no limit by default
        displayStringTextFormat = default("contains %p pk (%l) pushed %u created %c\n popped %o removed %r dropped %d");
        @class(CompoundPacketQueue);
        @signal[packetPushed](type=inet::Packet);
        @signal[packetPopped](type=inet::Packet);
        @signal[packetRemoved](type=inet::Packet);
        @signal[packetDropped](type=inet::Packet);
        @statistic[packetPushed](title="packets pushed"; source=localSignal(packetPushed); record=count,sum(packetBytes),vector(packetBytes); interpolationmode=none);
        @statistic[packetPopped](title="packets popped"; source=localSignal(packetPopped); record=count,sum(packetBytes),vector(packetBytes); interpolationmode=none);
        @statistic[packetRemoved](title="packets removed"; source=localSignal(packetRemoved); record=count,sum(packetBytes),vector(packetBytes); interpolationmode=none);
        @statistic[packetDropQueueOverflow](title="packets dropped: queue overflow"; source=packetDropReasonIsQueueOverflow(packetDropped); record=count,sum(packetBytes),vector(packetBytes); interpolationmode=none);
        @statistic[queueingTime](title="queueing times"; source=queueingTime(packetPopped); record=histogram,vector; unit=s; interpolationmode=none);
        @statistic[queueLength](title="queue length"; source=count(localSignal(packetPushed)) - count(localSignal(packetPopped)) - count(localSignal(packetRemoved)) - count(packetDropped); record=max,timeavg,vector; interpolationmode=sample-hold);
}
File: src/inet/queueing/queue/CompoundPacketQueue.ned