[ 
https://issues.apache.org/jira/browse/HIVE-22355?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16953484#comment-16953484
 ] 

Mate Juhasz commented on HIVE-22355:
------------------------------------

Hi [~Rajkumar Singh]! This is exactly what I would not like to do, thus it 
would help to resolve the username, but would still ask for password. I am 
thinking on something like this, a way where we dont need user and password:

{code:java}
  if (auth != 'NONE'){
      if(principal == null){
        //get user and password from stdin
     }
  }
connect();
{code}


> Beeline should not prompt for hive user and password when authentication is 
> NONE
> --------------------------------------------------------------------------------
>
>                 Key: HIVE-22355
>                 URL: https://issues.apache.org/jira/browse/HIVE-22355
>             Project: Hive
>          Issue Type: Bug
>          Components: Beeline
>            Reporter: Mate Juhasz
>            Priority: Major
>
> Beeline - without adding the jdbc url - prompts for username and password in 
> case hive.server2.authentication=NONE, which is possibly pointless and can be 
> misleading for users as any input is accepted.
> In addition, Sqoop has dropped hive cli recently in favor of beeline and if 
> there is no authentication set in Hive, Sqoop fails to connect as the process 
> stops waiting for the user/password input. 
> I think it would be nice to check the auth type "NONE" before reading unused 
> inputs from the console before this point:
> https://github.com/apache/hive/blob/master/beeline/src/java/org/apache/hive/beeline/Commands.java#L1641



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to