diff --git a/pyroute2/ndb/source.py b/pyroute2/ndb/source.py index 45cac43f1..a8c4a2c15 100644 --- a/pyroute2/ndb/source.py +++ b/pyroute2/ndb/source.py @@ -7,10 +7,21 @@ starts with one local RTNL source names `localhost`:: >>> ndb = NDB() - >>> ndb.sources.details() - {'kind': u'local', u'nlm_generator': 1, 'target': u'localhost'} + >>> ndb.sources.summary().format("json") + [ + { + "name": "localhost", + "spec": "{'target': 'localhost', 'nlm_generator': 1}", + "state": "running" + }, + { + "name": "localhost/nsmanager", + "spec": "{'target': 'localhost/nsmanager'}", + "state": "running" + } + ] >>> ndb.sources['localhost'] - [running] + [running] The `localhost` RTNL source starts an additional async cache thread. The `nlm_generator` option means that instead of collections the @@ -18,7 +29,7 @@ consume memory regardless of the RTNL objects number:: >>> ndb.sources['localhost'].nl.link('dump') - + See also: :ref:`iproute`