tuplejump / cash

The CASsandra Hive handler
34 stars 25 forks source link

Cannot connect to Cassandra server with username/password #10

Open dansc14 opened 10 years ago

dansc14 commented 10 years ago

Hi,

It seems there's no way to specify a username/password when trying to connect to a Cassandra server using the PasswordAuthenticator. When trying to create my EXTERNAL TABLE, i.e.

CREATE EXTERNAL TABLE example (
example_data bigint
)
STORED BY 'org.apache.hadoop.hive.cassandra.cql.CqlStorageHandler'
WITH SERDEPROPERTIES ("cassandra.host" = "1.2.3.4")
TBLPROPERTIES ("cassandra.ks.name" = "test", "cassandra.cf.name" = "example");

` I get this error message:

FAILED: Error in metadata: MetaException(message:Unable to connect to the server InvalidRequestException(why:You have not logged in))
FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.DDLTask

My external table works if I change the server back to AllowAllAuthenticator, but unfortunately that's not really an option.

Would it be possible to add username and password to SERDEPROPERTIES? Or is there a different workaround that I'm missing?

ghost commented 6 years ago

is there a solution to this issue.