Jiayi Liu created RANGER-2944:
---------------------------------

             Summary: Presto plugin lookupResource throws NPE if not set 
service password
                 Key: RANGER-2944
                 URL: https://issues.apache.org/jira/browse/RANGER-2944
             Project: Ranger
          Issue Type: Bug
          Components: plugins
            Reporter: Jiayi Liu


In the configuration of Ranger Presto plugin service, password is not a 
required content. Only when SSL is enabled in Presto, we need to fill in the 
password. When Presto does not enable SSL, if you fill in the password when 
configuring the service, the connection will fail and an exception will be 
thrown.

{code:java}
java.sql.SQLException: Authentication using username/password requires SSL to 
be enabled
{code}

However, currently in the code, we always put 
{{prop.getProperty(HadoopConfigHolder.RANGER_LOGIN_PASSWORD)}} to 
prestoProperties, if the password is not set, 
{{prop.getProperty(HadoopConfigHolder.RANGER_LOGIN_PASSWORD)}} will be null. If 
we put a null value to {{Properties}}, this will throw NPE. We need to check 
whether we have set the password.



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

Reply via email to