Issue #8592 - treat 504 as congestion (imported from 1.2/1.4)