feat: Adds RestTemplate default ConnectTimeout / ConnectRequestTimeout - #4148
Conversation
Codecov ReportBase: 55.61% // Head: 55.52% // Decreases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## 3.1.x #4148 +/- ##
============================================
- Coverage 55.61% 55.52% -0.09%
- Complexity 529 534 +5
============================================
Files 58 59 +1
Lines 2503 2534 +31
Branches 236 239 +3
============================================
+ Hits 1392 1407 +15
- Misses 1023 1038 +15
- Partials 88 89 +1
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
|
Wrote related code to explicitly declare custom timeouts in |
4d9c371 to
c4b0204
Compare
OlgaMaciaszek
left a comment
There was a problem hiding this comment.
@kworkbee Thanks a lot for submitting this PR. In general, it looks good, but there are a few minor issues. I've added comments - please address them. Also, since this contains breaking changes (method signature and constructor changes), we'd need to move them to 2022.x only (submitting against main branch - we're realeasing GA on the 14th, so it'd need to be done soon). If you want this to be made available also for the 2021.x release train (3.1.x branch), that's fine by me, but you'll need to make it backwards compatible (i.e., just adding new constructors and method signatures while deprecating the old ones, withou editing or removing existing public members).
This comment was marked as off-topic.
This comment was marked as off-topic.
- eureka.client.rest-template-timeout Fixes spring-cloudgh-4110
|
@OlgaMaciaszek Thank you for your code review. In addition to the feedback you gave me, I rewritten the code to keep the code cleaner, so please review it. If possible, I hope it will be reflected in the upcoming release. P.S. This is my first time to contribute, so I'm very nervous but so much excited! |
|
Because Configuration Properties declaration moved, I removed the test in the existing test class. Is it a big problem for the 'codecov/project' error to occur as you can see? |
OlgaMaciaszek
left a comment
There was a problem hiding this comment.
@kworkbee thanks for your contribution; its' a good enhancement :) . Please address the comments I've added for the new implementation.
No, the delta threshold is set too high. We should change it in future. I don't think this change requires additional tests. |
|
Again, modifies code. |
OlgaMaciaszek
left a comment
There was a problem hiding this comment.
Thanks @kworkbee, this is getting close to merge now. There's one more minor change left in the code - please see the comment. Also, please document the new functionality in spring-cloud-netflix.adoc (There's a phrase that sais: "If you want to customize the RestTemplate used by the Eureka HTTP Client you may want to create a bean of EurekaClientHttpRequestFactorySupplier and provide your own logic for generating a ClientHttpRequestFactory instance." - you can document your feature directly after that).
OlgaMaciaszek
left a comment
There was a problem hiding this comment.
Thanks, @kworkbee. LGTM.
|
Thank you. It was a good experience. |
|
Thanks for contributing. |
Fixes gh-4110