diff options
author | FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> | 2015-11-12 14:47:59 +0900 |
---|---|---|
committer | FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> | 2015-11-12 15:01:12 +0900 |
commit | 95e7cc73083dfbc161b4ac6b0271c006d822d38d (patch) | |
tree | f76aeb30f19ee66aca066f366f105c0d0a5bf20c /server/grpc_server.go | |
parent | 180d68f88f457096ec92bcb6eabd915a64bb8858 (diff) |
mrt: support reset/rotate commands
$ gobgp mrt update reset
create a new file or reopen the existing file and continue to write
update messages to it.
$ gobgp mrt update <filename>
rename the current logging file to <filename> and truncate the logging
file and continue to write update messages to it.
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Diffstat (limited to 'server/grpc_server.go')
-rw-r--r-- | server/grpc_server.go | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/server/grpc_server.go b/server/grpc_server.go index c475f232..5ec5947b 100644 --- a/server/grpc_server.go +++ b/server/grpc_server.go @@ -48,6 +48,7 @@ const ( REQ_MONITOR_NEIGHBOR_PEER_STATE REQ_MRT_GLOBAL_RIB REQ_MRT_LOCAL_RIB + REQ_MOD_MRT REQ_RPKI REQ_ROA REQ_VRF @@ -259,6 +260,10 @@ func (s *Server) GetMrt(arg *api.MrtArguments, stream api.GobgpApi_GetMrtServer) }) } +func (s *Server) ModMrt(ctx context.Context, arg *api.ModMrtArguments) (*api.Error, error) { + return s.mod(REQ_MOD_MRT, arg) +} + func (s *Server) GetRPKI(arg *api.Arguments, stream api.GobgpApi_GetRPKIServer) error { req := NewGrpcRequest(REQ_RPKI, "", bgp.RouteFamily(arg.Rf), nil) s.bgpServerCh <- req |