{"record":{"id":"8c6edd104bd8e9b9","repo":"apache/seatunnel","slug":"utf-8-encoding-is-not-supported","errorCode":null,"errorMessage":"UTF-8 encoding is not supported","messagePattern":"UTF-8 encoding is not supported","errorType":"exception","errorClass":"IllegalStateException","httpStatus":null,"severity":"info","filePath":"seatunnel-connectors-v2/connector-http/connector-http-airtable/src/main/java/org/apache/seatunnel/connectors/seatunnel/airtable/config/AirtableConfig.java","lineNumber":103,"sourceCode":"                            \"Maximum retries after receiving Airtable 429 responses, must be >= 0.\");\n\n    public static String buildBaseUrl(String apiBaseUrl, String baseId, String table) {\n        String normalized =\n                apiBaseUrl.endsWith(\"/\")\n                        ? apiBaseUrl.substring(0, apiBaseUrl.length() - 1)\n                        : apiBaseUrl;\n        if (!normalized.endsWith(API_VERSION_PATH)) {\n            normalized = normalized + API_VERSION_PATH;\n        }\n        return normalized + \"/\" + baseId + \"/\" + encodePathSegment(table);\n    }\n\n    public static String encodePathSegment(String value) {\n        try {\n            String encoded = URLEncoder.encode(value, StandardCharsets.UTF_8.name());\n            return encoded.replace(\"+\", \"%20\");\n        } catch (java.io.UnsupportedEncodingException e) {\n            throw new IllegalStateException(\"UTF-8 encoding is not supported\", e);\n        }\n    }\n\n    public static Map<String, String> buildAuthHeaders(\n            String token, Map<String, String> existingHeaders) {\n        Map<String, String> headers =\n                Optional.ofNullable(existingHeaders).map(HashMap::new).orElse(new HashMap<>());\n        headers.put(AUTHORIZATION, BEARER + \" \" + token);\n        headers.put(CONTENT_TYPE, APPLICATION_JSON);\n        return headers;\n    }\n}\n","sourceCodeStart":85,"sourceCodeEnd":116,"githubUrl":"https://github.com/apache/seatunnel/blob/cf67b549a7a6c35fa0beb12d83c62892427ea919/seatunnel-connectors-v2/connector-http/connector-http-airtable/src/main/java/org/apache/seatunnel/connectors/seatunnel/airtable/config/AirtableConfig.java#L85-L116","documentation":"AirtableConfig.encodePathSegment wraps java.io.UnsupportedEncodingException thrown while URL-encoding a path segment with UTF-8 into an IllegalStateException. Since every JVM is required to support UTF-8, this should practically never happen; it exists to satisfy checked-exception handling. If you see it, the JVM environment has a corrupted charset configuration.","triggerScenarios":"Calling encodePathSegment (via buildBaseUrl) on a JVM whose charset provider cannot resolve the name 'UTF-8', e.g. a broken/missing charset provider, an unusual custom JRE, or an agent that tampers with java.nio.charset.","commonSituations":"Running on a stripped-down or custom JVM/runtime image (e.g. minimal Docker base with a non-standard JRE), or environments where security managers/agents intercept charset lookups. Essentially never triggered by user config.","solutions":["Run on a standard JDK/JRE (Temurin/OpenJDK 8+) where UTF-8 is always available.","Rebuild/repair the runtime image if using a minimal or custom JRE (jlink) that lacks charset providers.","Remove any JVM agents or -Djava.nio.charset overrides that interfere with charset lookup."],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":"boolean utf8Ok = \"UTF-8\".equals(java.nio.charset.Charset.defaultCharset().name()) || java.nio.charset.StandardCharsets.UTF_8 != null;","typeGuard":null,"tryCatchPattern":"try { result = AirtableConfig.encodePathSegment(value); } catch (IllegalStateException e) { log.error(\"JVM lacks UTF-8 charset support\", e); throw e; }","preventionTips":["Use a standard OpenJDK/Temurin runtime image","Avoid custom jlink runtimes without charset providers","Don't install agents that alter charset resolution"],"tags":["jvm","encoding","charset"],"backgroundTag":"unsupported-platform","analyzedSha":"cf67b549a7a6c35fa0beb12d83c62892427ea919","analyzedAt":"2026-09-10T21:44:55.265Z","contentChangedAt":"2026-09-10T21:44:55.265Z","schemaVersion":2},"datasetVersion":"2026-09-14T16:17:12.679Z"}