Project

General

Profile

Actions

Task #1974

closed

Only multiply hyperbolic costs before registering

Added by Vince Lehman over 10 years ago. Updated about 10 years ago.

Status:
Closed
Priority:
High
Assignee:
Target version:
-
Start date:
09/09/2014
Due date:
% Done:

100%

Estimated time:

Description

Overview:

Currently, the route cost of all nexthops are multiplied and registered as an integer in NFD.

e.g. Nexthop{name: /a, faceId: 1, cost: 12.34} is registered as FibEntry{name: /a, faceId: 1, cost: 1234}

Instead, only hyperbolic costs should be multiplied before being registered. Link state costs should be registered with their originally computed costs.

Proposal:

Add a flag to the NextHop class that marks the nexthop as hyperbolic.

When getRouteCostAsAdjustedInteger() is called, the method checks if the nexthop is hyperbolic and if so, returns static_cast<uint64_t>(m_routeCost*HYPERBOLIC_COST_ADJUSTMENT_FACTOR);

If the nexthop was calculated by link state, the method returns static_cast<uint64_t>(m_routeCost);

HYPERBOLIC_COST_ADJUSTMENT_FACTOR was previously assigned a value of 100, but a cost of 1000 had been suggested and should be changed for this revision.

Actions

Also available in: Atom PDF