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

fix rest impl time #353

Merged
merged 10 commits into from Nov 7, 2018

Conversation

@leizhiyuan
Copy link
Contributor

commented Nov 6, 2018

Motivation:

add rest impl time

Modification:

Describe the idea and modifications you've done.

Result:

Fixes #.

If there is no issue then describe the changes introduced by this PR.

@leizhiyuan leizhiyuan requested a review from ujjboy Nov 6, 2018
// 补充服务端request和response大小
if (RpcInternalContext.isAttachmentEnable()) {
RpcInternalContext context = RpcInternalContext.getContext();
context.setAttachment(RpcConstants.INTERNAL_KEY_REQ_SIZE, requestContext.getLength());
context.setAttachment(RpcConstants.INTERNAL_KEY_RESP_SIZE, responseContext.getLength());
if (context != null) {

This comment has been minimized.

Copy link
@ujjboy

ujjboy Nov 6, 2018

Member

get操作不会返回null

This comment has been minimized.

Copy link
@leizhiyuan

leizhiyuan Nov 6, 2018

Author Contributor

改掉了.

@codecov

This comment has been minimized.

Copy link

commented Nov 6, 2018

Codecov Report

Merging #353 into 5.4 will decrease coverage by 0.49%.
The diff coverage is 86.36%.

Impacted file tree graph

@@             Coverage Diff             @@
##                5.4     #353     +/-   ##
===========================================
- Coverage     71.97%   71.48%   -0.5%     
+ Complexity      972      968      -4     
===========================================
  Files           346      346             
  Lines         14336    14350     +14     
  Branches       2302     2304      +2     
===========================================
- Hits          10319    10258     -61     
- Misses         2815     2891     +76     
+ Partials       1202     1201      -1
Impacted Files Coverage Δ Complexity Δ
...fa/rpc/tracer/sofatracer/log/tags/RpcSpanTags.java 0% <ø> (ø) 0 <0> (ø) ⬇️
.../java/com/alipay/sofa/rpc/common/RpcConstants.java 100% <ø> (ø) 0 <0> (ø) ⬇️
...cer/log/digest/RpcServerDigestSpanJsonEncoder.java 93.1% <100%> (ø) 0 <0> (ø) ⬇️
...cer/log/digest/RpcClientDigestSpanJsonEncoder.java 93.1% <100%> (ø) 0 <0> (ø) ⬇️
...ipay/sofa/rpc/server/rest/TraceResponseFilter.java 77.77% <66.66%> (-5.56%) 2 <0> (ø)
...a/rpc/transport/rest/TraceClientRequestFilter.java 72.72% <75%> (+1.29%) 3 <1> (ø) ⬇️
.../sofa/rpc/tracer/sofatracer/RestTracerAdapter.java 67.74% <85.71%> (+1.46%) 11 <0> (ø) ⬇️
.../rpc/transport/rest/SofaResteasyClientBuilder.java 62.96% <0%> (-25.93%) 0% <0%> (ø)
...ent/aft/impl/ServiceHorizontalMeasureStrategy.java 65.92% <0%> (-18.52%) 23% <0%> (-3%)
.../java/com/alipay/sofa/rpc/log/SLF4JLoggerImpl.java 81.81% <0%> (-18.19%) 0% <0%> (ø)
... and 15 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update dba0767...c0f0ac4. Read the comment docs.

@leizhiyuan leizhiyuan force-pushed the leizhiyuan:fix_rest_impl_time branch from 93f8dd5 to e8b6cf9 Nov 6, 2018
@khotyn

This comment has been minimized.

Copy link
Member

commented Nov 6, 2018

加一下 TestCase 吧。

leizhiyuan added 5 commits May 2, 2018
provide a TracerChecker to check tracer field.
@leizhiyuan leizhiyuan force-pushed the leizhiyuan:fix_rest_impl_time branch from 3d704c2 to 596daa6 Nov 7, 2018
leizhiyuan added 3 commits Nov 7, 2018
@NeGnail NeGnail merged commit 5eb9fb6 into sofastack:5.4 Nov 7, 2018
4 checks passed
4 checks passed
clahub All contributors have signed the Contributor License Agreement.
Details
codecov/patch 86.36% of diff hit (target 71.97%)
Details
codecov/project Absolute coverage decreased by -0.49% but relative coverage increased by +14.38% compared to dba0767
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@leizhiyuan leizhiyuan added this to the 5.4.8 milestone Nov 8, 2018
@leizhiyuan leizhiyuan deleted the leizhiyuan:fix_rest_impl_time branch Nov 9, 2018
ujjboy added a commit that referenced this pull request Nov 30, 2018
treenewtreenew added a commit to treenewtreenew/sofa-rpc that referenced this pull request Oct 7, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.