colinmarc / impala-ruby

an impala client for ruby
MIT License
34 stars 22 forks source link

Remove KNOWN_COMMANDS check #14

Closed saulius closed 10 years ago

saulius commented 10 years ago

Each time new command gets introduced this will have to be extended. Outsource this check to Thrift which will raise informative Impala::Protocol::Beeswax::BeeswaxException instead

E.g.:

"Impala::Protocol::Beeswax::BeeswaxException", "AnalysisException: Syntax error in line 1:\nwat\n^\nEncountered: IDENTIFIER\nExpected: ALTER, COMPUTE, CREATE, DESCRIBE, DROP, EXPLAIN, INSERT, INVALIDATE, LOAD, REFRESH, SELECT, SHOW, USE, VALUES, WITH\n\nCAUSED BY: Exception: Syntax error"
colinmarc commented 10 years ago

Yeah, I think this makes sense. A bit swamped right now but I'll merge when I get a sec.