-
Notifications
You must be signed in to change notification settings - Fork 184
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
Move gRPC deadline details to new internal module #1501
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM after some minor comments
|
||
dependencies { | ||
implementation project(":servicetalk-annotations") | ||
implementation project(":servicetalk-concurrent-api") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
concurrent-api
is transitively taken through http-api
, no need to define its explicitly. In the past it caused more issues when the transitive dependency was defined explicitly.
@@ -0,0 +1,20 @@ | |||
//// | |||
* Copyright © 2021 Apple Inc. and the ServiceTalk project authors |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't see copyright at any other *.adoc
file we have. Do we need it here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since we can, might as well start adding it. I am not sure why it would not have been included previously.
Motivation: Some of the details of the gRPC deadline implementation need to be shared between the api and netty modules. The internal module can also be used for other implementation code that does not need to reside in the api module. Modifications: Creates gRPC internal module and moves some existing deadline related details to a new DeadlineUtils class. Includes new tests for timeout header parsing and generation. Result: Improved source organization for gRPC source.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Assume that the code was moved with minimal changes (didn't go through it in details), module structure LGTM after the last comments:
apply plugin: "io.servicetalk.servicetalk-gradle-plugin-internal-library" | ||
|
||
dependencies { | ||
api project(":servicetalk-annotations") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
servicetalk-annotations
is always implementation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK. It seems like it could be api
if anybody wanted to access the annotations at runtime, but I will make the change.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
implementation
gives users the dependency at runtime, api
gives it at compile time
dependencies { | ||
api project(":servicetalk-annotations") | ||
api project(":servicetalk-http-api") | ||
api "com.google.code.findbugs:jsr305:$jsr305Version" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same
There is one change for generating timeout header if the timeout durations greater than ~292 years that had been the original inspiration for moving this to a separate module and adding tests. |
Motivation: All public API breaking changes should be deferred until 0.41.0. Modifications: - Restore `grpc-api` that was removed in apple#1501. Result: No public API changes for 0.40.0.
Motivation: All public API breaking changes should be deferred until 0.41.0. Modifications: - Restore `grpc-api` that was removed in apple#1501. Result: No public API changes for 0.40.0.
Motivation:
Some of the details of the gRPC deadline implementation need to be
shared between the api and netty modules. The internal module can also
be used for other implementation code that does not need to reside in
the api module.
Modifications:
Creates gRPC internal module and moves some existing deadline related
details to a new DeadlineUtils class. Includes new tests for timeout
header parsing and generation.
Result:
Improved source organization for gRPC source.