{"record":{"id":"fee67eeddf75bcc0","repo":"hibernate/hibernate-orm","slug":"unknown-entity-type","errorCode":null,"errorMessage":"Unknown entity type '{}'","messagePattern":"Unknown entity type '(.+?)'","errorType":"exception","errorClass":"UnknownEntityTypeException","httpStatus":null,"severity":"error","filePath":"hibernate-core/src/main/java/org/hibernate/graph/internal/parse/GraphParser.java","lineNumber":124,"sourceCode":"\t\t\t\t\t\tattributeName,\n\t\t\t\t\t\tqualifierName\n\t\t\t\t);\n\t\t\t}\n\t\t\treturn resolvePathQualifier( qualifierName ).getSubGraphCreator();\n\t\t}\n\t}\n\n\tprivate SubGraphImplementor<?> createSubGraph(AttributeNodeImplementor<?, ?, ?> attributeNode, String subTypeName) {\n\n\t\tfinal var shouldCreateTreatedSubgraph = attributeNode == null && subTypeName != null;\n\n\t\tif ( shouldCreateTreatedSubgraph ) {\n\t\t\tfinal var currentGraph = graphStack.getCurrent();\n\n\t\t\tfinal EntityDomainType entityDomainType = entityNameResolver.resolveEntityName( subTypeName );\n\n\t\t\tif ( entityDomainType == null ) {\n\t\t\t\tthrow new UnknownEntityTypeException( subTypeName );\n\t\t\t}\n\n\t\t\treturn currentGraph.addTreatedSubgraph(\n\t\t\t\t\tentityDomainType\n\t\t\t);\n\n\t\t}\n\n\n\t\tfinal var subGraphCreator = graphSourceStack.getCurrent();\n\n\t\treturn subGraphCreator.createSubGraph(\n\t\t\t\tattributeNode,\n\t\t\t\tsubTypeName,\n\t\t\t\tentityNameResolver\n\t\t);\n\n\t}","sourceCodeStart":106,"sourceCodeEnd":142,"githubUrl":"https://github.com/hibernate/hibernate-orm/blob/fad1729dce015f908198d57a8d80274a30f905a5/hibernate-core/src/main/java/org/hibernate/graph/internal/parse/GraphParser.java#L106-L142","documentation":"Error \"Unknown entity type '{}'\" thrown in hibernate/hibernate-orm.","triggerScenarios":"Thrown when Hibernate is asked to work with a class/name that is not a mapped managed type in the current SessionFactory.","commonSituations":"Typical situations: typos in entity names; the entity class not registered in the persistence unit; using a mapped-superclass or unmapped class where an entity is required.","solutions":["Check the entity name in the graph text for typos and ensure the entity is mapped in this persistence unit.","Use the entity's mapped name (or fully qualified class name) as declared in the metamodel."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"fad1729dce015f908198d57a8d80274a30f905a5","analyzedAt":"2026-08-22T04:13:57.527Z","schemaVersion":2},"datasetVersion":"2026-08-22T09:17:25.309Z"}