Ldp

Package: inet.networklayer.ldp

simple module Ldp

Handles and processes LDP messages.

The LDP protocol is used by one LSR (Label Switched Router) to inform another LSR of the label bindings it has made. The LSR uses this protocol to establish label switched paths through a network by mapping network layer routing information directly to data-link layer switched paths.

Operations

All LDP message types are subclassed from LdpPacket, and include LdpHello, LdpNotify, LdpLabelRequest, LdpIni and LdpAddress.

Message processing in the Ldp module is explained in LDP Message Processing

Author: Vojta Janota

inet.networklayer.ldp.LdpLdpsimple

Usage diagram

Inheritance diagram

Used in compound modules

Name

Type

Description

LdpMplsRouter

compound module

An LDP-capable MPLS router.

Extends

Name

Type

Description

SimpleModule

simple module

Base module for all INET simple modules.

Parameters

Name

Type

Default value

Description

displayStringTextFormat

string

“”

Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information

interfaceTableModule

string

The path to the InterfaceTable module

routingTableModule

string

libTableModule

string

tedModule

string

holdTime

double

15s

helloInterval

double

5s

stopOperationExtraTime

double

-1s

Extra time after lifecycle stop operation finished

stopOperationTimeout

double

2s

Timeout value for lifecycle stop operation

Properties

Name

Value

Description

class

Ldp

display

i=block/control

lifecycleSupport

Gates

Name

Direction

Size

Description

socketIn

input

socketOut

output

Source code

//
// Handles and processes LDP messages.
//
// The LDP protocol is used by one LSR (Label Switched Router) to inform
// another LSR of the label bindings it has made. The LSR uses this protocol
// to establish label switched paths through a network by mapping network layer
// routing information directly to data-link layer switched paths.
//
// Operations
//
// All LDP message types are subclassed from ~LdpPacket, and include
// ~LdpHello, ~LdpNotify, ~LdpLabelRequest, ~LdpIni and ~LdpAddress.
//
// Message processing in the ~Ldp module is explained in
// <a href="ldp-processing.html">LDP Message Processing</a>
//
// @author Vojta Janota
//
simple Ldp extends SimpleModule like IApp
{
    parameters:
        @class(Ldp);
        string interfaceTableModule;   // The path to the InterfaceTable module
        string routingTableModule;
        string libTableModule;
        string tedModule;
        double holdTime @unit(s) = default(15s);
        double helloInterval @unit(s) = default(5s);
        @display("i=block/control");
        @lifecycleSupport;
        double stopOperationExtraTime @unit(s) = default(-1s);    // Extra time after lifecycle stop operation finished
        double stopOperationTimeout @unit(s) = default(2s);    // Timeout value for lifecycle stop operation

    gates:
        input socketIn @labels(TcpCommand/up,UdpCommand/up);
        output socketOut @labels(TcpCommand/down,UdpCommand/down);
}

File: src/inet/networklayer/ldp/Ldp.ned