MULE-8018: Merge http connector code cleanup

Will add a test case with a big payload. That's the only scenario missing for transfer- encoding.