rbhive
rbhive copied to clipboard
Set credentials
Hi,
How do we set authentication params like user and password, while using tcli_connect or connect methods?
There is a PR https://github.com/forward3d/rbhive/pull/23 that offers Kerberos connectivity, but this is yet to be merged into master.
@Selenium-hari here is an example:
RBHive.tcli_connect('address', 10_000, { transport: :sasl,:sasl_params => {:username => "username",:password => "password"},logger: Logger.new(STDOUT), hive_version: 10 }) do |connection|
connection.fetch 'SELECT * FROM users LIMIT 5'
end