Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When the "package packagename" is missing in the proto file, an error occurs during the invocation. #13372

Closed
1 task
xiaoyuuuuuupeng opened this issue Nov 16, 2023 · 2 comments
Labels
type/bug Bugs to being fixed

Comments

@xiaoyuuuuuupeng
Copy link
Contributor

  • I have searched the issues of this repository and believe that this is not a duplicate.

Environment

  • Dubbo version: 3.2.7
  • Operating System version: macos 13.2.1 (22D68)
  • Java version: 1.8

Steps to reproduce this issue

  1. proto文件
syntax = "proto3";

option java_multiple_files = true;
option java_package = "org.example.protogen";
option java_outer_classname = "PredictorProto";


message PredictRequest {
  string model = 1;
  string imei = 2;
  repeated string itemId = 3;
}

message PredictResponse {
  string errMsg = 1;
  string model = 2;
  string predictionMap = 3;
}

service PredictService {
  rpc Predict (PredictRequest) returns (PredictResponse) {}
}
  1. generate proto files and build a trip server
  2. build a native grpc client

Expected Behavior

success

Actual Behavior

failed

If there is an exception, please attach the exception trace:

  • native grpc client side:
    image
Exception in thread "main" io.grpc.StatusRuntimeException: UNIMPLEMENTED: Service not found:PredictService
	at io.grpc.stub.ClientCalls.toStatusRuntimeException(ClientCalls.java:271)
	at io.grpc.stub.ClientCalls.getUnchecked(ClientCalls.java:252)
	at io.grpc.stub.ClientCalls.blockingUnaryCall(ClientCalls.java:165)
	at org.example.protogen.PredictServiceGrpc$PredictServiceBlockingStub.predict(PredictServiceGrpc.java:157)
	at com.example.userinfoservice.Main2Application.main(Main2Application.java:23)
@xiaoyuuuuuupeng xiaoyuuuuuupeng added the type/bug Bugs to being fixed label Nov 16, 2023
@xiaoyuuuuuupeng
Copy link
Contributor Author

原因是在没package xxx;时,会导致Dubbo3TripleGenerator生成的Interface中 SERVICE_NAME错误
image

@xiaoyuuuuuupeng
Copy link
Contributor Author

Will be fixed in 3.3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/bug Bugs to being fixed
Projects
None yet
Development

No branches or pull requests

2 participants