{"action":"created","issue":{"url":"https://api.github.com/repos/google/google-api-ruby-client/issues/222","labels_url":"https://api.github.com/repos/google/google-api-ruby-client/issues/222/labels{/name}","comments_url":"https://api.github.com/repos/google/google-api-ruby-client/issues/222/comments","events_url":"https://api.github.com/repos/google/google-api-ruby-client/issues/222/events","html_url":"https://github.com/google/google-api-ruby-client/pull/222","id":69037616,"number":222,"title":"Ridiculously large refactoring...","user":{"login":"sqrrrl","id":346343,"avatar_url":"https://avatars.githubusercontent.com/u/346343?v=3","gravatar_id":"","url":"https://api.github.com/users/sqrrrl","html_url":"https://github.com/sqrrrl","followers_url":"https://api.github.com/users/sqrrrl/followers","following_url":"https://api.github.com/users/sqrrrl/following{/other_user}","gists_url":"https://api.github.com/users/sqrrrl/gists{/gist_id}","starred_url":"https://api.github.com/users/sqrrrl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sqrrrl/subscriptions","organizations_url":"https://api.github.com/users/sqrrrl/orgs","repos_url":"https://api.github.com/users/sqrrrl/repos","events_url":"https://api.github.com/users/sqrrrl/events{/privacy}","received_events_url":"https://api.github.com/users/sqrrrl/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":17,"created_at":"2015-04-17T00:38:34Z","updated_at":"2015-04-17T20:15:58Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/google/google-api-ruby-client/pulls/222","html_url":"https://github.com/google/google-api-ruby-client/pull/222","diff_url":"https://github.com/google/google-api-ruby-client/pull/222.diff","patch_url":"https://github.com/google/google-api-ruby-client/pull/222.patch"},"body":"Yes, this is a very large pull request... no rush, but very much want opinions/reviews.\r\n\r\nBeen working on this the past few weeks to give the client some much needed TLC. The client was at an architectural dead-end and needed a lot of work. \r\n\r\n*Limitations in the current API client*\r\n\r\n*  Too much magic - The ruby client relies on runtime code generation to generate scheme classes. As this produces no documentation, it requires users understand the conventions used during generation.\r\nInconsistent conventions - Schema classes are generated using ruby naming conventions. Property names in JSON objects are converted to snake case from camel case. However, there are instances where conversion is not applied or where both forms are accepted. Combined with lack of documentation, this has been the source of many issues.\r\n* Clunky interface - The API client offers only a generic ‘execute’ method which takes the API method, parameters, body, etc as parameters. API calls are much more verbose than comparable client libraries.\r\n* Too many options - The client was originally written to support multiple calling styles, have pluggable transports, etc. These were all academic (in the bad way) exercises that produced complexity instead of simplicity. \r\n* Dependencies on dead 3rd party libraries - The underlying HTTP library used by the library, Faraday, is itself at a dead-end and is no longer being developed. As this both permeates the library and leaks through to users\r\n* Not on latest standards - The client still is designed for old versions of Ruby that are no longer supported and does not leverage language features that would simplify the code. Ruby 2.0+ is standard across the community.\r\n\r\n*Principles of the new client*\r\n\r\n* No magic (almost) - Ahead-of-time code generation is used to generate services & types for APIs from discovery services. Generated code is fully documented to the extent information is available in the descriptions. \r\n*Simplicity over Flexibility - Sensible defaults are used and few choices are offered to developers. Developers who need a high degree of flexibility can modify the client as needed or write their own.\r\n* Ruby 2.0+ only. 1.8 and 1.9 branches are officially dead. No need to maintain compatibility at this point.\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/google/google-api-ruby-client/issues/comments/94065903","html_url":"https://github.com/google/google-api-ruby-client/pull/222#issuecomment-94065903","issue_url":"https://api.github.com/repos/google/google-api-ruby-client/issues/222","id":94065903,"user":{"login":"coveralls","id":2354108,"avatar_url":"https://avatars.githubusercontent.com/u/2354108?v=3","gravatar_id":"","url":"https://api.github.com/users/coveralls","html_url":"https://github.com/coveralls","followers_url":"https://api.github.com/users/coveralls/followers","following_url":"https://api.github.com/users/coveralls/following{/other_user}","gists_url":"https://api.github.com/users/coveralls/gists{/gist_id}","starred_url":"https://api.github.com/users/coveralls/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/coveralls/subscriptions","organizations_url":"https://api.github.com/users/coveralls/orgs","repos_url":"https://api.github.com/users/coveralls/repos","events_url":"https://api.github.com/users/coveralls/events{/privacy}","received_events_url":"https://api.github.com/users/coveralls/received_events","type":"User","site_admin":false},"created_at":"2015-04-17T20:15:57Z","updated_at":"2015-04-17T20:15:57Z","body":"\n[![Coverage Status](https://coveralls.io/builds/2364656/badge)](https://coveralls.io/builds/2364656)\n\nCoverage decreased (-0.1%) to 93.16% when pulling **bde37beb0428cea15b1c12bf5bffc791b1be3a50 on sqrrrl:master** into **82f69445ad2d63d946baaaddd8d0563faba8e975 on google:master**.\n"}}