pulsar icon indicating copy to clipboard operation
pulsar copied to clipboard

[fix][admin] Map empty content to null

Open nodece opened this issue 1 year ago • 1 comments

Motivation

When using asyncResponse.resume(null) to write data to the admin, we will get an empty content, not null.

Please see the Jersey implementation: https://github.com/eclipse-ee4j/jersey/blob/2.34/core-server/src/main/java/org/glassfish/jersey/server/ServerRuntime.java#L603-L610

Modifications

In the asyncGetRequest method, when the content is empty, use null as the completion value.

Documentation

  • [ ] doc
  • [ ] doc-required
  • [x] doc-not-needed
  • [ ] doc-complete

nodece avatar Jan 31 '24 16:01 nodece

Codecov Report

Attention: Patch coverage is 57.14286% with 6 lines in your changes are missing coverage. Please review.

Project coverage is 71.85%. Comparing base (a702e5a) to head (5639be7). Report is 56 commits behind head on master.

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff              @@
##             master   #22008      +/-   ##
============================================
- Coverage     73.48%   71.85%   -1.63%     
+ Complexity    32465    32281     -184     
============================================
  Files          1863     1877      +14     
  Lines        138812   147777    +8965     
  Branches      15215    17345    +2130     
============================================
+ Hits         102003   106184    +4181     
- Misses        28921    33161    +4240     
- Partials       7888     8432     +544     
Flag Coverage Δ
inttests 27.18% <0.00%> (?)
systests 24.21% <21.42%> (+0.30%) :arrow_up:
unittests 70.99% <57.14%> (-1.89%) :arrow_down:

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

Files Coverage Δ
...che/pulsar/client/admin/internal/BaseResource.java 76.27% <57.14%> (-2.05%) :arrow_down:

... and 182 files with indirect coverage changes

codecov-commenter avatar Feb 06 '24 03:02 codecov-commenter