EligibilityTimeMeter¶
Package: inet.protocolelement.shaper
simple module EligibilityTimeMeter
A packet meter which measures the packet flow that is passing through and optionally attaches an EligibilityTimeTag to the packets. The tag contains the calculated simulation time when the packet becomes eligible for transmission according to the asynchronous shaper algorithm.
This module is part of the asynchronous shaper infrastructure.
See also: EligibilityTimeGate, EligibilityTimeFilter, EligibilityTimeQueue, EligibilityTimeTag
Usage diagram¶
Inheritance diagram¶
Used in compound modules¶
Name |
Type |
Description |
|---|---|---|
compound module |
Combines two meters and their corresponding filters per path. This is primarily useful for combining a token bucket based metering with an asynchronous packet shaper. Note that the asynchronous packet shaper also has parts in the network interface queue module. |
Known subclasses¶
Name |
Type |
Description |
|---|---|---|
simple module |
Extends the |
Extends¶
Name |
Type |
Description |
|---|---|---|
simple module |
Base module for various packet meter modules. Derived modules must implement a single |
Parameters¶
Name |
Type |
Default value |
Description |
|---|---|---|---|
displayStringTextFormat |
string |
“contains {numTokens} tk\nbucket empty at {bucketEmptyTime}\nmetered %p pk (%l)” |
Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information |
clockModule |
string |
“” |
Relative path of a module that implements IClock(1,:ref:2 <neddoc-msg-inet-iclock>); optional |
packetOverheadLength |
int |
0b |
Extra packet length taken into account, can be used to represent overhead added by lower layers |
committedInformationRate |
double |
Committed information rate of the packet flow |
|
committedBurstSize |
int |
Committed burst size of the packet flow |
|
maxResidenceTime |
double |
-1s |
Maximum packet residence time measured from the packet arrival time to the meter module to the transmission eligibility time, not used by default |
Properties¶
Name |
Value |
Description |
|---|---|---|
class |
EligibilityTimeMeter |
|
display |
i=block/star |
Gates¶
Name |
Direction |
Size |
Description |
|---|---|---|---|
in |
input |
||
out |
output |
Signals¶
Name |
Type |
Unit |
Description |
|---|---|---|---|
packetPulledIn |
|||
packetPulledOut |
|||
packetPushedIn |
|||
packetPushedOut |
|||
tokensChanged |
double |
Statistics¶
Name |
Title |
Source |
Record |
Unit |
Interpolation Mode |
Description |
|---|---|---|---|---|---|---|
flowIncomingDataRate |
flow specific incoming data rate |
throughput(demuxFlow(merge(packetPushedIn, packetPulledIn))) |
vector |
bps |
linear |
the statistical value is the flow specific data rate of the incoming packets |
flowIncomingPacketLengths |
flow specific incoming packet lengths |
packetLength(demuxFlow(merge(packetPushedIn, packetPulledIn))) |
sum,histogram,vector |
b |
none |
the statistical value is the flow specific length of the incoming packet |
flowOutgoingDataRate |
flow specific outgoing data rate |
throughput(demuxFlow(merge(packetPushedOut, packetPulledOut))) |
vector |
bps |
linear |
the statistical value is the flow specific data rate of the outgoing packets |
flowOutgoingPacketLengths |
flow specific outgoing packet lengths |
packetLength(demuxFlow(merge(packetPushedOut, packetPulledOut))) |
sum,histogram,vector |
b |
none |
the statistical value is the flow specific length of the outgoing packet |
incomingDataRate |
incoming data rate |
throughput(merge(packetPushedIn, packetPulledIn)) |
vector |
bps |
linear |
the statistical value is the data rate of the incoming packets |
incomingPacketLengths |
incoming packet lengths |
packetLength(merge(packetPushedIn, packetPulledIn)) |
sum,histogram,vector |
b |
none |
the statistical value is the length of the incoming packet |
incomingPackets |
incoming packets |
merge(packetPushedIn, packetPulledIn) |
count |
pk |
the statistical value is the incoming packet |
|
numTokens |
number of tokens |
tokensChanged |
vector |
tk |
linear |
|
outgoingDataRate |
outgoing data rate |
throughput(merge(packetPushedOut, packetPulledOut)) |
vector |
bps |
linear |
the statistical value is the data rate of the outgoing packets |
outgoingPacketLengths |
outgoing packet lengths |
packetLength(merge(packetPushedOut, packetPulledOut)) |
sum,histogram,vector |
b |
none |
the statistical value is the length of the outgoing packet |
outgoingPackets |
outgoing packets |
merge(packetPushedOut, packetPulledOut) |
count |
pk |
the statistical value is the outgoing packet |
Source code¶
//
// A packet meter which measures the packet flow that is passing
// through and optionally attaches an ~EligibilityTimeTag to the packets. The
// tag contains the calculated simulation time when the packet becomes eligible
// for transmission according to the asynchronous shaper algorithm.
//
// This module is part of the asynchronous shaper infrastructure.
//
// @see ~EligibilityTimeGate, ~EligibilityTimeFilter, ~EligibilityTimeQueue, ~EligibilityTimeTag
//
simple EligibilityTimeMeter extends PacketMeterBase like IPacketMeter
{
parameters:
string clockModule = default(""); // Relative path of a module that implements IClock; optional
int packetOverheadLength @unit(b) = default(0b); // Extra packet length taken into account, can be used to represent overhead added by lower layers
double committedInformationRate @unit(bps); // Committed information rate of the packet flow
int committedBurstSize @unit(b); // Committed burst size of the packet flow
double maxResidenceTime @unit(s) = default(-1s); // Maximum packet residence time measured from the packet arrival time to the meter module to the transmission eligibility time, not used by default
displayStringTextFormat = default("contains {numTokens} tk\nbucket empty at {bucketEmptyTime}\nmetered %p pk (%l)");
@class(EligibilityTimeMeter);
@signal[tokensChanged](type=double);
@statistic[numTokens](title="number of tokens"; source=tokensChanged; record=vector; unit=tk; interpolationmode=linear);
}
File: src/inet/protocolelement/shaper/EligibilityTimeMeter.ned