added timeout to http.request