Creates a process-level mutex to prevent concurrent pak operations that could
cause cache corruption. Uses operation-specific locks for better concurrency.
Usage
acquire_pak_mutex(operation_type = "install", timeout_seconds = 120L)
Arguments
- operation_type
(character)
Type of operation: "install", "download", "cache_write"
- timeout_seconds
(integer)
Maximum time to wait for lock in seconds (default: 120L)
Value
Path to mutex file if acquired successfully
Details
Automatically cleans up stale locks older than 5 minutes