This is an automated email from the ASF dual-hosted git repository.

zrlw pushed a commit to branch 3.3
in repository https://gitbox.apache.org/repos/asf/dubbo.git


The following commit(s) were added to refs/heads/3.3 by this push:
     new 43478c1d9b Fix RpcUtils by getting method from invokerInterface if it 
is not null (#15477)
43478c1d9b is described below

commit 43478c1d9bfd6dd6f7a9ea79fc0943603af7010e
Author: zrlw <[email protected]>
AuthorDate: Mon Jun 23 09:38:18 2025 +0800

    Fix RpcUtils by getting method from invokerInterface if it is not null 
(#15477)
---
 .../src/main/java/org/apache/dubbo/rpc/support/RpcUtils.java          | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git 
a/dubbo-rpc/dubbo-rpc-api/src/main/java/org/apache/dubbo/rpc/support/RpcUtils.java
 
b/dubbo-rpc/dubbo-rpc-api/src/main/java/org/apache/dubbo/rpc/support/RpcUtils.java
index 228392fe02..ccd48e8d73 100644
--- 
a/dubbo-rpc/dubbo-rpc-api/src/main/java/org/apache/dubbo/rpc/support/RpcUtils.java
+++ 
b/dubbo-rpc/dubbo-rpc-api/src/main/java/org/apache/dubbo/rpc/support/RpcUtils.java
@@ -244,9 +244,7 @@ public class RpcUtils {
 
     private static Method getMethodByService(Invocation invocation, String 
service) throws NoSuchMethodException {
         Class<?> invokerInterface = invocation.getInvoker().getInterface();
-        Class<?> cls = invokerInterface != null
-                ? ReflectUtils.forName(invokerInterface.getClassLoader(), 
service)
-                : ReflectUtils.forName(service);
+        Class<?> cls = invokerInterface != null ? invokerInterface : 
ReflectUtils.forName(service);
         Method method = cls.getMethod(invocation.getMethodName(), 
invocation.getParameterTypes());
         if (method.getReturnType() == void.class) {
             return null;

Reply via email to