Title: Make gcloud.storage use a streaming HTTP library for downloads · Issue #11 · googleapis/google-cloud-python · GitHub
Open Graph Title: Make gcloud.storage use a streaming HTTP library for downloads · Issue #11 · googleapis/google-cloud-python
X Title: Make gcloud.storage use a streaming HTTP library for downloads · Issue #11 · googleapis/google-cloud-python
Description: Right now we're using httplib2 because of oauth2client working really nicely with that, however httplib2 doesn't support a streaming download. This means, a .request() will load the entire response content into memory, which won't work a...
Open Graph Description: Right now we're using httplib2 because of oauth2client working really nicely with that, however httplib2 doesn't support a streaming download. This means, a .request() will load the entire response...
X Description: Right now we're using httplib2 because of oauth2client working really nicely with that, however httplib2 doesn't support a streaming download. This means, a .request() will load the entire ...
Opengraph URL: https://github.com/googleapis/google-cloud-python/issues/11
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Make gcloud.storage use a streaming HTTP library for downloads","articleBody":"Right now we're using `httplib2` because of `oauth2client` working really nicely with that, however `httplib2` doesn't support a streaming download.\n\nThis means, a `.request()` will load the entire response content into memory, which won't work at all for a big file.\n\nTo get around this, we chunk the file up using the Range HTTP header and request pieces of it until the end, however the better way to handle this is with a streaming HTTP library:\n\n``` python\nstream = \u003csend http request\u003e\nwith open('output.txt', 'wb') as output:\n data = stream.read(CHUNK_SIZE)\n while data:\n output.write(data)\n data = stream.read(CHUNK_SIZE)\n```\n\nTo make this work we need to:\n- [ ] use a library that does support streaming\n- [ ] update `oauth2client` to work with that library\n","author":{"url":"https://github.com/jgeewax","@type":"Person","name":"jgeewax"},"datePublished":"2014-02-05T17:30:49.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":2},"url":"https://github.com/11/google-cloud-python/issues/11"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:b9545d8e-5610-264f-bd2c-fcc74eb8cff7 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | E35C:FD8C5:DAE5DD:12BB7F4:6A4DCECB |
| html-safe-nonce | 52b047f9d8d0c0e213ebd2c22259d04813434edfc1ba34bab33ef5ca77cef0de |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFMzVDOkZEOEM1OkRBRTVERDoxMkJCN0Y0OjZBNERDRUNCIiwidmlzaXRvcl9pZCI6IjU1NzM5Mjk4ODc2MTYzMjMyNzUiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 2d307707cbc5e64975743d63797adc5def335f331db0fde3a772cb0ff46031b8 |
| hovercard-subject-tag | issue:26981082 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/googleapis/google-cloud-python/11/issue_layout |
| twitter:image | https://opengraph.githubassets.com/8d7d248544b2d3ab548f871d7dcd4680ee8c4e928b08326e2e520d277a623c3d/googleapis/google-cloud-python/issues/11 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/8d7d248544b2d3ab548f871d7dcd4680ee8c4e928b08326e2e520d277a623c3d/googleapis/google-cloud-python/issues/11 |
| og:image:alt | Right now we're using httplib2 because of oauth2client working really nicely with that, however httplib2 doesn't support a streaming download. This means, a .request() will load the entire response... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | jgeewax |
| hostname | github.com |
| expected-hostname | github.com |
| None | 06b8a6144231bf3a234f1c2e9993861e07ce98a905912b114aa386c2d7e84b33 |
| turbo-cache-control | no-preview |
| go-import | github.com/googleapis/google-cloud-python git https://github.com/googleapis/google-cloud-python.git |
| octolytics-dimension-user_id | 16785467 |
| octolytics-dimension-user_login | googleapis |
| octolytics-dimension-repository_id | 16316451 |
| octolytics-dimension-repository_nwo | googleapis/google-cloud-python |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 16316451 |
| octolytics-dimension-repository_network_root_nwo | googleapis/google-cloud-python |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 1d344bdb7547fe6bca17a59bb2b8aac3dc9532a0 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width