You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dubbo.apache.org by li...@apache.org on 2023/12/28 07:07:58 UTC
(dubbo) branch 3.3 updated: Triple Stub path compatibility (#13581)
This is an automated email from the ASF dual-hosted git repository.
liujun 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 bfd748ee5d Triple Stub path compatibility (#13581)
bfd748ee5d is described below
commit bfd748ee5d6ffe70baa7c3876097a0d51b936ec8
Author: earthchen <ea...@gmail.com>
AuthorDate: Thu Dec 28 15:07:51 2023 +0800
Triple Stub path compatibility (#13581)
fixes #13348
---
.../dubbo-compiler/src/main/resources/Dubbo3TripleStub.mustache | 8 ++++++--
.../src/main/resources/ReactorDubbo3TripleStub.mustache | 4 +++-
2 files changed, 9 insertions(+), 3 deletions(-)
diff --git a/dubbo-plugin/dubbo-compiler/src/main/resources/Dubbo3TripleStub.mustache b/dubbo-plugin/dubbo-compiler/src/main/resources/Dubbo3TripleStub.mustache
index c75eab4cf3..525eb8d634 100644
--- a/dubbo-plugin/dubbo-compiler/src/main/resources/Dubbo3TripleStub.mustache
+++ b/dubbo-plugin/dubbo-compiler/src/main/resources/Dubbo3TripleStub.mustache
@@ -238,8 +238,12 @@ public final class {{className}} {
Map<String,StubMethodHandler<?, ?>> handlers = new HashMap<>();
{{#methods}}
- pathResolver.addNativeStub( "/" + SERVICE_NAME + "/{{originMethodName}}" );
- pathResolver.addNativeStub( "/" + SERVICE_NAME + "/{{originMethodName}}Async" );
+ pathResolver.addNativeStub( "/" + SERVICE_NAME + "/{{originMethodName}}");
+ pathResolver.addNativeStub( "/" + SERVICE_NAME + "/{{originMethodName}}Async");
+ // for compatibility
+ pathResolver.addNativeStub( "/" + JAVA_SERVICE_NAME + "/{{originMethodName}}");
+ pathResolver.addNativeStub( "/" + JAVA_SERVICE_NAME + "/{{originMethodName}}Async");
+
{{/methods}}
{{#unaryMethods}}
diff --git a/dubbo-plugin/dubbo-compiler/src/main/resources/ReactorDubbo3TripleStub.mustache b/dubbo-plugin/dubbo-compiler/src/main/resources/ReactorDubbo3TripleStub.mustache
index 28c7626da8..ad9e2e232e 100644
--- a/dubbo-plugin/dubbo-compiler/src/main/resources/ReactorDubbo3TripleStub.mustache
+++ b/dubbo-plugin/dubbo-compiler/src/main/resources/ReactorDubbo3TripleStub.mustache
@@ -151,7 +151,9 @@ public final class {{className}} {
Map<String,StubMethodHandler<?, ?>> handlers = new HashMap<>();
{{#methods}}
- pathResolver.addNativeStub( "/" + SERVICE_NAME + "/{{originMethodName}}" );
+ pathResolver.addNativeStub( "/" + SERVICE_NAME + "/{{originMethodName}}");
+ // for compatibility
+ pathResolver.addNativeStub( "/" + JAVA_SERVICE_NAME + "/{{originMethodName}}");
{{/methods}}
{{#unaryMethods}}