UnaryClientInterceptor(target string) grpc.UnaryClientInterceptor { return func() error { cb := g.GetCircuit(target, method) err := cb.Execute( ctx, func(ctx context.Context) error { return invoker(ctx, method, req, reply, cc, opts...) }, g.fallbackFunc, ) if cErr, ok := err.(circuit.Error); ok && cErr.CircuitOpen() { return ErrorCircleIsOpen } return err } }