{"record":{"id":"68e99c4f64158f2a","repo":"hibernate/hibernate-orm","slug":"unrecognized-hibernate-hbm2ddl-jdbc-metadata-extr","errorCode":null,"errorMessage":"Unrecognized 'hibernate.hbm2ddl.jdbc_metadata_extraction_strategy' value: '%s'","messagePattern":"Unrecognized 'hibernate\\.hbm2ddl\\.jdbc_metadata_extraction_strategy' value: '(.+?)'","errorType":"exception","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"hibernate-core/src/main/java/org/hibernate/tool/schema/JdbcMetadataAccessStrategy.java","lineNumber":72,"sourceCode":"\t\t\treturn interpretHbm2ddlSetting( options.get( HBM2DDL_JDBC_METADATA_EXTRACTOR_STRATEGY ) );\n\t\t}\n\t}\n\n\tpublic static JdbcMetadataAccessStrategy interpretHbm2ddlSetting(Object value) {\n\t\tif ( value == null ) {\n\t\t\treturn GROUPED;\n\t\t}\n\t\telse {\n\t\t\tfinal String name = value.toString().trim();\n\t\t\tif ( name.isEmpty() ) {\n\t\t\t\treturn GROUPED;\n\t\t\t}\n\t\t\tfor ( var strategy: values() ) {\n\t\t\t\tif ( strategy.toString().equalsIgnoreCase(name) ) {\n\t\t\t\t\treturn strategy;\n\t\t\t\t}\n\t\t\t}\n\t\t\tthrow new IllegalArgumentException( \"Unrecognized '\" + HBM2DDL_JDBC_METADATA_EXTRACTOR_STRATEGY + \"' value: '\" + value + \"'\");\n\t\t}\n\t}\n}\n","sourceCodeStart":54,"sourceCodeEnd":76,"githubUrl":"https://github.com/hibernate/hibernate-orm/blob/fad1729dce015f908198d57a8d80274a30f905a5/hibernate-core/src/main/java/org/hibernate/tool/schema/JdbcMetadataAccessStrategy.java#L54-L76","documentation":"hibernate.hbm2ddl.jdbc_metadata_extraction_strategy selects how JDBC metadata is read during schema validate/update: grouped (one grouped extraction round, the default — an empty/blank value also falls back to it) or individually (per-table lookups). Any other trimmed value throws this IllegalArgumentException, since matching is case-insensitive equality against exactly those two strategy names.","triggerScenarios":"Setting the property to \"individual\", \"grouped-by-table\", \"single\", or a typo — none equal grouped/individually case-insensitively, so JdbcMetadataAccessStrategy.interpret throws during bootstrap.","commonSituations":"Tuning schema-validation performance against slow database metadata catalogs; copying the key/value from blog posts that use a wrong token like 'individual'; leftover experiments committed into property files.","solutions":["Set the value to grouped or individually — or remove the property entirely to get the grouped default.","Fix token typos and variants: 'individual' is not accepted; the exact strings are 'grouped' and 'individually'."],"exampleFix":"# before\nhibernate.hbm2ddl.jdbc_metadata_extraction_strategy=individual\n\n# after\nhibernate.hbm2ddl.jdbc_metadata_extraction_strategy=individually","handlingStrategy":"validation","validationCode":"private static final Set<String> VALID_STRATEGIES = Set.of(\"grouped\", \"individually\");\n\nString token = strategy == null ? \"\" : strategy.trim().toLowerCase(Locale.ROOT);\nif (!token.isEmpty() && !VALID_STRATEGIES.contains(token)) {\n    throw new IllegalStateException(\"Bad jdbc_metadata_extraction_strategy: \" + strategy);\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Remember the two exact tokens: grouped and individually (not 'individual').","Omit the property unless you specifically need per-table extraction."],"tags":["hibernate","hbm2ddl","schema-validation","jdbc-metadata","configuration"],"backgroundTag":"invalid-hibernate-enum-setting","analyzedSha":"fad1729dce015f908198d57a8d80274a30f905a5","analyzedAt":"2026-08-22T04:13:57.527Z","schemaVersion":2},"datasetVersion":"2026-08-22T09:17:25.309Z"}