{"record":{"id":"996846361f766df0","repo":"apache/seatunnel","slug":"invalid-hivesitepath","errorCode":null,"errorMessage":"Invalid hiveSitePath {}","messagePattern":"Invalid hiveSitePath (.+?)","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"seatunnel-connectors-v2/connector-hive/src/main/java/org/apache/seatunnel/connectors/seatunnel/hive/utils/HiveMetaStoreCatalog.java","lineNumber":391,"sourceCode":"        hiveConf.setInt(\"hive.metastore.failure.retries\", 3);\n\n        if (StringUtils.isNotBlank(hadoopConfDir)) {\n            for (String fileName : HADOOP_CONF_FILES) {\n                Path path = Paths.get(hadoopConfDir, fileName);\n                if (Files.exists(path)) {\n                    try {\n                        hiveConf.addResource(path.toUri().toURL());\n                    } catch (IOException e) {\n                        log.warn(\"Error adding Hadoop config {}\", path, e);\n                    }\n                }\n            }\n        }\n        if (StringUtils.isNotBlank(hiveSitePath)) {\n            try {\n                hiveConf.addResource(new File(hiveSitePath).toURI().toURL());\n            } catch (MalformedURLException e) {\n                log.warn(\"Invalid hiveSitePath {}\", hiveSitePath, e);\n            }\n        }\n        hadoopProperties.forEach(hiveConf::set);\n        log.debug(\"Hive client configuration initialized\");\n        return hiveConf;\n    }\n\n    private IMetaStoreClient loginWithKerberos(HiveConf hiveConf) throws Exception {\n        Configuration authConf = new Configuration();\n        authConf.set(\"hadoop.security.authentication\", \"kerberos\");\n        return HadoopLoginFactory.loginWithKerberos(\n                authConf,\n                krb5Path,\n                principal,\n                keytabPath,\n                (conf, ugi) -> {\n                    this.userGroupInformation = ugi;\n                    return createClient(hiveConf);","sourceCodeStart":373,"sourceCodeEnd":409,"githubUrl":"https://github.com/apache/seatunnel/blob/cf67b549a7a6c35fa0beb12d83c62892427ea919/seatunnel-connectors-v2/connector-hive/src/main/java/org/apache/seatunnel/connectors/seatunnel/hive/utils/HiveMetaStoreCatalog.java#L373-L409","documentation":"buildHiveConf optionally adds a user-provided hive-site.xml via its path. If that path is not a valid URL (MalformedURLException), the file cannot be added to the HiveConf; the warning names the invalid path and initialization continues without it, so hive-site settings will be missing from the client configuration.","triggerScenarios":"buildHiveConf() (called from initializeClient) calls hiveConf.addResource(new File(hiveSitePath).toURI().toURL()) and the string is malformed — e.g. relative path with bad characters, or a URI-incompatible string passed as hive_site_path.","commonSituations":"Typo in hive_site_path option, passing a URL string with illegal characters, using a relative path when an absolute one is required.","solutions":["Provide an absolute, properly-formed path to hive-site.xml (e.g. /etc/hive/conf/hive-site.xml)","Check the path for spaces or illegal URI characters and quote/rename accordingly","Verify the file exists and is readable before launching the job","Alternatively place hive-site.xml on the classpath so it is picked up automatically"],"exampleFix":"// before\n\"hive_site_path\" = \"~/conf/hive site.xml\"\n// after\n\"hive_site_path\" = \"/etc/hive/conf/hive-site.xml\"","handlingStrategy":"validation","validationCode":"java.io.File f = new java.io.File(hiveSitePath);\nif (!f.isAbsolute() || !f.isFile()) throw new IllegalArgumentException(\"hive_site_path must be an absolute existing file: \" + hiveSitePath);\njava.net.URL u = f.toURI().toURL(); // throws MalformedURLException before the job","typeGuard":null,"tryCatchPattern":"try {\n  hiveConf.addResource(new File(hiveSitePath).toURI().toURL());\n} catch (MalformedURLException e) {\n  throw new IllegalArgumentException(\"Invalid hive_site_path: \" + hiveSitePath, e);\n}","preventionTips":["Pass an absolute filesystem path for hive_site_path, not a URL or relative path","Avoid spaces/illegal URI characters in config paths","Ensure the file exists and is readable at job launch","Alternatively ship hive-site.xml on the classpath instead of a path option"],"tags":["hive","configuration","url","hive-site"],"backgroundTag":"invalid-url-format","analyzedSha":"cf67b549a7a6c35fa0beb12d83c62892427ea919","analyzedAt":"2026-09-10T21:44:55.265Z","contentChangedAt":"2026-09-10T21:44:55.265Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}