When MediaWiki sends the PURGE request to a CDN, it waits for a response before proceeding to respond to the client. If the CDN takes a moment to respond, this makes saving pages take longer.
It's become an issue for us after we implemented wildcard cache purging with Nginx,[1] to make sure that saving a page purges both the desktop and mobile versions, and both GET and HEAD responses. Nginx takes up to several seconds to process these PURGE requests.
It's been pointed out to me that the MW code explicitly requests this synchronicity by using PRESEND instead of POSTSEND in HTMLCacheUpdater.php.[2] We weren't able to tell why this choice was made. There's a large comment in the commit adding HTMLCacheUpdater, that explains why it's deferred,[3] but it's not clear if it needs to be PRESEND.
I've been told @aaron may know more. Thanks to @Bawolff for the pointers.
[1] https://www.mediawiki.org/wiki/Manual:Nginx_caching
[2] https://github.com/wikimedia/mediawiki/blob/master/includes/cache/HTMLCacheUpdater.php#L187
[3] https://github.com/wikimedia/mediawiki/commit/35da1bbd7cb8b4414c4fbcf331473f1024bc638d