Improving robustness; check response message size and add timeout (3 s).