Skip to content

Change to use OkHttp instead of TubeSock #13

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

Closed
rogerhu opened this issue Mar 20, 2017 · 6 comments
Closed

Change to use OkHttp instead of TubeSock #13

rogerhu opened this issue Mar 20, 2017 · 6 comments

Comments

@rogerhu
Copy link
Contributor

rogerhu commented Mar 20, 2017

TubeSockWebSocketClient library is being used. We should just standardize on OkHttp v3.6.0 (and possibly share instances between Parse/Parse Live Query?) One advantage is that we can use ParseLogHttpInterceptor to troubleshoot network requests.

@rogerhu
Copy link
Contributor Author

rogerhu commented Mar 23, 2017

#19

@jhansche
Copy link
Contributor

This may actually solve another problem I'm having, related to getting it to use the configured proxy server. Apparently TubeSock does not support the configured HTTP proxy, which makes it difficult to use with tools like Charles proxy.

OkHttp appears to use the system proxy automatically, so that would be helpful. @rogerhu is this something that we can test in our applications using the latest snapshots, or would we have to manually create the OkHttp websocket client in order to test it?

@jhansche
Copy link
Contributor

Looks like we can create a class in the com.parse package to hoist access to the ParseLiveQueryClientImpl constructor that takes a WebSocketClientFactory. Would be nice to make that a bit more accessible. I.e., by allowing a way to inject the default client factory instance, so that existing uses of ParseLiveQueryClient.getClient() will automatically use the injected websocket factory.

@rogerhu
Copy link
Contributor Author

rogerhu commented Mar 24, 2017

I'm going to change now. I really don't think we should be using TubeSocket especially since it is using the old Apache HttpClient which is no longer being supported by Android.

@rogerhu
Copy link
Contributor Author

rogerhu commented Mar 24, 2017

@jhansche
Copy link
Contributor

Added with #19; and tubesock removed with #28. Closing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants