{"record":{"id":"6def953f4f0abafb","repo":"apache/flink","slug":"union-types-are-such-as-allof-anyof-etc-and","errorCode":null,"errorMessage":"Union types are such as 'allOf', 'anyOf' etc. and extending are not supported yet.","messagePattern":"Union types are such as 'allOf', 'anyOf' etc\\. and extending are not supported yet\\.","errorType":"validation","errorClass":"java.lang.IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"flink-formats/flink-json/src/main/java/org/apache/flink/formats/json/JsonRowSchemaConverter.java","lineNumber":214,"sourceCode":"            final TypeInformation<?>[] types =\n                    convertTypes(location + '/' + ONE_OF, node.get(ONE_OF), root);\n            typeSet.addAll(Arrays.asList(types));\n        }\n        // use ONE_OF of reference as fallback\n        else if (ref.isPresent() && ref.get().has(ONE_OF) && ref.get().get(ONE_OF).isArray()) {\n            final TypeInformation<?>[] types =\n                    convertTypes(\n                            node.get(REF).asText() + '/' + ONE_OF, ref.get().get(ONE_OF), root);\n            typeSet.addAll(Arrays.asList(types));\n        }\n\n        // validate no union types or extending\n        if (node.has(ALL_OF)\n                || node.has(ANY_OF)\n                || node.has(NOT)\n                || node.has(EXTENDS)\n                || node.has(DISALLOW)) {\n            throw new IllegalArgumentException(\n                    \"Union types are such as '\"\n                            + ALL_OF\n                            + \"', '\"\n                            + ANY_OF\n                            + \"' etc. \"\n                            + \"and extending are not supported yet.\");\n        }\n\n        // only a type (with null) is supported yet\n        final List<TypeInformation<?>> types = new ArrayList<>(typeSet);\n        if (types.size() == 0) {\n            throw new IllegalArgumentException(\"No type could be found in node:\" + location);\n        } else if (types.size() > 2 || (types.size() == 2 && !types.contains(Types.VOID))) {\n            throw new IllegalArgumentException(\n                    \"Union types with more than just a null type are not supported yet.\");\n        }\n\n        // return the first non-void type or void","sourceCodeStart":196,"sourceCodeEnd":232,"githubUrl":"https://github.com/apache/flink/blob/2f3c205e9266cb30240eb7f4fdab15cad629a70f/flink-formats/flink-json/src/main/java/org/apache/flink/formats/json/JsonRowSchemaConverter.java#L196-L232","documentation":"Error \"Union types are such as 'allOf', 'anyOf' etc. and extending are not supported yet.\" thrown in apache/flink.","triggerScenarios":"Triggered at runtime when the operation fails because: Union types are such as 'allOf', 'anyOf' etc. and extending are not supported yet.","commonSituations":"Commonly caused by misconfiguration, missing dependencies or files, unsupported types or operations, or invalid user input leading to: Union types are such as 'allOf', 'anyOf' etc. and extending are not supported yet.","solutions":["Address the cause reported by the error message: Union types are such as 'allOf', 'anyOf' etc. and extending are not supported yet.","Verify the inputs, configuration values, and classpath/dependency setup related to this operation, then retry."],"exampleFix":"Correct the condition described (\"Union types are such as 'allOf', 'anyOf' etc. and extending are not supported yet.\") and rerun the job or command.","handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"2f3c205e9266cb30240eb7f4fdab15cad629a70f","analyzedAt":"2026-08-14T08:48:24.518Z","schemaVersion":2},"datasetVersion":"2026-08-14T10:17:34.591Z"}