{"action":"created","issue":{"url":"https://api.github.com/repos/rusoto/rusoto/issues/212","repository_url":"https://api.github.com/repos/rusoto/rusoto","labels_url":"https://api.github.com/repos/rusoto/rusoto/issues/212/labels{/name}","comments_url":"https://api.github.com/repos/rusoto/rusoto/issues/212/comments","events_url":"https://api.github.com/repos/rusoto/rusoto/issues/212/events","html_url":"https://github.com/rusoto/rusoto/pull/212","id":146528159,"number":212,"title":"[WIP] Implement Elastic Transcoder Support","user":{"login":"indiv0","id":641547,"avatar_url":"https://avatars.githubusercontent.com/u/641547?v=3","gravatar_id":"","url":"https://api.github.com/users/indiv0","html_url":"https://github.com/indiv0","followers_url":"https://api.github.com/users/indiv0/followers","following_url":"https://api.github.com/users/indiv0/following{/other_user}","gists_url":"https://api.github.com/users/indiv0/gists{/gist_id}","starred_url":"https://api.github.com/users/indiv0/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/indiv0/subscriptions","organizations_url":"https://api.github.com/users/indiv0/orgs","repos_url":"https://api.github.com/users/indiv0/repos","events_url":"https://api.github.com/users/indiv0/events{/privacy}","received_events_url":"https://api.github.com/users/indiv0/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2016-04-07T07:10:43Z","updated_at":"2016-04-07T07:20:51Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/rusoto/rusoto/pulls/212","html_url":"https://github.com/rusoto/rusoto/pull/212","diff_url":"https://github.com/rusoto/rusoto/pull/212.diff","patch_url":"https://github.com/rusoto/rusoto/pull/212.patch"},"body":"**THIS IS A WORK IN PROGRESS**\r\n\r\nI'm interested in implementing Elastic Transcoder support (as I need it for a personal project), so I've begun a PR for it.\r\n\r\nI'll post updates and questions here as I work on it.\r\n\r\n# Current Status\r\n\r\n* [x] Add `ets` feature to `Cargo.toml`\r\n* [x] Generate `elastictranscoder` `Service` in `build.rs`\r\n* [ ] Implement `rest-json` generator\r\n    * [x] Add `rest-json` generator\r\n    * [x] Add `request_uri` format code generator function\r\n    * [ ] Add `querystring` format code generator function\r\n    * [ ] Verify it works against minimum subset of `Ets` operations\r\n        * [ ] `read_job` (**Partial**)\r\n            * This only works if the payload is not added to the request because adding a payload adds a `content-length` header, which causes the request to stall\r\n        * [x] `create_job`\r\n        * ...?\r\n* [ ] Add tests\r\n* ...?\r\n\r\n# Notes\r\n\r\n* `HttpError`\r\n    * `code` is now `Option<String>` because `HttpError`s for `Ecs` don't specify it\r\n* `Metadata`\r\n    * `service_abbreviation` is now `Option<String>` because `Ecs` doesn't specify it\r\n* `generator`\r\n    * `generate_protocol` now has a match statement to retrieve the `service_abbreviation` since it's now an `Option<String>`\r\n\r\n# Resources\r\n\r\n* AWS\r\n    * [Create Job - Amazon Elastic Transcoder][create-job]\r\n    * [Read Job - Amazon Elastic Transcoder][read-job]\r\n    * [Making HTTP Requests to Elastic Transcoder][making-http-requests]\r\n    * [AWS CLI Reference - Elastic Transcoder][aws-ets-reference]\r\n* botocore\r\n    * [botocore - 2012-09-25/service-2.json][botocore-ets]\r\n    * [botocore - serialize.py][botocore-serialize]\r\n\r\n[aws-ets-reference]: http://docs.aws.amazon.com/cli/latest/reference/elastictranscoder/index.html\r\n[botocore-ets]: https://github.com/boto/botocore/blob/develop/botocore/data/elastictranscoder/2012-09-25/service-2.json\r\n[botocore-serialize]: https://github.com/boto/botocore/blob/master/botocore/serialize.py\r\n[create-job]: http://docs.aws.amazon.com/elastictranscoder/latest/developerguide/create-job.html\r\n[making-http-requests]: http://docs.aws.amazon.com/elastictranscoder/latest/developerguide/making-http-requests.html\r\n[read-job]: http://docs.aws.amazon.com/elastictranscoder/latest/developerguide/get-job.html"},"comment":{"url":"https://api.github.com/repos/rusoto/rusoto/issues/comments/206732721","html_url":"https://github.com/rusoto/rusoto/pull/212#issuecomment-206732721","issue_url":"https://api.github.com/repos/rusoto/rusoto/issues/212","id":206732721,"user":{"login":"indiv0","id":641547,"avatar_url":"https://avatars.githubusercontent.com/u/641547?v=3","gravatar_id":"","url":"https://api.github.com/users/indiv0","html_url":"https://github.com/indiv0","followers_url":"https://api.github.com/users/indiv0/followers","following_url":"https://api.github.com/users/indiv0/following{/other_user}","gists_url":"https://api.github.com/users/indiv0/gists{/gist_id}","starred_url":"https://api.github.com/users/indiv0/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/indiv0/subscriptions","organizations_url":"https://api.github.com/users/indiv0/orgs","repos_url":"https://api.github.com/users/indiv0/repos","events_url":"https://api.github.com/users/indiv0/events{/privacy}","received_events_url":"https://api.github.com/users/indiv0/received_events","type":"User","site_admin":false},"created_at":"2016-04-07T07:20:51Z","updated_at":"2016-04-07T07:20:51Z","body":"@jimmycuadra @matthewkmayer right now I have two questions:\r\n\r\n1. Is the way I handle [`service_abbreviation` retrieval](https://github.com/rusoto/rusoto/pull/212/files#diff-b042b5677f883b9007470c2820b91c73R68) in `generate_protocol` acceptable?\r\nIt could be possibly refactored out to a function.\r\nIf you have an idea as to how to handle it without a `panic!`, I think that would be good too.\r\n\r\n2. Do you have any idea why the request to Elastic Transcoder would hang (for about 20 seconds, then end with a `500` `Internal Server Error`) if I issue a `read_job` (see the error at the bottom)?\r\n\r\nI've narrowed it down to an issue with the request payload.\r\nIf [`request.set_payload(Some(encoded.as_bytes()));`](https://github.com/rusoto/rusoto/pull/212/files#diff-51fd4ca8ee52b44a7d2879077e03a4abR28) is commented, it completes successfully.\r\nI believe this has something to do with the `content-length` header (perhaps it's larger than it should be, so AWS waits for the remaining payload until timeout?).\r\n\r\n    Response {\r\n      status: InternalServerError,\r\n      headers: Headers {\r\n        Date: Thu, 07 Apr 2016 05:36:41 GMT,\r\n        Transfer-Encoding: chunked, nnCoection: close,\r\n      },\r\n      version: Http11,\r\n      url: Url {\r\n        scheme: \"https\",\r\n        scheme_data: Relative(RelativeSchemeData {\r\n          username: \"\",\r\n          password: None,\r\n          host: Domain(\"elastictranscoder.us-east-1.amazonaws.com\"),\r\n          port: None, default_port: Some(443), path: [\"2012-09-25\", \"jobs\", \"vLmPDjeioMmU\"] }),\r\n          query: None,\r\n          fragment: None\r\n        },\r\n      status_raw: RawStatus(500, \"Internal Server Error\"),\r\n      message: Http11Message {\r\n        method: None,\r\n        stream: Wrapper { obj: Some(Reading(ChunkedReader(chunk_remaining=unknown))) }\r\n      }\r\n    }"}}