{"record":{"id":"ca0e810579e448d1","repo":"MyCATApache/Mycat-Server","slug":"node-s-in-group-groupname-doesn-t-exi","errorCode":null,"errorMessage":"[ node :${s}] in [ group:${groupName}] doesn't exist!","messagePattern":"\\[ node :(.+?)\\] in \\[ group:(.+?)\\] doesn't exist!","errorType":"exception","errorClass":"ConfigException","httpStatus":null,"severity":"critical","filePath":"src/main/java/io/mycat/config/model/ClusterConfig.java","lineNumber":128,"sourceCode":"                if (groups.containsKey(groupName)) {\n                    throw new ConfigException(\"group duplicated : \" + groupName);\n                }\n\n                Map<String, Object> props = ConfigUtil.loadElements(e);\n                String value = (String) props.get(\"nodeList\");\n                if (null == value || \"\".equals(value)) {\n                    throw new ConfigException(\"group should contain 'nodeList'\");\n                }\n\n                String[] sList = SplitUtil.split(value, ',', true);\n\n                if (null == sList || sList.length == 0) {\n                    throw new ConfigException(\"group should contain 'nodeList'\");\n                }\n\n                for (String s : sList) {\n                    if (!nodes.containsKey(s)) {\n                        throw new ConfigException(\"[ node :\" + s + \"] in [ group:\" + groupName + \"] doesn't exist!\");\n                    }\n                }\n                List<String> nodeList = Arrays.asList(sList);\n                groups.put(groupName, nodeList);\n            }\n        }\n        if (!groups.containsKey(\"default\")) {\n            List<String> nodeList = new ArrayList<String>(nodes.keySet());\n            groups.put(\"default\", nodeList);\n        }\n        return groups;\n    }\n}","sourceCodeStart":110,"sourceCodeEnd":141,"githubUrl":"https://github.com/MyCATApache/Mycat-Server/blob/65f8d8beb752f935752f2a0eec0ab017facab9ef/src/main/java/io/mycat/config/model/ClusterConfig.java#L110-L141","documentation":"ClusterConfig.loadGroup validates that every node listed in a group's nodeList exists in the parsed `nodes` map. If any referenced dataHost/node name is not defined earlier in the schema.xml configuration, ConfigException is thrown. Mycat refuses to start with an inconsistent cluster definition.","triggerScenarios":"Loading schema.xml: a <group> element's nodeList attribute (comma-separated) references a node name that has no corresponding <dataNode> definition in the same file, so nodes.containsKey(s) is false.","commonSituations":"Typo in a node name inside nodeList; renaming or deleting a dataNode while the group still references the old name; splitting config across files and forgetting the node entry; copy-pasting group blocks from another deployment.","solutions":["Fix the nodeList entry in schema.xml so every name exactly matches an existing <dataNode name=...> definition.","Add the missing <dataNode> definition for the referenced node before the group is loaded.","Remove stale node names from the group's nodeList if that node is no longer used."],"exampleFix":"// before (schema.xml)\n<group name=\"group1\"><nodeList>dn1,dn9</nodeList></group>\n// after\n<group name=\"group1\"><nodeList>dn1,dn2</nodeList></group>","handlingStrategy":"validation","validationCode":"// Java: validate group nodeList before startup\nfor (String nodeName : groupNodeList.split(\",\")) {\n    if (!nodes.containsKey(nodeName.trim())) {\n        throw new IllegalArgumentException(\"nodeList references undefined node: \" + nodeName);\n    }\n}","typeGuard":null,"tryCatchPattern":"try { ClusterConfig.load(); } catch (ConfigException e) { LOG.error(\"Bad group/nodeList config: {}\", e.getMessage()); throw new IllegalStateException(\"Fix schema.xml nodeList entries\", e); }","preventionTips":["Keep a single source of truth for dataNode names and generate nodeList entries from it.","Add a config lint step that cross-checks nodeList references against dataNode definitions before deployment.","Copy node names verbatim; avoid hand-typing them into group blocks."],"tags":["config","mycat","startup","schema-xml"],"backgroundTag":"resource-not-found","analyzedSha":"65f8d8beb752f935752f2a0eec0ab017facab9ef","analyzedAt":"2026-09-11T00:12:21.696Z","contentChangedAt":"2026-09-11T00:12:21.696Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}