{"action":"created","issue":{"url":"https://api.github.com/repos/GoogleCloudPlatform/google-cloud-dotnet/issues/640","repository_url":"https://api.github.com/repos/GoogleCloudPlatform/google-cloud-dotnet","labels_url":"https://api.github.com/repos/GoogleCloudPlatform/google-cloud-dotnet/issues/640/labels{/name}","comments_url":"https://api.github.com/repos/GoogleCloudPlatform/google-cloud-dotnet/issues/640/comments","events_url":"https://api.github.com/repos/GoogleCloudPlatform/google-cloud-dotnet/issues/640/events","html_url":"https://github.com/GoogleCloudPlatform/google-cloud-dotnet/pull/640","id":194804484,"number":640,"title":"NOT FOR SUBMISSION Signed URL resumable upload support","user":{"login":"evildour","id":4014815,"avatar_url":"https://avatars.githubusercontent.com/u/4014815?v=3","gravatar_id":"","url":"https://api.github.com/users/evildour","html_url":"https://github.com/evildour","followers_url":"https://api.github.com/users/evildour/followers","following_url":"https://api.github.com/users/evildour/following{/other_user}","gists_url":"https://api.github.com/users/evildour/gists{/gist_id}","starred_url":"https://api.github.com/users/evildour/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/evildour/subscriptions","organizations_url":"https://api.github.com/users/evildour/orgs","repos_url":"https://api.github.com/users/evildour/repos","events_url":"https://api.github.com/users/evildour/events{/privacy}","received_events_url":"https://api.github.com/users/evildour/received_events","type":"User","site_admin":false},"labels":[{"id":394156494,"url":"https://api.github.com/repos/GoogleCloudPlatform/google-cloud-dotnet/labels/Storage","name":"Storage","color":"0052cc","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":7,"created_at":"2016-12-11T00:56:46Z","updated_at":"2016-12-13T17:45:38Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/GoogleCloudPlatform/google-cloud-dotnet/pulls/640","html_url":"https://github.com/GoogleCloudPlatform/google-cloud-dotnet/pull/640","diff_url":"https://github.com/GoogleCloudPlatform/google-cloud-dotnet/pull/640.diff","patch_url":"https://github.com/GoogleCloudPlatform/google-cloud-dotnet/pull/640.patch"},"body":"(It might help to read [this section](https://cloud.google.com/storage/docs/access-control/signed-urls#signing-resumable) of docs for background)\r\n\r\nThe main thing needing review is the SignedUrlUploader class (which I'll comment and move to its own file if we decide to stick with it) and the way in which the user must create a the signed URL for the initial POST to kick off the resumable upload. I had a few choices here:\r\n1. Use the existing Sign methods and have a special http method named \"RESUMABLE\" that when specified, will set a special header needed for the upload and sign a URL for a POST method request instead. This is the route the gcloud SDK went with (see [here](https://cloud.google.com/storage/docs/gsutil/commands/signurl#usage)). The main drawback here is its not easily discoverable without reading the remarks.\r\n2. Use the existing Sign methods and let the user specify the POST method and we'll automatically add the special header. This might require breaking changes if we ever want to support other kinds of POST requests in the future (currently no other POST requests are possible with signed URLs though).\r\n3. Use the existing Sign methods, let the user specify POST, and also require that they specify the special header manually. This seems like extra boilerplate we shouldn't require the users to perform.\r\n4. Create new methods such as SignResumable perhaps. This would require 4 additional methods though which are mostly identical to the current methods.\r\n\r\nSo I opted for 1, but I'm open to changing this.\r\n\r\nNote that this requires a refactor of `ResumableUpload<TRequest>`, which I've split into a base `ResumableUpload` class and derived class. So @chrisdunelm, I've added you in case you want to look at those changes. However, keep in mind the refactor is kind of hacked together for now, but if we agree on this, I'll make the changes to google-api-dotnet-client in a much cleaner way. Once that's merged and published, I'll send out the real PR for resumable upload support."},"comment":{"url":"https://api.github.com/repos/GoogleCloudPlatform/google-cloud-dotnet/issues/comments/266809015","html_url":"https://github.com/GoogleCloudPlatform/google-cloud-dotnet/pull/640#issuecomment-266809015","issue_url":"https://api.github.com/repos/GoogleCloudPlatform/google-cloud-dotnet/issues/640","id":266809015,"user":{"login":"evildour","id":4014815,"avatar_url":"https://avatars.githubusercontent.com/u/4014815?v=3","gravatar_id":"","url":"https://api.github.com/users/evildour","html_url":"https://github.com/evildour","followers_url":"https://api.github.com/users/evildour/followers","following_url":"https://api.github.com/users/evildour/following{/other_user}","gists_url":"https://api.github.com/users/evildour/gists{/gist_id}","starred_url":"https://api.github.com/users/evildour/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/evildour/subscriptions","organizations_url":"https://api.github.com/users/evildour/orgs","repos_url":"https://api.github.com/users/evildour/repos","events_url":"https://api.github.com/users/evildour/events{/privacy}","received_events_url":"https://api.github.com/users/evildour/received_events","type":"User","site_admin":false},"created_at":"2016-12-13T17:45:38Z","updated_at":"2016-12-13T17:45:38Z","body":"Rebased and removed TmpMediaDownloader. It wasn't needed after all."}}
{"actor":{"display_login":"evildour"}}