应该将哪个网络库用于Google云端点

时间:2021-06-06 20:20:25

I am building an android application with back-end on Google App Engine. I want to use google cloud endpoint for rest APIs. Is it possible to use any other network library on client side other than Google HTTP Client API? If yes, what network library should I use to make my network calls light and fast? Other possible network libraries are Retrofit, Volley, OkHttp.

我正在使用Google App Engine上的后端构建一个Android应用程序。我想将谷歌云端点用于其他API。是否可以在客户端使用除Google HTTP Client API之外的任何其他网络库?如果是,我应该使用什么网络库来使我的网络呼叫轻松快速?其他可能的网络库是Retrofit,Volley,OkHttp。

1 个解决方案

#1


1  

The main answer is 'yes'. Using Google's http client for cloud endpoints does not restrict your other networking in any way. You could even, for example, use one of those other libraries in the same Android app, and to communicate with the same server app (through a different servlet in the same app).

主要答案是'是'。将Google的http客户端用于云端点不会以任何方式限制您的其他网络。例如,您甚至可以在同一Android应用程序中使用其他库中的一个,并与同一服务器应用程序通信(通过同一应用程序中的不同servlet)。

Regarding the choice between Retrofit, Volley, OkHttp, etc., questions like that are not considered suitable for * because it is really a matter of preference, and pros and cons. SO is for questions that have a right answer.

关于Retrofit,Volley,OkHttp等之间的选择,类似的问题不适合*,因为它确实是一个偏好,优点和缺点。 SO适用于有正确答案的问题。

#1


1  

The main answer is 'yes'. Using Google's http client for cloud endpoints does not restrict your other networking in any way. You could even, for example, use one of those other libraries in the same Android app, and to communicate with the same server app (through a different servlet in the same app).

主要答案是'是'。将Google的http客户端用于云端点不会以任何方式限制您的其他网络。例如,您甚至可以在同一Android应用程序中使用其他库中的一个,并与同一服务器应用程序通信(通过同一应用程序中的不同servlet)。

Regarding the choice between Retrofit, Volley, OkHttp, etc., questions like that are not considered suitable for * because it is really a matter of preference, and pros and cons. SO is for questions that have a right answer.

关于Retrofit,Volley,OkHttp等之间的选择,类似的问题不适合*,因为它确实是一个偏好,优点和缺点。 SO适用于有正确答案的问题。