接口的使用
org.apache.dubbo.rpc.Result
-
使用Result的程序包 程序包 说明 org.apache.dubbo.rpc org.apache.dubbo.rpc.filter org.apache.dubbo.rpc.listener org.apache.dubbo.rpc.protocol org.apache.dubbo.rpc.proxy org.apache.dubbo.rpc.support -
-
org.apache.dubbo.rpc中Result的使用
实现Result的org.apache.dubbo.rpc中的类 修饰符和类型 类 说明 classAppResponseAsyncRpcResultis introduced in 3.0.0 to replace RpcResult, and RpcResult is replaced withAppResponse: AsyncRpcResult is the object that is actually passed in the call chain AppResponse only simply represents the business resultclassAsyncRpcResultThis class represents an unfinished RPC call, it will hold some context information for this call, for example RpcContext and Invocation, so that when the call finishes and the result returns, it can guarantee all the contexts being recovered as the same as when the call was made before any callback is invoked.返回Result的org.apache.dubbo.rpc中的方法 修饰符和类型 方法 说明 ResultAppResponse. get()ResultAppResponse. get(long timeout, TimeUnit unit)ResultAsyncRpcResult. get()This method will always return after a maximum 'timeout' waiting: 1. if value returns before timeout, return normally. 2. if no value returns after timeout, throw TimeoutException.ResultAsyncRpcResult. get(long timeout, TimeUnit unit)ResultResult. get()ResultResult. get(long timeout, TimeUnit unit)ResultAsyncRpcResult. getAppResponse()ResultFilter. invoke(Invoker<?> invoker, Invocation invocation)Make sure call invoker.invoke() in your implementation.ResultInvoker. invoke(Invocation invocation)invoke.ResultAppResponse. whenCompleteWithContext(BiConsumer<Result,Throwable> fn)ResultAsyncRpcResult. whenCompleteWithContext(BiConsumer<Result,Throwable> fn)ResultResult. whenCompleteWithContext(BiConsumer<Result,Throwable> fn)Add a callback which can be triggered when the RPC call finishes.参数类型为Result的org.apache.dubbo.rpc中的方法 修饰符和类型 方法 说明 voidFilter.Listener. onResponse(Result appResponse, Invoker<?> invoker, Invocation invocation)类型变量类型为Result的org.apache.dubbo.rpc中的方法参数 修饰符和类型 方法 说明 <U> CompletableFuture<U>AppResponse. thenApply(Function<Result,? extends U> fn)<U> CompletableFuture<U>AsyncRpcResult. thenApply(Function<Result,? extends U> fn)<U> CompletableFuture<U>Result. thenApply(Function<Result,? extends U> fn)ResultAppResponse. whenCompleteWithContext(BiConsumer<Result,Throwable> fn)ResultAsyncRpcResult. whenCompleteWithContext(BiConsumer<Result,Throwable> fn)ResultResult. whenCompleteWithContext(BiConsumer<Result,Throwable> fn)Add a callback which can be triggered when the RPC call finishes. -
org.apache.dubbo.rpc.filter中Result的使用
返回Result的org.apache.dubbo.rpc.filter中的方法 修饰符和类型 方法 说明 ResultAccessLogFilter. invoke(Invoker<?> invoker, Invocation inv)This method logs the access log for service method invocation call.ResultActiveLimitFilter. invoke(Invoker<?> invoker, Invocation invocation)ResultClassLoaderFilter. invoke(Invoker<?> invoker, Invocation invocation)ResultCompatibleFilter. invoke(Invoker<?> invoker, Invocation invocation)ResultConsumerContextFilter. invoke(Invoker<?> invoker, Invocation invocation)ResultContextFilter. invoke(Invoker<?> invoker, Invocation invocation)ResultDeprecatedFilter. invoke(Invoker<?> invoker, Invocation invocation)ResultEchoFilter. invoke(Invoker<?> invoker, Invocation inv)ResultExceptionFilter. invoke(Invoker<?> invoker, Invocation invocation)ResultExecuteLimitFilter. invoke(Invoker<?> invoker, Invocation invocation)ResultGenericFilter. invoke(Invoker<?> invoker, Invocation inv)ResultGenericImplFilter. invoke(Invoker<?> invoker, Invocation invocation)ResultTimeoutFilter. invoke(Invoker<?> invoker, Invocation invocation)ResultTokenFilter. invoke(Invoker<?> invoker, Invocation inv)ResultTpsLimitFilter. invoke(Invoker<?> invoker, Invocation invocation)参数类型为Result的org.apache.dubbo.rpc.filter中的方法 修饰符和类型 方法 说明 voidActiveLimitFilter. onResponse(Result appResponse, Invoker<?> invoker, Invocation invocation)voidCompatibleFilter. onResponse(Result appResponse, Invoker<?> invoker, Invocation invocation)voidContextFilter. onResponse(Result appResponse, Invoker<?> invoker, Invocation invocation)voidExceptionFilter. onResponse(Result appResponse, Invoker<?> invoker, Invocation invocation)voidExecuteLimitFilter. onResponse(Result appResponse, Invoker<?> invoker, Invocation invocation)voidGenericFilter. onResponse(Result appResponse, Invoker<?> invoker, Invocation inv)voidGenericImplFilter. onResponse(Result appResponse, Invoker<?> invoker, Invocation invocation)voidTimeoutFilter. onResponse(Result appResponse, Invoker<?> invoker, Invocation invocation) -
org.apache.dubbo.rpc.listener中Result的使用
返回Result的org.apache.dubbo.rpc.listener中的方法 修饰符和类型 方法 说明 ResultListenerInvokerWrapper. invoke(Invocation invocation) -
org.apache.dubbo.rpc.protocol中Result的使用
返回Result的org.apache.dubbo.rpc.protocol中的方法 修饰符和类型 方法 说明 ResultAbstractInvoker. invoke(Invocation inv)ResultAsyncToSyncInvoker. invoke(Invocation invocation)ResultInvokerWrapper. invoke(Invocation invocation) -
org.apache.dubbo.rpc.proxy中Result的使用
返回Result的org.apache.dubbo.rpc.proxy中的方法 修饰符和类型 方法 说明 ResultAbstractProxyInvoker. invoke(Invocation invocation) -
org.apache.dubbo.rpc.support中Result的使用
返回Result的org.apache.dubbo.rpc.support中的方法 修饰符和类型 方法 说明 ResultMockInvoker. invoke(Invocation invocation)
-