mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
FIX: serialize post processing
This avoids all sorts of nasty race conditions in job schedular
This commit is contained in:
parent
c711c06bb8
commit
23b8a408f7
@ -16,11 +16,13 @@ class CookedPostProcessor
|
|||||||
end
|
end
|
||||||
|
|
||||||
def post_process(bypass_bump = false)
|
def post_process(bypass_bump = false)
|
||||||
keep_reverse_index_up_to_date
|
DistributedMutex.synchronize("post_process_#{@post.id}") do
|
||||||
post_process_images
|
keep_reverse_index_up_to_date
|
||||||
post_process_oneboxes
|
post_process_images
|
||||||
optimize_urls
|
post_process_oneboxes
|
||||||
pull_hotlinked_images(bypass_bump)
|
optimize_urls
|
||||||
|
pull_hotlinked_images(bypass_bump)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
def keep_reverse_index_up_to_date
|
def keep_reverse_index_up_to_date
|
||||||
|
Loading…
Reference in New Issue
Block a user