Configuring Pulumi preview to respect state lock read locks for safe concurrent runs
0 reputation · 30 Nov 2025, 22:48 UTC
The Pulumi preview command acquires a read lock on the stack state when using a backend that supports locking (e.g., AWS S3 + DynamoDB). This allows multiple previews to run simultaneously but is intended to block concurrent update operations that require a write lock. The exact interaction between a running preview and an ongoing up operation is not fully documented, leaving uncertainty about which operation waits for the other and whether lock behavior can be adjusted.
Goal: clarify the lock compatibility between preview and up operations to determine if it is safe to run previews while updates are in progress, or to schedule multiple previews alongside updates without causing deadlocks or unexpected blocking.
Does a running pulumi preview block a subsequent pulumi up from acquiring the write lock? Does a running pulumi up block a pulumi preview from acquiring the read lock? Are there any backend or stack configuration options that modify this lock compatibility behavior?