Project

impaler

0.0
No commit activity in last 3 years
No release in over 3 years
Wrapper around Impala and Hive gems
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 1.3
>= 0
>= 0

Runtime

>= 0
>= 0
 Project Readme

Impaler

Impaler combines the best of Impala and Hive. Queries are run on Impala and if it fails there it will fallback to running the query in Hive.

Installation

Add this line to your application's Gemfile:

gem 'impaler'

And then execute:

$ bundle

Or install it yourself as:

$ gem install impaler

Usage

Basic Usage

require 'impaler'
c = Impaler.connect(['impala_server:21000'], ['hivethrift_server:10000'])
c.query("select count(*) from my_table") # This will run in Impala
c.query("select name, collect_set(foo) from my_table") # This will run in Hive (after a quick error on Impala)
c.query("select count(*) from my_table", Impaler::HIVE_ONLY) # This is forced to run on Hive

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Test your changes in both connected and unconnected modes (rspec and IMPALA_SERVER=server:21000 HIVETHRIFT_SERVER=server:10000 TEST_TABLE=my_test_table TEST_TABLE_COLUMN=some_test_column rspec
  4. Commit your changes (git commit -am 'Add some feature')
  5. Push to the branch (git push origin my-new-feature)
  6. Create new Pull Request