diff --git a/controller/northbound/server/pnd.go b/controller/northbound/server/pnd.go index 2ec5b3c75a30de50ac82e16dc85c6cb8f5c75420..7b88166d9bf5379bdb4fc03f60b2dc7ffcce7200 100644 --- a/controller/northbound/server/pnd.go +++ b/controller/northbound/server/pnd.go @@ -655,30 +655,23 @@ func (p PndServer) DeleteOnd(ctx context.Context, request *ppb.DeleteOndRequest) // SubscribePath subscribes to specifc paths of an ond func (p PndServer) SubscribePath(request *ppb.SubscribePathRequest, stream ppb.PndService_SubscribePathServer) error { - labels := prometheus.Labels{"service": "pnd", "rpc": "subscribe path"} - start := metrics.StartHook(labels, grpcRequestsTotal) - defer metrics.FinishHook(labels, start, grpcRequestDurationSecondsTotal, grpcRequestDurationSeconds) - pid, err := uuid.Parse(request.Pid) if err != nil { - return handleRPCError(labels, err) + return err } pnd, err := p.pndStore.Get(store.Query{ID: pid}) if err != nil { - log.Error(err) - return handleRPCError(labels, err) + return err } did, err := uuid.Parse(request.Did) if err != nil { - log.Error(err) - return handleRPCError(labels, err) + return err } if err := pnd.SubscribePath(did, request.Sublist); err != nil { - log.Error(err) - return handleRPCError(labels, err) + return err } return nil