Open yorkshire-pudding opened 2 months ago
I agree with the suggestion to be clearing caches when enabling/disabling maintenance mode šš¼ ...although I'd suggest to implement this as two submit buttons instead of adding a checkbox. So basically follow the same pattern as "Save" and "Save and configure" buttons, and keep the "Save configuration" button, but also add another "Save configuration and clear caches" button next to it.
Good idea @klonos
Description of the need
When maintenance mode is enabled, cached pages continue to be visible although non-cached page show the site in maintenance mode. This may well be the intended behaviour and in many cases, having some pages cached while a quick update is done could reduce the the number of 503 (Service Unavailable). However, it is not clear to site admins that this will happen. I was testing a module I'm porting and this behaviour intrigued me so I investigated the effects without the module and found the same.
Some use cases of maintenance mode might actually want the site to show as unavailable the whole time, and some may prefer the clarity of everything being offline rather than some pages being visible and others showing as unavailable.
I then found this issue (still unresolved) in the Drupal queue relating to modern Drupal: https://www.drupal.org/project/drupal/issues/2804387
I quite like the suggestion by "isa.bel"![image](https://github.com/backdrop/backdrop-issues/assets/20357797/157e9233-0ccb-41c6-ab7f-97f15cfe03ef)
but there is no consensus there.
Proposed solution
At least there should be some information to say that:
Possibly the text should change depending on whether cache is enabled or not?
I think it is user friendly to allow the site admin to clear the page cache as part of enabling maintenance mode, so it would be good to include this IMHO, but I fully accept, that like the Drupal issue, others may not agree.
Alternatives that have been considered
Describe alternatives you've considered. Have you seen this work in a better way in another CMS? Just looked at Drupal issue above.
Draft of feature description for Press Release (1 paragraph at most)
Backdrop now includes the option for site admins to clear the cache as part of enabling or disabling maintenance mode.