Skip to content

Commit

Permalink
Merge pull request #33031 from vespa-engine/hmusum/reduce-file-downlo…
Browse files Browse the repository at this point in the history
…ader-timeout

Reduce FileDownloader timeout in maintainer
  • Loading branch information
hmusum authored Dec 12, 2024
2 parents 3b8c00e + f076feb commit 8900f89
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@
public class ApplicationPackageMaintainer extends ConfigServerMaintainer {

private static final Logger log = Logger.getLogger(ApplicationPackageMaintainer.class.getName());
private static final Duration fileDownloaderTimeout = Duration.ofSeconds(30);

private final File downloadDirectory;
private final Supervisor supervisor = new Supervisor(new Transport("filedistribution-pool")).setDropEmptyBuffers(true);
Expand Down Expand Up @@ -126,7 +127,7 @@ private static FileDownloader createFileDownloader(ApplicationRepository applica
List<String> otherConfigServersInCluster = getOtherConfigServersInCluster(applicationRepository.configserverConfig());
ConfigSourceSet configSourceSet = new ConfigSourceSet(otherConfigServersInCluster);
ConnectionPool connectionPool = new FileDistributionConnectionPool(configSourceSet, supervisor);
return new FileDownloader(connectionPool, supervisor, downloadDirectory, Duration.ofSeconds(60));
return new FileDownloader(connectionPool, supervisor, downloadDirectory, fileDownloaderTimeout);
}

@Override
Expand Down

0 comments on commit 8900f89

Please sign in to comment.