From fb1dd3d79c215918748b2a3813922805e9f97568 Mon Sep 17 00:00:00 2001 From: August Miller Date: Thu, 4 Jan 2024 15:01:37 -0800 Subject: [PATCH] Default mutex driver --- docs/4.x/config/app.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/docs/4.x/config/app.md b/docs/4.x/config/app.md index 91514a3ea..9dd2dda59 100644 --- a/docs/4.x/config/app.md +++ b/docs/4.x/config/app.md @@ -452,13 +452,13 @@ If your queue driver supplies its own worker, set the , which means it will work natively in [load-balanced environments](kb:configuring-load-balanced-environments#mutex-locks). -::: tip -A [NullMutex](craft4:craft\mutex\NullMutex) driver is used when Dev Mode is enabled, since mutex drivers aren’t necessary for local development and we’ve seen issues with mutex in some Windows and Linux filesystems. +::: warning +Prior to 4.6, enabling `devMode` would automatically switch from the default `FileMutex` driver to a special `NullMutex` driver to help avoid some virtualization bugs. Now, `NullMutex` is only used when a database connection is not available (i.e. prior to installation). ::: -You can configure a custom mutex driver by configuring the `mutex` component’s nested `$mutex` property: +You can configure a custom mutex driver by overriding the `mutex` component’s nested `$mutex` property: ```php // Use mutex driver provided by yii2-redis @@ -487,7 +487,7 @@ return [ ``` ::: warning -Pay careful attention to the structure, here—we’re only modifying the existing component’s `mutex` _property_ and leaving the rest of its config as-is. +Pay careful attention to the structure of the configuration object: we’re only modifying the existing `mutex` component’s nested _driver_ property and leaving the rest of its config as-is. The mutex _component_ should always be an instance of , ::: ## Modules