Ipv4NodeConfigurator

Package: inet.networklayer.configurator.ipv4

Ipv4NodeConfigurator

simple module

This module has one instance per network node, and it acts like a bridge between the node and the network's global configurator module, Ipv4NetworkConfigurator.

Ipv4NetworkConfigurator only computes and remembers configuration data (assigned IP addresses, static routes, etc), but doesn't configure the nodes' routing tables and interfaces accordingly. The actual configuration is carried out by this module, at network initialization time and also when the node restarts (i.e. after a shutdown or a crash.)

This module is needed because of failure/restart scenarios: Ipv4NetworkConfigurator would not be able to configure the node after a restart, because being a global module, it doesn't know about node lifecycle events.

Inheritance diagram

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

Used in compound modules

Name Type Description
ExtUpperIpv4NetworkLayer compound module (no description)

Parameters

Name Type Default value Description
interfaceTableModule string

The path to the InterfaceTable module

routingTableModule string
networkConfiguratorModule string "configurator"

TODO eventually rename to networkConfigurator

configureRoutingTable bool true

add routing entries to routing table (uses the configurator module)

Properties

Name Value Description
display i=block/cogwheel

Direct method calls (observed)

call tofunctioninfo
MacForwardingTableConfiguratorinet::MacForwardingTableConfigurator::receiveSignalipv4McastChange
InterfaceTableinet::InterfaceTable::interfaceChangedinterfaceChanged
Igmpv2inet::Igmpv2::receiveSignalipv4MulticastGroupJoined
Ipv4RoutingTableinet::Ipv4RoutingTable::addMulticastRouteaddMulticastRoute(...)
Ipv4RoutingTableinet::Ipv4RoutingTable::addRouteaddRoute(...)

Called methods (observed)

functioninfocall from
inet::Ipv4NodeConfigurator::handleOperationStagehandleOperationStageScenarioManager, SimpleEpEnergyManagement, SimpleEpEnergyStorage
inet::Ipv4NodeConfigurator::receiveSignalinterfaceStateChangedInterfaceTable

Tagging operations (observed)

tagTypetagAction
inet::Ipv4InterfaceDataaddTag, getTagForUpdate

Source code

//
// This module has one instance per network node, and it acts like a bridge
// between the node and the network's global configurator module,
// ~Ipv4NetworkConfigurator.
//
// ~Ipv4NetworkConfigurator only computes and remembers configuration data
// (assigned IP addresses, static routes, etc), but doesn't configure the nodes'
// routing tables and interfaces accordingly. The actual configuration is
// carried out by this module, at network initialization time and also when
// the node restarts (i.e. after a shutdown or a crash.)
//
// This module is needed because of failure/restart scenarios:
// ~Ipv4NetworkConfigurator would not be able to configure the node after
// a restart, because being a global module, it doesn't know about node
// lifecycle events.
//
simple Ipv4NodeConfigurator like IIpv4NodeConfigurator
{
    parameters:
        string interfaceTableModule;   // The path to the InterfaceTable module
        string routingTableModule;
        // TODO eventually rename to networkConfigurator
        string networkConfiguratorModule = default("configurator"); // the absolute path to the Ipv4NetworkConfigurator; use "" if there is no configurator
        bool configureRoutingTable = default(true);     // add routing entries to routing table (uses the configurator module)
        @display("i=block/cogwheel");
}

File: src/inet/networklayer/configurator/ipv4/Ipv4NodeConfigurator.ned