The discussion explores how auto-closing works when enabled in a category. one1 asks whether existing old posts are immediately closed when the setting is turned on and whether changing the auto-close time reopens closed topics. jahan_gagan clarifies that auto-close only applies to new topics by default, and existing topics are not affected unless a rake task (rake topics:apply_autoclose) is run to apply it to older posts. This background process may take time but is designed to minimize performance impact. Changing the auto-close time does not reopen previously closed topics, and there is no bulk re-open option in the UI, though scripts can be used to reopen them. one1 thanks jahan_gagan for the clarification and acknowledges missing the referenced post.
Stel dat je veel heel oude berichten hebt die in aanmerking komen om automatisch te worden gesloten zodra je die instelling inschakelt voor een categorie. Wanneer je de instelling inschakelt, laten we zeggen, om berichten na 5 jaar van inactiviteit automatisch te sluiten, wanneer worden al die berichten dan automatisch gesloten? Zodra je op opslaan klikt? Of is er een automatische opruiming die op de achtergrond plaatsvindt. Is dat waarschijnlijk om prestatieproblemen te veroorzaken?
En tweede vraag, gaan berichten die automatisch zijn gesloten weer open als je de tijd op de categorie wijzigt? Ik neem aan van niet. Ik neem ook aan dat er geen gemakkelijke manier is via de interface om in bulk te heropenen. Klopt dat?
By default, the auto-close setting on a category only applies to newly created topics.
Existing topics are not auto-closed as soon as you save the setting. They will remain open unless you explicitly apply the auto-close to them.
There is a dedicated script (rake topics:apply_autoclose) that can be run via the server console to apply the auto-close timer to existing topics. This script silently closes qualifying topics (those old enough, based on your setting), minimizing notifications.
Applying the setting to all old topics at once using the script is a background operation. If you have a very large community and many old topics, it may take some time, but it runs server-side. Performance impact varies depending on hosting and topic count, but the rake task is designed for bulk actions and should not severely affect healthy, well-provisioned Discourse sites.
Discussion on the same is here:
Changing the auto-close time does NOT reopen topics that were already closed (i.e., closure is not reversed).
There is no built-in user interface option to bulk re-open closed topics.
However, you can use a script or a Rails console command to reopen topics in bulk.
Topic.where(closed: true).where("created_at < 'your_date'").find_each do |topic|
topic.update_status('closed', false, Discourse.system_user)
end