{"record":{"id":"6e4c05157727e783","repo":"apache/seatunnel","slug":"retryingmetastoreclient-found-but-no-compatible-ge","errorCode":null,"errorMessage":"RetryingMetaStoreClient found but no compatible getProxy method, falling back to HiveMetaStoreClient","messagePattern":"RetryingMetaStoreClient found but no compatible getProxy method, falling back to HiveMetaStoreClient","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":236,"sourceCode":"     */\n    private static Class<?> loadClass(String className, HiveConf hiveConf)\n            throws ClassNotFoundException {\n        ClassLoader contextClassLoader = Thread.currentThread().getContextClassLoader();\n        if (contextClassLoader != null) {\n            try {\n                return Class.forName(className, true, contextClassLoader);\n            } catch (ClassNotFoundException ignored) {\n            }\n        }\n        return hiveConf.getClassByName(className);\n    }\n\n    private IMetaStoreClient tryCreateRetryingClient(HiveConf hiveConf) {\n        try {\n            Class<?> clazz = Class.forName(RETRYING_METASTORE_CLIENT_CLASS_NAME);\n            Method getProxyMethod = getProxyMethod(clazz);\n            if (getProxyMethod == null) {\n                log.warn(RETRYING_METASTORE_CLIENT_NO_COMPATIBLE_GET_PROXY_MESSAGE);\n                return null;\n            }\n\n            Object proxy = getProxyMethod.invoke(null, hiveConf, true);\n            if (proxy instanceof IMetaStoreClient) {\n                log.info(\n                        \"Using RetryingMetaStoreClient for Hive metastore connection [uris={}]\",\n                        hiveConf.get(\"hive.metastore.uris\"));\n                return (IMetaStoreClient) proxy;\n            }\n            log.warn(RETRYING_METASTORE_CLIENT_NO_COMPATIBLE_GET_PROXY_MESSAGE);\n            return null;\n        } catch (ClassNotFoundException e) {\n            log.debug(\"RetryingMetaStoreClient not found, falling back to HiveMetaStoreClient\", e);\n            return null;\n        } catch (Exception e) {\n            log.warn(\n                    \"Failed to create RetryingMetaStoreClient proxy, falling back to HiveMetaStoreClient\",","sourceCodeStart":218,"sourceCodeEnd":254,"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#L218-L254","documentation":"HiveMetaStoreCatalog tries to build a RetryingMetaStoreClient via reflection on its static getProxy method, for resilience across Hive versions. If the class is found but no getProxy method with the expected signature exists, it logs this warning and returns null, causing a plain HiveMetaStoreClient fallback (no built-in retry).","triggerScenarios":"tryCreateRetryingClient() loads RETRYING_METASTORE_CLIENT_CLASS_NAME successfully, but getProxyMethod(clazz) returns null because no compatible getProxy(Configuration,boolean)-style method exists in the classpath's Hive version.","commonSituations":"Hive version mismatch: connector built against one Hive release while the runtime classpath contains another with a changed getProxy signature; shaded/mixed Hive jars.","solutions":["Align the Hive metastore client version on the classpath with the version SeaTunnel's Hive connector expects","Inspect getProxyMethod(clazz) to see which signature it looks for and confirm your hive-exec/metastore jar provides it","Accept the fallback if retrying behavior is not critical — HiveMetaStoreClient still works","Pin an explicit hive-exec dependency version to avoid transitive version drift"],"exampleFix":null,"handlingStrategy":"fallback","validationCode":"Class<?> c = Class.forName(\"org.apache.hadoop.hive.metastore.RetryingMetaStoreClient\");\nboolean ok = java.util.Arrays.stream(c.getMethods()).anyMatch(m -> m.getName().equals(\"getProxy\"));","typeGuard":null,"tryCatchPattern":"try {\n  client = retryingClientFactory(hiveConf);\n} catch (Exception e) {\n  client = new HiveMetaStoreClient(hiveConf); // fallback\n}","preventionTips":["Keep hive-exec/metastore jars consistent with the connector's expected Hive version","Avoid mixing multiple Hive jars on the classpath","Treat this warning as 'no auto-retry' and add application-level retry if needed"],"tags":["hive","reflection","version-mismatch","metastore"],"backgroundTag":"incompatible-source-type","analyzedSha":"cf67b549a7a6c35fa0beb12d83c62892427ea919","analyzedAt":"2026-09-10T21:44:55.265Z","contentChangedAt":"2026-09-10T21:44:55.265Z","schemaVersion":2},"datasetVersion":"2026-09-14T11:17:12.474Z"}