{"action":"created","issue":{"url":"https://api.github.com/repos/xerions/mariaex/issues/138","repository_url":"https://api.github.com/repos/xerions/mariaex","labels_url":"https://api.github.com/repos/xerions/mariaex/issues/138/labels{/name}","comments_url":"https://api.github.com/repos/xerions/mariaex/issues/138/comments","events_url":"https://api.github.com/repos/xerions/mariaex/issues/138/events","html_url":"https://github.com/xerions/mariaex/pull/138","id":179344724,"number":138,"title":"Handle text protocol COM_QUERY response","user":{"login":"jdangerx","id":2495794,"avatar_url":"https://avatars.githubusercontent.com/u/2495794?v=3","gravatar_id":"","url":"https://api.github.com/users/jdangerx","html_url":"https://github.com/jdangerx","followers_url":"https://api.github.com/users/jdangerx/followers","following_url":"https://api.github.com/users/jdangerx/following{/other_user}","gists_url":"https://api.github.com/users/jdangerx/gists{/gist_id}","starred_url":"https://api.github.com/users/jdangerx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jdangerx/subscriptions","organizations_url":"https://api.github.com/users/jdangerx/orgs","repos_url":"https://api.github.com/users/jdangerx/repos","events_url":"https://api.github.com/users/jdangerx/events{/privacy}","received_events_url":"https://api.github.com/users/jdangerx/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":12,"created_at":"2016-09-26T21:42:05Z","updated_at":"2016-09-30T17:12:55Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/xerions/mariaex/pulls/138","html_url":"https://github.com/xerions/mariaex/pull/138","diff_url":"https://github.com/xerions/mariaex/pull/138.diff","patch_url":"https://github.com/xerions/mariaex/pull/138.patch"},"body":"The MySQL [text protocol COM_QUERY response](https://dev.mysql.com/doc/internals/en/com-query-response.html) is not supported. I needed to communicated with a MySQL-like implementation that only supported the text protocol, so I was running into #132.\r\n\r\nThis is my implementation of the text query response protocol. The difference between the binary and text protocols is that the text protocol converts all the row data to length encoded strings. I've made `Query.decode` dispatch on the query type, added more function clauses to `handle_text_query`, and added a bunch of string parsing for the `decode_text_rows` function.\r\n\r\nI also have a few questions/concerns about my code:\r\n* It seems like the `handle_text_query` function should be able to have more overlap with the `handle_binary_query` functions, but I'm not sure how that would work. It sure would be nice to DRY it up a bit.\r\n* It would be nice _for my use case_ to pass query type (and whether or not to prepare the query) into `Mariaex.query` - does that seem like something that we could or should insert into the API?"},"comment":{"url":"https://api.github.com/repos/xerions/mariaex/issues/comments/250800368","html_url":"https://github.com/xerions/mariaex/pull/138#issuecomment-250800368","issue_url":"https://api.github.com/repos/xerions/mariaex/issues/138","id":250800368,"user":{"login":"jdangerx","id":2495794,"avatar_url":"https://avatars.githubusercontent.com/u/2495794?v=3","gravatar_id":"","url":"https://api.github.com/users/jdangerx","html_url":"https://github.com/jdangerx","followers_url":"https://api.github.com/users/jdangerx/followers","following_url":"https://api.github.com/users/jdangerx/following{/other_user}","gists_url":"https://api.github.com/users/jdangerx/gists{/gist_id}","starred_url":"https://api.github.com/users/jdangerx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jdangerx/subscriptions","organizations_url":"https://api.github.com/users/jdangerx/orgs","repos_url":"https://api.github.com/users/jdangerx/repos","events_url":"https://api.github.com/users/jdangerx/events{/privacy}","received_events_url":"https://api.github.com/users/jdangerx/received_events","type":"User","site_admin":false},"created_at":"2016-09-30T17:12:54Z","updated_at":"2016-09-30T17:12:54Z","body":"Ping @liveforeverx - tests pass, so the question is, is this functionality something we want to have around?"}}
{"actor":{"display_login":"jdangerx"}}