def del_neighbor(self, **kwargs):
"""
Unregister the specified neighbor from the speaker.
Usage:
======= ==================================
Method URI
======= ==================================
DELETE /vtep/speaker/neighbors/{address}
======= ==================================
Request parameters:
========== ================================================
Attribute Description
========== ================================================
address IP address of neighbor. (e.g. "172.17.0.2")
========== ================================================
Example::
$ curl -X DELETE http://localhost:8080/vtep/speaker/neighbors/172.17.0.2 |
python -m json.tool
::
{
"172.17.0.2": {
"EvpnNeighbor": {
"address": "172.17.0.2",
"remote_as": 65000,
"state": "up"
}
}
}
"""
try:
body = self.vtep_app.del_neighbor(**kwargs)
except (BGPSpeakerNotFound, NeighborNotFound) as e:
return e.to_response(status=404)
return Response(content_type='application/json',
body=json.dumps(body))
评论列表
文章目录