{"record":{"id":"650e88a4516569a0","repo":"apache/seatunnel","slug":"get-ezs-version-failed","errorCode":"GET_EZS_VERSION_FAILED","errorMessage":"fail to get easysearch version.","messagePattern":"fail to get easysearch version\\.","errorType":"error_code","errorClass":"EasysearchConnectorException","httpStatus":null,"severity":"error","filePath":"seatunnel-connectors-v2/connector-easysearch/src/main/java/org/apache/seatunnel/connectors/seatunnel/easysearch/client/EasysearchClient.java","lineNumber":281,"sourceCode":"    }\n\n    public EasysearchClusterInfo getClusterInfo() {\n        Request request = new Request(\"GET\", \"/\");\n        try {\n            Response response = restClient.performRequest(request);\n            String result = EntityUtils.toString(response.getEntity());\n            ObjectMapper objectMapper = new ObjectMapper();\n            JsonNode jsonNode = objectMapper.readTree(result);\n            JsonNode versionNode = jsonNode.get(\"version\");\n            return EasysearchClusterInfo.builder()\n                    .clusterVersion(versionNode.get(\"number\").asText())\n                    .distribution(\n                            Optional.ofNullable(versionNode.get(\"distribution\"))\n                                    .map(e -> e.asText())\n                                    .orElse(null))\n                    .build();\n        } catch (IOException e) {\n            throw new EasysearchConnectorException(\n                    EasysearchConnectorErrorCode.GET_EZS_VERSION_FAILED,\n                    \"fail to get easysearch version.\",\n                    e);\n        }\n    }\n\n    public void close() {\n        try {\n            restClient.close();\n        } catch (IOException e) {\n            log.warn(\"close easysearch connection error\", e);\n        }\n    }\n\n    public boolean clearScroll(String scrollId) {\n        if (scrollId == null || scrollId.isEmpty()) {\n            return false;\n        }","sourceCodeStart":263,"sourceCodeEnd":299,"githubUrl":"https://github.com/apache/seatunnel/blob/cf67b549a7a6c35fa0beb12d83c62892427ea919/seatunnel-connectors-v2/connector-easysearch/src/main/java/org/apache/seatunnel/connectors/seatunnel/easysearch/client/EasysearchClient.java#L263-L299","documentation":"EasysearchClient.getClusterInfo calls GET / to read version info; any IOException during that request is wrapped as EasysearchConnectorException with GET_EZS_VERSION_FAILED. This call runs during catalog open / connection initialization, so the job fails before processing data.","triggerScenarios":"Requesting the root endpoint fails while establishing cluster info: host unreachable, connection refused, auth challenge causing IO failure, or response stream broken.","commonSituations":"Wrong host/port in config; cluster starting up; TLS misconfiguration; proxy blocking the root endpoint; transient network blip at job start.","solutions":["Verify the endpoint responds: curl http(s)://host:port/ from the job machine.","Check hosts/scheme/credentials options in the Easysearch catalog/connection config.","Inspect the wrapped IOException cause for connect vs read vs SSL failure.","Retry after confirming cluster health; ensure the root endpoint is not blocked by a proxy."],"exampleFix":"// before\nEasysearchConnectionOptions opts = EasysearchConnectionOptions.builder()\n    .hosts(Collections.singletonList(\"localhost:9210\")) // wrong port\n    .build();\n// after\nEasysearchConnectionOptions opts = EasysearchConnectionOptions.builder()\n    .hosts(Collections.singletonList(\"localhost:9200\"))\n    .scheme(\"http\")\n    .build();","handlingStrategy":"retry","validationCode":"// preflight version endpoint\nHttpResponse resp = httpGet(scheme + \"://\" + host + \":\" + port + \"/\");\nif (resp.status() != 200) throw new IllegalStateException(\"Easysearch root endpoint not reachable\");","typeGuard":null,"tryCatchPattern":"try {\n    clusterInfo = client.getClusterInfo();\n} catch (EasysearchConnectorException e) {\n    if (EasysearchConnectorErrorCode.GET_EZS_VERSION_FAILED.equals(e.getErrorCode())) {\n        // check cause IOException: retry after connectivity check\n    } else throw e;\n}","preventionTips":["Verify host/port/scheme in connection options before job start","Ensure the root '/' endpoint is not blocked by proxies","Wait for cluster readiness before submitting jobs","Import TLS certificates when using https"],"tags":["easysearch","cluster-info","connection"],"backgroundTag":"http-request-failed","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"}