Module constants

Module constants 

Source
Expand description

Global constants used throughout the AGPM codebase.

This module contains timeout durations, retry parameters, and other numeric constants that are used across multiple modules. Defining them centrally improves maintainability and makes magic numbers more discoverable.

Constants§

DEFAULT_LOCK_TIMEOUT
Legacy constant for backwards compatibility - prefer default_lock_timeout() function.
FALLBACK_CORE_COUNT
Default CPU core count when detection fails.
GIT_CLONE_TIMEOUT
Timeout for Git clone operations (120 seconds).
GIT_FETCH_TIMEOUT
Timeout for Git fetch operations (60 seconds).
GIT_WORKTREE_TIMEOUT
Timeout for Git worktree creation (60 seconds).
MAX_BACKOFF_DELAY_MS
Maximum backoff delay for exponential backoff (500ms).
MIN_PARALLELISM
Minimum number of parallel operations regardless of CPU count.
PARALLELISM_CORE_MULTIPLIER
Multiplier applied to CPU core count for default parallelism.
PENDING_STATE_TIMEOUT
Legacy constant for backwards compatibility - prefer pending_state_timeout() function.
STARTING_BACKOFF_DELAY_MS
Starting delay for exponential backoff (10ms).

Functions§

batch_operation_timeout
Timeout for batch operations using join_all (5 minutes).
default_lock_timeout
Default timeout for cache lock acquisition (120 seconds).
pending_state_timeout
Timeout for pending operations (10 seconds).