-
Notifications
You must be signed in to change notification settings - Fork 16
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
Implement an OkHttpChannels factory class #355
Conversation
Generate changelog in
|
dialogue-okhttp-client/src/main/java/com/palantir/dialogue/OkHttpChannels.java
Outdated
Show resolved
Hide resolved
dialogue-okhttp-client/src/main/java/com/palantir/dialogue/OkHttpChannels.java
Show resolved
Hide resolved
.dispatcher(dispatcher) | ||
.connectionPool(connectionPool) | ||
.followRedirects(false) // We implement our own redirect logic. | ||
.sslSocketFactory(config.sslSocketFactory(), config.trustManager()) |
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.
have we lost the KeepAliveSslSocketFactory here? Maybe we should just make it public in c-j-r?
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.
That's correct, this doesn't record client tls handshake metrics or set keepalive. Agree that we should be consistent across all clients.
dialogue-okhttp-client/src/main/java/com/palantir/dialogue/OkHttpChannels.java
Show resolved
Hide resolved
442f023
to
b718b48
Compare
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 - don't think the KeepAliveSocketFactory thing should be a blocker
I've enabled keep-alive on the apache hc implementation in #335 :-) |
Before this PR
Difficult to make an okhttp based channel.
After this PR
==COMMIT_MSG==
Implement an OkHttpChannels factory class based on CJR without duplicated functionality.
==COMMIT_MSG==
Possible downsides?
We don't really want to use okhttp, but it's helpful to have a class to compare with.