mirror of
https://git.mirrors.martin98.com/https://github.com/actions/toolkit
synced 2026-05-04 14:08:05 +08:00
Merge remote-tracking branch 'refs/remotes/origin/pdotl-zstd-win-patch' into pdotl-zstd-win-patch
This commit is contained in:
2
packages/cache/src/internal/tar.ts
vendored
2
packages/cache/src/internal/tar.ts
vendored
@@ -3,7 +3,7 @@ import * as io from '@actions/io'
|
||||
import {existsSync, writeFileSync} from 'fs'
|
||||
import * as path from 'path'
|
||||
import * as utils from './cacheUtils'
|
||||
import {CompressionMethod, TarOperation} from './constants'
|
||||
import {CompressionMethod} from './constants'
|
||||
|
||||
const IS_WINDOWS = process.platform === 'win32'
|
||||
|
||||
|
||||
12
packages/cache/src/options.ts
vendored
12
packages/cache/src/options.ts
vendored
@@ -112,10 +112,22 @@ export function getDownloadOptions(copy?: DownloadOptions): DownloadOptions {
|
||||
result.segmentTimeoutInMs = copy.segmentTimeoutInMs
|
||||
}
|
||||
}
|
||||
const segmentDownloadTimeoutMins =
|
||||
process.env['SEGMENT_DOWNLOAD_TIMEOUT_MINS']
|
||||
|
||||
if (
|
||||
segmentDownloadTimeoutMins &&
|
||||
!isNaN(Number(segmentDownloadTimeoutMins)) &&
|
||||
isFinite(Number(segmentDownloadTimeoutMins))
|
||||
) {
|
||||
result.segmentTimeoutInMs = Number(segmentDownloadTimeoutMins) * 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 segment download timeout mins env var: ${process.env['SEGMENT_DOWNLOAD_TIMEOUT_MINS']}`
|
||||
)
|
||||
core.debug(`Segment download timeout (ms): ${result.segmentTimeoutInMs}`)
|
||||
|
||||
return result
|
||||
|
||||
Reference in New Issue
Block a user