fix:when proto miss package config bug (#13373)

Co-authored-by: pengxiaoyu <pengxiaoyu@shengqugames.com>
Co-authored-by: earthchen <earthchen1996@gmail.com>
This commit is contained in:
XiaoyuPeng 2023-11-20 21:57:02 +08:00 committed by GitHub
parent f441e79d8d
commit 650ee3b9d4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 15 additions and 3 deletions

View File

@ -28,7 +28,12 @@ import java.util.concurrent.atomic.AtomicBoolean;
public interface {{interfaceClassName}} extends org.apache.dubbo.rpc.model.DubboStub {
static final String JAVA_SERVICE_NAME = "{{packageName}}.{{serviceName}}";
{{#commonPackageName}}
static final String SERVICE_NAME = "{{commonPackageName}}.{{serviceName}}";
{{/commonPackageName}}
{{^commonPackageName}}
static final String SERVICE_NAME = "{{serviceName}}";
{{/commonPackageName}}
// FIXME, initialize Dubbo3 stub when interface loaded, thinking of new ways doing this.
static final boolean inited = {{className}}.init();

View File

@ -30,8 +30,12 @@ import java.util.concurrent.CompletableFuture;
public interface {{interfaceClassName}} extends org.apache.dubbo.rpc.model.DubboStub {
String JAVA_SERVICE_NAME = "{{packageName}}.{{serviceName}}";
{{#commonPackageName}}
String SERVICE_NAME = "{{commonPackageName}}.{{serviceName}}";
{{/commonPackageName}}
{{^commonPackageName}}
String SERVICE_NAME = "{{serviceName}}";
{{/commonPackageName}}
{{#unaryMethods}}
{{#javaDoc}}
{{{javaDoc}}}

View File

@ -25,9 +25,12 @@ import reactor.core.publisher.Mono;
public interface {{interfaceClassName}} extends org.apache.dubbo.rpc.model.DubboStub {
String JAVA_SERVICE_NAME = "{{packageName}}.{{serviceName}}";
{{#commonPackageName}}
String SERVICE_NAME = "{{commonPackageName}}.{{serviceName}}";
{{/commonPackageName}}
{{^commonPackageName}}
String SERVICE_NAME = "{{commonPackageName}}.{{serviceName}}";
{{/commonPackageName}}
{{#methods}}
{{#javaDoc}}
{{{javaDoc}}}