{"record":{"id":"68dfbe4e47f8fe32","repo":"hibernate/hibernate-orm","slug":"cache-provider-not-started","errorCode":null,"errorMessage":"Cache provider not started","messagePattern":"Cache provider not started","errorType":"exception","errorClass":"IllegalStateException","httpStatus":null,"severity":"error","filePath":"hibernate-core/src/main/java/org/hibernate/cache/spi/AbstractRegionFactory.java","lineNumber":55,"sourceCode":"\t */\n\tpublic static final List<String> LEGACY_UPDATE_TIMESTAMPS_REGION_UNQUALIFIED_NAMES = List.of(\n\t\t\t\"org.hibernate.cache.spi.TimestampsRegion\",\n\t\t\t\"org.hibernate.cache.spi.UpdateTimestampsCache\"\n\t);\n\n\tprivate Exception startingException;\n\n\tprivate SessionFactoryOptions options;\n\n\n\tprotected boolean isStarted() {\n\t\tif ( started.get() ) {\n\t\t\tassert options != null;\n\t\t\treturn true;\n\t\t}\n\t\telse {\n\t\t\tassert options == null;\n\t\t\tthrow new IllegalStateException( \"Cache provider not started\", startingException );\n\t\t}\n\t}\n\n\tprotected void verifyStarted() {\n\t\tif ( ! verifiedStartStatus() ) {\n\t\t\tthrow new IllegalStateException( \"Cache provider not started\", startingException );\n\t\t}\n\t}\n\n\tprotected boolean verifiedStartStatus() {\n\t\tif ( started.get() ) {\n\t\t\tassert options != null;\n\t\t\treturn true;\n\t\t}\n\t\telse {\n\t\t\tassert options == null;\n\t\t\treturn false;\n\t\t}","sourceCodeStart":37,"sourceCodeEnd":73,"githubUrl":"https://github.com/hibernate/hibernate-orm/blob/fad1729dce015f908198d57a8d80274a30f905a5/hibernate-core/src/main/java/org/hibernate/cache/spi/AbstractRegionFactory.java#L37-L73","documentation":"Error \"Cache provider not started\" thrown in hibernate/hibernate-orm.","triggerScenarios":"Second-level caching is misconfigured or a cache region/key does not match what Hibernate expects.","commonSituations":"Enabling @Cacheable entities without setting hibernate.cache.region.factory_class, custom RegionFactory implementations, or unwrapping Cache to provider types.","solutions":["Do not use cache regions before the SessionFactory is fully built; the RegionFactory starts with the SessionFactory."],"exampleFix":"Do not use cache regions before the SessionFactory is fully built; the RegionFactory starts with the SessionFactory.","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"}