blaze-persistence
Blaze-Persistence is a Java library that extends JPA with a more powerful Criteria API for building database queries. It adds support for advanced SQL features like CTEs, set operations, and keyset pagination while maintaining compatibility with standard JPA providers.
Key facts
Objective fields from the source. Values we can't verify are shown as “Unknown” rather than guessed.
| Field | Value |
|---|---|
| Repository | Blazebit/blaze-persistence |
| Owner | Blazebit |
| Primary language | Java |
| License | Apache-2.0 — OSI-approved |
| Stars | 855 |
| Forks | 106 |
| Open issues | 346 |
| Latest release | 1.6.18 (2026-02-01) |
| Last updated | 2026-06-23 |
| Source | https://github.com/Blazebit/blaze-persistence |
What blaze-persistence is
A query builder framework for JPA that layers on Hibernate, EclipseLink, and other JPA providers to expose advanced SQL capabilities (CTEs, RETURNING clauses, VALUES, UNION/EXCEPT/INTERSECT) through a fluent API. Includes Entity-View projection support and Spring Data/DeltaSpike Data integration modules.
Get the blaze-persistence source
Clone the repository and explore it locally.
git clone https://github.com/Blazebit/blaze-persistence.gitcd blaze-persistence# follow the project's README for install & configurationNeed it deployed, integrated, or customized instead? DEV.co ships production installs.
Best use cases
Implementation considerations
- Requires JPA 2.0 minimum; Java 8+ recommended for most integrations (Hibernate 5.2+, Spring Data 2.0+). Java 21 tested; ensure JAXB/JTA APIs available on Java 11+.
- Modular design: choose core, Entity-View, JPA-Criteria, and Spring Data/DeltaSpike modules independently; use BOM for version alignment.
- Metamodel generation is compile-time; relies on annotation processors (javax.persistence.metamodel); ensure build config supports this.
- Database dialect support varies: CTE and RETURNING features depend on underlying DB and JPA provider (Hibernate dialect configuration critical).
- Test against target JPA provider and database early; some advanced features may require specific provider versions or configurations.
When to avoid it — and what to weigh
- Minimal or greenfield projects with simple CRUD — If your queries are basic SELECT/INSERT/UPDATE/DELETE without complex joins or reporting, standard JPA or Spring Data suffices; Blaze adds unnecessary complexity.
- Non-JPA data sources or polyglot persistence — Blaze is tightly coupled to JPA providers; it cannot abstract over NoSQL, graph, or non-relational stores.
- Teams unfamiliar with JPA or SQL semantics — The fluent API assumes solid understanding of relational concepts and JPA metamodel generation; steep learning curve for junior teams.
- Strict vendor-neutral requirements — While claimed as JPA-provider-agnostic, some advanced features (CTEs, RETURNING) depend on database dialect support; not all databases/providers are equal.
License & commercial use
Apache License 2.0 (Apache-2.0). Permissive OSI-approved license allowing commercial use, modification, and distribution with minimal restrictions (attribution and notice of changes required).
Commercial use is permitted under Apache 2.0. No proprietary dependencies or restrictions noted in provided data. Verify that all transitive JPA provider licenses (Hibernate, EclipseLink, etc.) align with your commercial use terms, as Blaze is a library layered atop them.
DEV.co evaluation signals
Editorial assessment — not user reviews. Directional, with an explicit confidence level.
| Signal | Assessment |
|---|---|
| Maintenance | Active |
| Documentation | Strong |
| License clarity | Clear |
| Deployment complexity | Moderate |
| DEV.co fit | Good |
| Assessment confidence | High |
Blaze-Persistence is a query builder and does not introduce novel security primitives. Standard JPA/SQL injection risks apply: parameterized queries and named parameters (supported) mitigate SQL injection. No explicit encryption, audit logging, or access control documented; rely on underlying JPA provider and database security. Review provider's security advisories (e.g., Hibernate CVEs) as Blaze depends on them.
Alternatives to consider
Spring Data JPA / Querydsl
Industry standard for type-safe JPA queries with smaller ecosystem footprint; better for simple-to-moderate complexity. Querydsl's APT-based type generation avoids some Blaze bootstrapping overhead.
jOOQ
Database-first, code-generation approach with superior support for advanced SQL (CTEs, window functions, dialects). Type-safe and database-agnostic, but heavier upfront cost and less JPA-integrated.
Raw JPA Criteria API + native queries
Lower-level, zero dependencies beyond JPA. Suitable if your use cases are simple; native SQL for complex reporting. More boilerplate, no abstraction over database differences.
Build on blaze-persistence with DEV.co software developers
Evaluate Blaze-Persistence for your Java backend if you need CTEs, keyset pagination, or projection mapping. Start with a Spring Boot or Core archetype and test against your JPA provider and database.
Talk to DEV.coRelated open-source tools
Surfaced by semantic similarity across the DEV.co open-source index.
Related on DEV.co
Explore the category and the services that help you build with it.
blaze-persistence FAQ
Does Blaze-Persistence work with Spring Boot?
Can I use Blaze with Hibernate 6+?
What databases support CTEs and RETURNING clauses?
Is Entity-View similar to DTOs or database views?
Software development & web development with DEV.co
DEV.co helps companies turn open-source tools like blaze-persistence into production software. Our software development services cover the full lifecycle — architecture, web development, integration, and maintenance — delivered by software developers and web developers who ship. Engage our software development agency to implement or customize it for your open-source databases stack.
Ready to simplify complex JPA queries?
Evaluate Blaze-Persistence for your Java backend if you need CTEs, keyset pagination, or projection mapping. Start with a Spring Boot or Core archetype and test against your JPA provider and database.