Skip to content

Fix Empty return type in triple generator#16324

Open
gaoxiaolei-s59 wants to merge 1 commit into
apache:3.3from
gaoxiaolei-s59:codex/fix-empty-return-type
Open

Fix Empty return type in triple generator#16324
gaoxiaolei-s59 wants to merge 1 commit into
apache:3.3from
gaoxiaolei-s59:codex/fix-empty-return-type

Conversation

@gaoxiaolei-s59

Copy link
Copy Markdown

What is the purpose of the change

Fix the Dubbo3 Triple generator output for unary methods whose response type is google.protobuf.Empty. The generated synchronous Java method now uses void, while descriptor, parser, async, and StreamObserver paths keep using com.google.protobuf.Empty.

Fixes #15629

Brief changelog

  • Map google.protobuf.Empty to com.google.protobuf.Empty in generator type context.
  • Split unary synchronous return type from protobuf wire output type.
  • Add Triple generator coverage for Empty responses.

Verifying this change

  • ./mvnw -pl dubbo-plugin/dubbo-compiler test

@codecov-commenter

codecov-commenter commented Jun 9, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 90.90909% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 60.97%. Comparing base (c3ceb27) to head (f5889a1).

Files with missing lines Patch % Lines
...n/java/org/apache/dubbo/gen/AbstractGenerator.java 90.90% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##                3.3   #16324      +/-   ##
============================================
+ Coverage     60.79%   60.97%   +0.18%     
+ Complexity    11777    11773       -4     
============================================
  Files          1953     1953              
  Lines         89208    89217       +9     
  Branches      13458    13460       +2     
============================================
+ Hits          54234    54401     +167     
+ Misses        29403    29218     -185     
- Partials       5571     5598      +27     
Flag Coverage Δ
integration-tests-java21 32.16% <0.00%> (+0.03%) ⬆️
integration-tests-java8 32.25% <0.00%> (-0.08%) ⬇️
samples-tests-java21 32.16% <0.00%> (+0.04%) ⬆️
samples-tests-java8 29.85% <0.00%> (-0.02%) ⬇️
unit-tests-java11 59.21% <90.90%> (+0.18%) ⬆️
unit-tests-java17 58.69% <90.90%> (+0.17%) ⬆️
unit-tests-java21 58.73% <90.90%> (+0.22%) ⬆️
unit-tests-java25 58.67% <90.90%> (+0.19%) ⬆️
unit-tests-java8 59.24% <87.50%> (+0.16%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@gaoxiaolei-s59 gaoxiaolei-s59 force-pushed the codex/fix-empty-return-type branch from dc45bda to f5889a1 Compare June 9, 2026 03:05
@zrlw

zrlw commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

@heliang666s PTAL

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] dubbo-maven-pluggin cannot successfully compile google.protobuf.Empty into 'void' keyword

3 participants