@Override
    protected ExecuteContext doBefore(ExecuteContext context) {
        final Optional<Object> rpcClient = ReflectUtils.getFieldValue(context.getObject(), "rpcClient");
        if (!rpcClient.isPresent()) {
            return context;
        }
        final Object client = rpcClient.get();
        final Optional<Object> isShutdownRaw = ReflectUtils.invokeMethod(client, "isShutdown", null, null);
        if (isShutdownRaw.isPresent() && isShutdownRaw.get() instanceof Boolean) {
            boolean isShutdown = (boolean) isShutdownRaw.get();
            if (isShutdown) {
                LOGGER.info("RpcClient has been shutdown, skip deregister operation!");
                context.skip(null);
            }
        }
        return context;
    }
@Test
    public void test() throws NoSuchMethodException {
        final NacosGrpcDeRegisterInterceptor interceptor = new NacosGrpcDeRegisterInterceptor();
        final ExecuteContext context = buildContext(new NacosGrpcProxy1());
        final ExecuteContext context1 = interceptor.doBefore(context);
        Assert.assertFalse(context1.isSkip());
        final ExecuteContext context2 = buildContext(new NacosRealGrpcProxy());
        final ExecuteContext context3 = interceptor.doBefore(context2);
        Assert.assertFalse(context3.isSkip());
        final NacosRealGrpcProxy nacosRealGrpcProxy = new NacosRealGrpcProxy();
        nacosRealGrpcProxy.rpcClient.isShutdown = true;
        final ExecuteContext context4 = buildContext(nacosRealGrpcProxy);
        final ExecuteContext context5 = interceptor.doBefore(context4);
        Assert.assertTrue(context5.isSkip());
    }