Bug 1187 - Provide DELETE_PERIOD scaling factor K as an attribute
Provide DELETE_PERIOD scaling factor K as an attribute
Product: ns-3
Classification: Unclassified
Component: aodv
All All
: P5 normal
Assigned To: ns-bugs
Depends on:
  Show dependency treegraph
Reported: 2011-06-16 00:24 EDT by John Abraham
Modified: 2017-02-25 19:43 EST (History)
2 users (show)

See Also:


Note You need to log in before you can comment on or make changes to this bug.
Description John Abraham 2011-06-16 00:24:16 EDT
Provide DELETE_PERIOD scaling factor K as an attribute.
The current DELETE_PERIOD of 15 may be excessive for several MANET simulations.
Comment 1 Tom Henderson 2011-06-28 16:28:35 EDT
Agree with the proposal to add K.

I noticed a possible problem with the current implementation:

RoutingProtocol::RoutingProtocol () :


  DeletePeriod (Time (5 * std::max (ActiveRouteTimeout, HelloInterval))),
  m_routingTable (DeletePeriod),

m_routingTable is initialized with the DeletePeriod provided by the above default initializer, not by the attribute value  (attribute initialization is called after the constructor is called).

I'm not sure the attribute DeletePeriod is ever used; can you check?
Comment 2 Robert Ammon 2017-02-25 19:43:07 EST
DeletePeriod is indeed used by the RoutingTable implementation.

Changes uploaded as http://codereview.appspot.com/320720043 to use attributes to override constructor settings.