[misc] Updated code using the old commons-httpclient with the new httpcomponents