Commit 425d6e51 by Kunj Gupta

Increase read time for fetching the data.

parent b097e5ef
...@@ -30,7 +30,7 @@ public class RestClient { ...@@ -30,7 +30,7 @@ public class RestClient {
OkHttpClient.Builder httpClient = new OkHttpClient.Builder() OkHttpClient.Builder httpClient = new OkHttpClient.Builder()
.connectTimeout(10, TimeUnit.SECONDS) .connectTimeout(10, TimeUnit.SECONDS)
.writeTimeout(10, TimeUnit.SECONDS) .writeTimeout(10, TimeUnit.SECONDS)
.readTimeout(15, TimeUnit.SECONDS); .readTimeout(30, TimeUnit.SECONDS);
String credentials = username + ":" + password; String credentials = username + ":" + password;
final String basic = final String basic =
"Basic " + Base64.encodeToString(credentials.getBytes(), Base64.NO_WRAP); "Basic " + Base64.encodeToString(credentials.getBytes(), Base64.NO_WRAP);
...@@ -75,7 +75,7 @@ public class RestClient { ...@@ -75,7 +75,7 @@ public class RestClient {
OkHttpClient.Builder httpClient = new OkHttpClient.Builder() OkHttpClient.Builder httpClient = new OkHttpClient.Builder()
.connectTimeout(10, TimeUnit.SECONDS) .connectTimeout(10, TimeUnit.SECONDS)
.writeTimeout(10, TimeUnit.SECONDS) .writeTimeout(10, TimeUnit.SECONDS)
.readTimeout(15, TimeUnit.SECONDS); .readTimeout(30, TimeUnit.SECONDS);
// add your other interceptors // add your other interceptors
Interceptor interceptor = new Interceptor() { Interceptor interceptor = new Interceptor() {
@Override @Override
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment