Added custom user inputted timeout
This commit is contained in:
1 parent
d3dea8eb29
commit
43567c73a0
5 files changed
+36
-4
No files matched your search
@@ -112,10 +112,21 @@ export function getDownloadOptions(copy?: DownloadOptions): DownloadOptions {
|
||||
result.segmentTimeoutInMs = copy.segmentTimeoutInMs
|
||||
}
|
||||
}
|
||||
const customDownloadTimeoutMins = process.env['CACHE_DOWNLOAD_TIMEOUT_MINS']
|
||||
|
||||
if (
|
||||
customDownloadTimeoutMins &&
|
||||
!isNaN(Number(customDownloadTimeoutMins)) &&
|
||||
isFinite(Number(customDownloadTimeoutMins))
|
||||
) {
|
||||
result.segmentTimeoutInMs = Number(customDownloadTimeoutMins) * 60 * 1000
|
||||
}
|
||||
core.debug(`Use Azure SDK: ${result.useAzureSdk}`)
|
||||
core.debug(`Download concurrency: ${result.downloadConcurrency}`)
|
||||
core.debug(`Request timeout (ms): ${result.timeoutInMs}`)
|
||||
core.debug(
|
||||
`Cache download timeout mins env var: ${process.env['CACHE_DOWNLOAD_TIMEOUT_MINS']}`
|
||||
)
|
||||
core.debug(`Segment download timeout (ms): ${result.segmentTimeoutInMs}`)
|
||||
|
||||
return result
|
||||
|
||||
Reference in new issue
Block a user