Commit b6eb2157 authored by qiaozhanwei's avatar qiaozhanwei
Browse files

only kerberos startup and sql task type is hive or spark

parent d9d96b0b
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -522,7 +522,10 @@ public class DataSourceService extends BaseService{
        parameterMap.put(Constants.JDBC_URL, jdbcUrl);
        parameterMap.put(Constants.USER, userName);
        parameterMap.put(Constants.PASSWORD, password);
        if (CommonUtils.getKerberosStartupState() &&
                (type == DbType.HIVE || type == DbType.SPARK)){
            parameterMap.put(Constants.PRINCIPAL,principal);
        }
        if (other != null && !"".equals(other)) {
            Map map = JSONObject.parseObject(other, new TypeReference<LinkedHashMap<String, String>>() {
            });