{"action":"created","issue":{"url":"https://api.github.com/repos/MarcusBarnes/mik/issues/3","labels_url":"https://api.github.com/repos/MarcusBarnes/mik/issues/3/labels{/name}","comments_url":"https://api.github.com/repos/MarcusBarnes/mik/issues/3/comments","events_url":"https://api.github.com/repos/MarcusBarnes/mik/issues/3/events","html_url":"https://github.com/MarcusBarnes/mik/issues/3","id":73161392,"number":3,"title":"Make HTTP requests more robusts against network connectivity and latency issues","user":{"login":"MarcusBarnes","id":938274,"avatar_url":"https://avatars.githubusercontent.com/u/938274?v=3","gravatar_id":"","url":"https://api.github.com/users/MarcusBarnes","html_url":"https://github.com/MarcusBarnes","followers_url":"https://api.github.com/users/MarcusBarnes/followers","following_url":"https://api.github.com/users/MarcusBarnes/following{/other_user}","gists_url":"https://api.github.com/users/MarcusBarnes/gists{/gist_id}","starred_url":"https://api.github.com/users/MarcusBarnes/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MarcusBarnes/subscriptions","organizations_url":"https://api.github.com/users/MarcusBarnes/orgs","repos_url":"https://api.github.com/users/MarcusBarnes/repos","events_url":"https://api.github.com/users/MarcusBarnes/events{/privacy}","received_events_url":"https://api.github.com/users/MarcusBarnes/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/MarcusBarnes/mik/labels/enhancement","name":"enhancement","color":"84b6eb"}],"state":"open","locked":false,"assignee":{"login":"mjordan","id":403918,"avatar_url":"https://avatars.githubusercontent.com/u/403918?v=3","gravatar_id":"","url":"https://api.github.com/users/mjordan","html_url":"https://github.com/mjordan","followers_url":"https://api.github.com/users/mjordan/followers","following_url":"https://api.github.com/users/mjordan/following{/other_user}","gists_url":"https://api.github.com/users/mjordan/gists{/gist_id}","starred_url":"https://api.github.com/users/mjordan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mjordan/subscriptions","organizations_url":"https://api.github.com/users/mjordan/orgs","repos_url":"https://api.github.com/users/mjordan/repos","events_url":"https://api.github.com/users/mjordan/events{/privacy}","received_events_url":"https://api.github.com/users/mjordan/received_events","type":"User","site_admin":false},"milestone":null,"comments":10,"created_at":"2015-05-05T00:01:33Z","updated_at":"2015-12-18T15:46:38Z","closed_at":null,"body":"Currently, MIK is uses several methods that use the [file_get_contents] (http://php.net/manual/en/function.file-get-contents.php) function.  This makes MIK particularly susceptible to network connectivity (say, if the network cuts out momentarily) and latency issues for larger collections.  Below are some suggestions for approaches that may make MIK more robust against these network issues when reading remote files:\r\n\r\n* Use [Guzzle](http://docs.guzzlephp.org/en/latest/) - a PHP HTTP client and framework for consuming RESTful web services\r\n* Use [cURL](http://php.net/manual/en/book.curl.php) for its enhanced error reporting, and add appropriate logic and logging to make error handling more robust.\r\n* Investigate how Drupal's  [drupal_http_request](https://api.drupal.org/api/drupal/includes!common.inc/function/drupal_http_request/7) function was implemented for ideas on how to create more robust file request methods within MIK.\r\n\r\nOther suggestions are welcome.  Please comment below."},"comment":{"url":"https://api.github.com/repos/MarcusBarnes/mik/issues/comments/165811547","html_url":"https://github.com/MarcusBarnes/mik/issues/3#issuecomment-165811547","issue_url":"https://api.github.com/repos/MarcusBarnes/mik/issues/3","id":165811547,"user":{"login":"mjordan","id":403918,"avatar_url":"https://avatars.githubusercontent.com/u/403918?v=3","gravatar_id":"","url":"https://api.github.com/users/mjordan","html_url":"https://github.com/mjordan","followers_url":"https://api.github.com/users/mjordan/followers","following_url":"https://api.github.com/users/mjordan/following{/other_user}","gists_url":"https://api.github.com/users/mjordan/gists{/gist_id}","starred_url":"https://api.github.com/users/mjordan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mjordan/subscriptions","organizations_url":"https://api.github.com/users/mjordan/orgs","repos_url":"https://api.github.com/users/mjordan/repos","events_url":"https://api.github.com/users/mjordan/events{/privacy}","received_events_url":"https://api.github.com/users/mjordan/received_events","type":"User","site_admin":false},"created_at":"2015-12-18T15:46:38Z","updated_at":"2015-12-18T15:46:38Z","body":"Done in 169597c1615de0ab015491937be2ff3843098cca. I think we can merge issue-3 into master and close this issue. @MarcusBarnes any reason not to do that?"}}