- Increase the "requestReadTimeoutDuration" to 5 hours.
- Improve gradle's performance.
This commit is contained in:
parent
6c17e86c70
commit
8c1daadad0
|
@ -52,7 +52,7 @@ configurations {
|
|||
}
|
||||
|
||||
// Set increased lower and upper limits for the java-execution.
|
||||
tasks.withType(JavaExec) {
|
||||
tasks.withType(JavaExec).configureEach {
|
||||
jvmArgs = ['-Xms512m', '-Xmx8g']
|
||||
}
|
||||
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
# This script installs and runs the project.
|
||||
# It also sets the "max-heap-size", depending on the machine's memory.
|
||||
|
||||
# For error-handling, we cannot use the "set -e" since: it has problems https://mywiki.wooledge.org/BashFAQ/105
|
||||
# So we have our own function, for use when a single command fails.
|
||||
|
|
|
@ -38,7 +38,7 @@ public class AssignmentsHandler {
|
|||
private static String requestUrl;
|
||||
|
||||
private static final Duration requestConnectTimeoutDuration = Duration.ofMinutes(1); // 1 minute.
|
||||
private static final Duration requestReadTimeoutDuration = Duration.ofHours(3); // 3 hours. Time to wait for the data to get transferred over the network. Many workers may try to get assignments from the Worker, so each worker might have to wait some 10s of minutes for work.
|
||||
private static final Duration requestReadTimeoutDuration = Duration.ofHours(5); // 5 hours. Time to wait for the data to get transferred over the network. Many workers may try to get assignments from the Worker, so each worker might have to wait some 10s of minutes for work.
|
||||
// The controller has to retrieve the data from the database, then prepare them in memory, insert them in the "assignment"-table and, finally, return them to the worker.
|
||||
|
||||
public static final RestTemplate restTemplate = new RestTemplateBuilder().setConnectTimeout(requestConnectTimeoutDuration).setReadTimeout(requestReadTimeoutDuration).build();
|
||||
|
|
Loading…
Reference in New Issue