Use HTTP code 504 instead of the vague 500 (OMS-545)