mirror of
https://github.com/github/codeql-action.git
synced 2026-04-17 12:33:16 +00:00
Respect scaling_reserved_ram feature flag
The amount of RAM given to the CodeQL evaluator is the machine's total memory size, minus a reserved amount. Currently, the reserved amount is fixed at 1 GB (or 1.5 GB on Windows). When the scaling_reserved_ram feature flag is enabled, we also add 2% of the total memory size to the reserved amount. This allows for the fact that the kernel will consume more RAM (e.g. for page tables) on machines with more physical RAM.
This commit is contained in:
@@ -39,6 +39,7 @@ export enum Feature {
|
||||
MlPoweredQueriesEnabled = "ml_powered_queries_enabled",
|
||||
NewAnalysisSummaryEnabled = "new_analysis_summary_enabled",
|
||||
QaTelemetryEnabled = "qa_telemetry_enabled",
|
||||
ScalingReservedRam = "scaling_reserved_ram",
|
||||
UploadFailedSarifEnabled = "upload_failed_sarif_enabled",
|
||||
}
|
||||
|
||||
@@ -76,6 +77,11 @@ export const featureConfig: Record<
|
||||
minimumVersion: undefined,
|
||||
defaultValue: false,
|
||||
},
|
||||
[Feature.ScalingReservedRam]: {
|
||||
envVar: "CODEQL_ACTION_SCALING_RESERVED_RAM",
|
||||
minimumVersion: undefined,
|
||||
defaultValue: false,
|
||||
},
|
||||
[Feature.UploadFailedSarifEnabled]: {
|
||||
envVar: "CODEQL_ACTION_UPLOAD_FAILED_SARIF",
|
||||
minimumVersion: "2.11.3",
|
||||
|
||||
Reference in New Issue
Block a user