|
|
|
@ -41808,7 +41808,8 @@ function getDownloadOptions(copy) {
|
|
|
|
|
useAzureSdk: true,
|
|
|
|
|
downloadConcurrency: 8,
|
|
|
|
|
timeoutInMs: 30000,
|
|
|
|
|
segmentTimeoutInMs: 3600000
|
|
|
|
|
segmentTimeoutInMs: 3600000,
|
|
|
|
|
dryRun: false
|
|
|
|
|
};
|
|
|
|
|
if (copy) {
|
|
|
|
|
if (typeof copy.useAzureSdk === 'boolean') {
|
|
|
|
@ -41823,6 +41824,9 @@ function getDownloadOptions(copy) {
|
|
|
|
|
if (typeof copy.segmentTimeoutInMs === 'number') {
|
|
|
|
|
result.segmentTimeoutInMs = copy.segmentTimeoutInMs;
|
|
|
|
|
}
|
|
|
|
|
if (typeof copy.dryRun === 'boolean') {
|
|
|
|
|
result.dryRun = copy.dryRun;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
const segmentDownloadTimeoutMins = process.env['SEGMENT_DOWNLOAD_TIMEOUT_MINS'];
|
|
|
|
|
if (segmentDownloadTimeoutMins &&
|
|
|
|
@ -41835,6 +41839,7 @@ function getDownloadOptions(copy) {
|
|
|
|
|
core.debug(`Request timeout (ms): ${result.timeoutInMs}`);
|
|
|
|
|
core.debug(`Cache segment download timeout mins env var: ${process.env['SEGMENT_DOWNLOAD_TIMEOUT_MINS']}`);
|
|
|
|
|
core.debug(`Segment download timeout (ms): ${result.segmentTimeoutInMs}`);
|
|
|
|
|
core.debug(`Dry run: ${result.dryRun}`);
|
|
|
|
|
return result;
|
|
|
|
|
}
|
|
|
|
|
exports.getDownloadOptions = getDownloadOptions;
|
|
|
|
@ -47283,6 +47288,10 @@ function restoreCache(paths, primaryKey, restoreKeys, options, enableCrossOsArch
|
|
|
|
|
// Cache not found
|
|
|
|
|
return undefined;
|
|
|
|
|
}
|
|
|
|
|
if (options === null || options === void 0 ? void 0 : options.dryRun) {
|
|
|
|
|
core.info('Dry run - skipping download');
|
|
|
|
|
return cacheEntry.cacheKey;
|
|
|
|
|
}
|
|
|
|
|
archivePath = path.join(yield utils.createTempDirectory(), utils.getCacheFileName(compressionMethod));
|
|
|
|
|
core.debug(`Archive Path: ${archivePath}`);
|
|
|
|
|
// Download the cache from the cache entry
|
|
|
|
|