[Interop-dev] Network Topology JSON [was: OLSRd2 JSON APIs]

Nemesis (spam-protected)
Thu Nov 20 13:02:47 CET 2014


Hey,

On 11/19/2014 12:24 PM, Henning Rogge wrote:
> If you run different metrics, you create multiple routes. Maybe we
> need to add the routing table to the tuple.
>
> the "cost" value should contain the metric as a dimensionless value,
> so external code can judge if one route is better than another one
> without knowing the metric type. But we could add a "cost_type" as a
> free-text field that describes the content of the cost field.
>
> {
>     "route" : [
>         {
>             "destination": "<ip/prefix>",
>             "source": "<ip/prefix>",
>             "next" : "<ip>",
>             "device": "<dev>",
>             "table": <routing-table>
>             "cost": "<value>",
>             "cost_type": "<name of cost algorithm>"
>         }
>     ]
> }
>
> "cost_type" value could be things like ETX, ETT or "BATMAN metric xyz"
> or whatever.

Thanks for the input.

I got some feedback from Antonio Quartulli (batman-adv) to see how that
would fit for batman-adv.

He told me that "source" doesn't apply for batman-adv and should be
omitted if "type" is "batman-adv".

We also reasoned about "cost" and "cost_type". The word "cost" implies
that is better to have a lower cost, while some algorithms might do it
differently.
So peraphs using "metric" and "metric_name" would be more generic.

I also added a "meta" section (which I think we should have in the
network-device-config-json too) and renamed "type" to "routing_protocol"
to follow the verbose and self documenting approach that Mitar suggested
previously.

This is the result:
https://github.com/interop-dev/network-device-schema/compare/f41a1561bd...1cba66c3c5c

{

  *
    meta: {
      o
        type: "topology",
      o
        version: 0
    },
  *
    routing_protocol: "<routing protocol name>",
  *
    routes: [
      o
        {
          +
            destination: "<id>",
          +
            source: "<id>",
          +
            next: "<id>",
          +
            device: "<device>",
          +
            table: "<routing table>",
          +
            metric: "<metric value>",
          +
            metric_name: "<name of algorithm>"
        }
    ]

}

Whatcha think?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.funkfeuer.at/pipermail/interop-dev/attachments/20141120/62d72379/attachment.html>


More information about the Interop-dev mailing list