Releases: querydsl/querydsl
5.1.0
What's Changed
- Bump jcc from 11.5.5.0 to 11.5.6.0 by @dependabot in #2956
- Bump classgraph from 4.8.108 to 4.8.110 by @dependabot in #2959
- Bump postgresql from 42.2.22 to 42.2.23 by @dependabot in #2960
- Bump dokka-maven-plugin from 1.4.32 to 1.5.0 by @dependabot in #2961
- Bump spring-jdbc from 5.3.8 to 5.3.9 by @dependabot in #2966
- Bump ant from 1.10.10 to 1.10.11 by @dependabot in #2967
- Bump mongo-java-driver from 3.12.8 to 3.12.9 by @dependabot in #2970
- Bump mysql-connector-java from 8.0.25 to 8.0.26 by @dependabot in #2973
- Bump slf4j.version from 1.7.31 to 1.7.32 by @dependabot in #2975
- Bump sqlite-jdbc from 3.36.0 to 3.36.0.1 by @dependabot in #2957
- Bump kotlin.version from 1.5.20 to 1.5.21 by @dependabot in #2965
- Bump classgraph from 4.8.110 to 4.8.115 by @dependabot in #3000
- Bump mongo-java-driver from 3.12.9 to 3.12.10 by @dependabot in #2989
- Bump spring-boot-starter-parent from 2.5.2 to 2.5.4 by @dependabot in #3002
- Bump jmh.version from 1.32 to 1.33 by @dependabot in #2991
- Bump kotlin.version from 1.5.21 to 1.5.30 by @dependabot in #3006
- Bump annotations from 21.0.1 to 22.0.0 by @dependabot in #2998
- Bump sqlite-jdbc from 3.36.0.1 to 3.36.0.3 by @dependabot in #3010
- Bump javax.jdo from 3.2.0-m13 to 3.2.0-release by @dependabot in #2992
- Bump classgraph from 4.8.115 to 4.8.116 by @dependabot in #3020
- fixed codegen-utils artifactId in bom by @lpandzic in #3033
- Bump classgraph from 4.8.116 to 4.8.128 by @dependabot in #3057
- Bump kotlin.version from 1.5.30 to 1.5.31 by @dependabot in #3034
- Bump lombok from 1.18.20 to 1.18.22 by @dependabot in #3051
- Bump kotlinpoet from 1.9.0 to 1.10.1 by @dependabot in #3037
- Bump dokka-maven-plugin from 1.5.0 to 1.5.31 by @dependabot in #3050
- fix typo by @Camork in #3055
- Bump plexus-utils from 3.3.0 to 3.4.1 by @dependabot in #3009
- Bump guava from 30.1.1-jre to 31.0.1-jre by @dependabot in #3044
- Bump joda-time from 2.10.10 to 2.10.12 by @dependabot in #3046
- Bump maven-javadoc-plugin from 3.3.0 to 3.3.1 by @dependabot in #3018
- Bump maven-pmd-plugin from 3.14.0 to 3.15.0 by @dependabot in #3026
- Bump kotlinpoet from 1.10.1 to 1.10.2 by @dependabot in #3070
- Bump spring-boot-starter-parent from 2.5.4 to 2.5.6 by @dependabot in #3067
- Bump spring.version from 5.3.9 to 5.3.12 by @dependabot in #3065
- Improve Kotlin Codegen Spring Data Interop by @F43nd1r in #3076
- Bump spring-boot-starter-parent from 2.5.6 to 2.6.1 by @dependabot in #3106
- Bump checkstyle from 8.44 to 9.2 by @dependabot in #3103
- Bump maven-plugin-plugin from 3.6.1 to 3.6.2 by @dependabot in #3101
- Bump kotlin.version from 1.5.31 to 1.6.0 by @dependabot in #3087
- Bump dokka-maven-plugin from 1.5.31 to 1.6.0 by @dependabot in #3098
- Bump spring.version from 5.3.12 to 5.3.13 by @dependabot in #3082
- Bump ant from 1.10.11 to 1.10.12 by @dependabot in #3061
- Bump hibernate-search-orm from 5.11.9.Final to 5.11.10.Final by @dependabot in #3060
- Bump annotations from 22.0.0 to 23.0.0 by @dependabot in #3083
- Bump spring-jdbc from 5.3.12 to 5.3.13 by @dependabot in #3084
- Bump postgresql from 42.2.23 to 42.3.1 by @dependabot in #3077
- Removal of java < 8 compatibility code by @yorlov in #3079
- Bump checkstyle from 9.2 to 9.3 by @dependabot in #3168
- Bump spring-boot-starter-parent from 2.6.1 to 2.6.3 by @dependabot in #3158
- Bump kotlin.version from 1.6.0 to 1.6.10 by @dependabot in #3122
- Bump jcc from 11.5.6.0 to 11.5.7.0 by @dependabot in #3128
- Bump guice from 5.0.1 to 5.1.0 by @dependabot in #3163
- Bump hibernate-validator from 7.0.1.Final to 7.0.2.Final by @dependabot in #3159
- Bump slf4j.version from 1.7.32 to 1.7.35 by @dependabot in #3162
- Bump maven-plugin-plugin from 3.6.2 to 3.6.4 by @dependabot in #3155
- Bump maven-compiler-plugin from 3.8.1 to 3.9.0 by @dependabot in #3150
- Bump jmh.version from 1.33 to 1.34 by @dependabot in #3138
- Bump spring-jdbc from 5.3.13 to 5.3.15 by @dependabot in #3152
- Bump jboss-logging from 3.4.2.Final to 3.4.3.Final by @dependabot in #3149
- Bump maven-bundle-plugin from 5.1.2 to 5.1.4 by @dependabot in #3143
- Bump maven-jar-plugin from 3.2.0 to 3.2.2 by @dependabot in #3148
- Removes SpringRoo dependencies by @burricks in #3092
- Fixes "parameter 'catalogPattern' is not set for querydsl-maven-plugin by @USK-DIMA in #3175
- Addresses listagg #2778 by @yang03265 in #3114
- Bump kotlin.version from 1.6.10 to 1.6.21 by @dependabot in #3241
- Bump spring-boot-starter-parent from 2.6.3 to 2.6.7 by @dependabot in #3243
- Bump maven-compiler-plugin from 3.9.0 to 3.10.1 by @dependabot in #3198
- Bump hibernate-validator from 7.0.2.Final to 7.0.4.Final by @dependabot in #3199
- Bump maven-javadoc-plugin from 3.3.1 to 3.4.0 by @dependabot in #3242
- Bump postgresql from 42.3.1 to 42.3.4 by @dependabot in #3240
- Bump lombok from 1.18.22 to 1.18.24 by @dependabot in #3239
- Bump spring-jdbc from 5.3.15 to 5.3.19 by @dependabot in #3234
- Bump asm-commons from 9.2 to 9.3 by @dependabot in #3231
- Bump jacoco-maven-plugin from 0.8.7 to 0.8.8 by @dependabot in #3230
- Bump asm from 9.2 to 9.3 by @dependabot in #3229
- Bump jmh.version from 1.34 to 1.35 by @dependabot in #3221
- Bump maven-jxr-plugin from 3.1.1 to 3.2.0 by @dependabot in #3214
- Bump joda-time from 2.10.12 to 2.10.14 by @dependabot in #3213
- Bump dn.version from 5.2.7 to 5.2.8 by @dependabot in #3194
- Bump guava from 31.0.1-jre to 31.1-jre by @dependabot in #3191
- Bump kotlinpoet from 1.10.2 to 1.11.0 by @dependabot in #3217
- Bump classgraph from 4.8.128 to 4.8.146 by @dependabot in #3238
- add $geoIntersects by @sangyongchoi in #3195
- Bump dokka-maven-plugin from 1.6.0 to 1.6.21 by @dependabot in #3249
- add nullable annotation in Fetchable by @sangyongchoi in #3245
- Bump mongo-java-driver from 3.12.10 to 3.12.11 by @dependabot in #3248
- Bump mysql-connector-java from 8.0.26 to 8.0.29 by @dependabot in #3246
- Fix yml error on issue template config by @msacakci in #3287
- Introduce japicmp by @F43nd1r in #2977
- MS SQL Server: replace old, unmaintained jTDS driver with mssql-jdbc by @rdicroce in #3403
- Firebird: upgrade JDBC driver to latest. Maven coordinates changed. by...
5.0.0
This release of QueryDSL targets Java 8 minimally and comes with various improvements to make QueryDSL ready for the modern Java ecosystem.
This version also removes joda-time:joda-time
, com.google.guava:guava
and com.google.code.findbugs:jsr305
as required runtime dependencies for using QueryDSL.
QueryDSL 5.0 is the long awaited major release after the QueryDSL project was left mostly unmaintained for over two years.
With this release the team worked hard on resolving the most pressing issues that have been requested repeatedly for a long time.
A huge thanks goes out to all contributors that made this release possible in their free time:
- @mp911de, for working on the MongoDB Document API;
- @daniel-shuy, for working on decoupling
querydsl-sql
fromjoda-time:joda-time
; - @heesuk-ahn, for working on improved Hibernate support and count query generation in
JPASQLQuery
; - @harshtuna, for working on NullsLast ordering in
querydsl-collections
; - @kherrala, @ridoo and @NikitaKochkurov for working on the JTS and GeoLatte upgrade for
querydsl-spatial
; - @ridoo, for working on Spatial support in
HibernateDomainExporter
andJPADomainExporter
; - @lpandzic, for working on codegen support for Java 15 records and general improvements;
- @F43nd1r, for working on Kotlin Code generation, Java 11 support, general improvements and Continuous Integration;
- @jwgmeligmeyling, @Shredder121, @johnktims, @idosal and @robertandrewbain.
New features
- #2672 - Various performance and code improvements possible by targeting Java 8 source level.
- #2672 - Added
Fetchable#stream()
which returns aStream<T>
.
Make sure that the returned stream is always closed to free up resources, for example using try-with-resources.
It does not suffice to rely on a terminating operation on the stream for this (i.e.forEach
,collect
). - #2324 - Removal of Guava as dependency.
Almost no required transitive dependencies to get started with QueryDSL.
And no more conflicts with Guava versions required by your other tools or own application. - #2025 -
joda-time:joda-time
is no longer a required dependency forquerydsl-sql
.
By default, the Java 8 date/time API is used for date/time operations.
Thejoda-time:joda-time
types will still be registered automatically if they are on the classpath. - #2215 - MongoDB 4 support through the Document API
- #2697 - Allow
com.querydsl.core.alias.Alias.*
to be used on a JRE by relying on ECJ as compiler - #2479 - Swap out JSR305 for Jetbrains Annotations.
Because the Jetbrains Annotations, contrary to the JSR305 annotations, use a Class retention level, Jetbrains Annotations
does not have to be available at runtime and is not a transitive dependency. - #658 - Added
JPAExpressions#treat
which can be used to generate JPA 2.1 Treated path expressions. - #2666 - More descriptive error message when using unsupported query features in JPA.
- #2106 - Support NullsLast ordering in
querydsl-collections
. - #2404 - Upgrade of JTS / Geolatte in
querydsl-spatial
- #2320 - Make Spatial support available to
HibernateDomainExporter
andJPADomainExporter
. - #2612 - Support jakarta.* packages for new Jakarta EE releases (available through the
jakarta
classifiers for Maven) - #1376 - Return typed expression from
nullif
andcoalesce
methods. - #1828 - Kotlin Codegen support
- #2798 - Java Record support
Bugfixes
- #2579 - Count query generation in
JPASQLQuery
- #2671 - Fixed a concurrency issue in
Alias.*
.Alias.*
is now Thread safe. - #2053 - Work around issues with
AbstractJPAQuery#fetchResults
andAbstractJPAQuery#fetchCount
in a query with a having clause by using an in-memory calculation. - #2504 - Work around issues with
AbstractJPAQuery#fetchResults
andAbstractJPAQuery#fetchCount
in a query with multiple group by expressions by using an in-memory calculation. - #2663 - Fix issues with the JPA implementation of
InsertClause
. - #2706 - Fix a memory leak in
TemplateFactory
. - #2467 - Prevent
ExtendedBeanSerializer
from generatingtoString
method twice - #2326 - Use JPA indexed parameters instead of HQL's legacy positional parameters
- #2816 - Generated JPA query with incorrect argument binding indexes
- #1413 - Incorrect parameter values with Hibernate custom types
- #1429 - Reusing of constants in JPQL generation causes issues with hibernate query caching
Breaking changes
- Java 8 minimal requirement. If you still rely on Java <7, please use the latest 4.x.x version.
JavaSE6SQLExceptionWrapper
and other parts regarding pre-Java 7 exception handling are removed.- Removed bridge method that were in place for backwards compatibility of legacy API's. This may lead to some breaking API changes.
- Removed Guava as a dependency. If your application relies on Guava, make sure to add it as a direct dependency for your project and not rely on QueryDSL shipping it transitively.
- In order for Guava to be removed Mysema Codegen had to be rereleased as QueryDSL Codegen Utils.
Therefore, the classes in this module moved to a different package:com.mysema.codegen
is nowcom.querydsl.codegen.utils
.
This for example affectscom.mysema.codegen.model.SimpleType
.
Although many applications won't touch the codgen internal classes, custom APT extensions might be affected by this. - Due to the removal of Guava, any method that received an
ImmutableList
as parameter, now accepts anyList
instead.
Normal code should handle this signature just fine.
However, make sure to check any reflective uses of these parameters. - The
querydsl.variableNameFunctionClass
property for theDefaultConfiguration
should now be provided as ajava.util.function.Function
instead of acom.google.common.base.Function
. CodeWriter#beginStaticMethod
now takes ajava.util.function.Function
instead of acom.google.common.base.Function
.AbstractLuceneQuery
now takes ajava.util.function.Function
instead of acom.google.common.base.Function
.AbstractMongodbQuery
now takes ajava.util.function.Function
instead of acom.google.common.base.Function
.com.querydsl.codegen.NamingFunction
,EvaluatorFunction
,DefaultVariableFunction
now extendjava.util.function.Function
instead ofcom.google.common.base.Function
.- Any constructor that received a
javax.inject.Provider
, now takes ajava.util.function.Supplier
instead. In most cases you can replace the argument withprovider::get
. - This release targets Hibernate 5.2 in the Hibernate integration. If you need Hibernate 4 dialect specific workarounds, use the
HQLTemplates
instead of theHibernate5Templates
. - Removal of various deprecated methods.
joda-time:joda-time
is now an optional dependency. If your application relies onjoda-time:joda-time
make sure to specify it as a direct dependency rather than relying on QueryDSL to include it transitively.com.google.code.findbugs:jsr305
is no longer a dependency. If your application currently relies on QueryDSL shipping JSR305 transitively, you should add JSR305 as a direct dependency to your project.- MDC keys now use an underscore instead of a dot as separator:
querydsl.query
now isquerydsl_query
andquerydsl.parameters
isquerydsl_parameters
. - Removal of
PolyHedralSurface
inquerydsl-spatial
andquerydsl-sql-spatial
due to the upgrade ofgeolatte-geom
. com.querydsl.apt.Extension
moved tocom.querydsl.codegen
and now resides in thequerydsl-codegen
module.com.querydsl.apt.SpatialSupport
moved tocom.querydsl.spatial.apt.SpatialSupport
and now resides in thequerydsl-spatial
module.com.querydsl.sql.codegen.SpatialSupport
moved tocom.querydsl.sql.spatial.SpatialSupport
and now resides in thequerydsl-sql-spatial
module.SQLServerGeometryReader
inquerydsl-sql-spatial
is removed in favour oforg.geolatte.geom.codec.db.sqlserver.*
.PGgeometryConverter
in `...
5.0.0.M1
This release of QueryDSL targets Java 8 minimally and comes with various improvements to make QueryDSL ready for the modern Java ecosystem.
This version also removes joda-time:joda-time
, com.google.guava:guava
and com.google.code.findbugs:jsr305
as required runtime dependencies for using QueryDSL.
QueryDSL 5.0 is the long awaited major release after the QueryDSL project was left mostly unmaintained for over two years.
With this release the team worked hard on resolving the most pressing issues that have been requested repeatedly for a long time.
A huge thanks goes out to all contributors that made this release possible in their free time:
- @mp911de, for working on the MongoDB Document API;
- @daniel-shuy, for working on decoupling
querydsl-sql
fromjoda-time:joda-time
; - @heesuk-ahn, for working on improved Hibernate support and count query generation in
JPASQLQuery
; - @harshtuna, for working on NullsLast ordering in
querydsl-collections
; - @kherrala, @ridoo and @NikitaKochkurov for working on the JTS and GeoLatte upgrade for
querydsl-spatial
; - @ridoo, for working on Spatial support in
HibernateDomainExporter
andJPADomainExporter
; - @lpandzic, for working on codegen support for Java 15 records and general improvements;
- @F43nd1r, for working on Kotlin Code generation, Java 11 support, general improvements and Continuous Integration;
- @jwgmeligmeyling, @Shredder121, @johnktims, @idosal and @robertandrewbain.
New features
- #2672 - Various performance and code improvements possible by targeting Java 8 source level.
- #2672 - Added
Fetchable#stream()
which returns aStream<T>
.
Make sure that the returned stream is always closed to free up resources, for example using try-with-resources.
It does not suffice to rely on a terminating operation on the stream for this (i.e.forEach
,collect
). - #2324 - Removal of Guava as dependency.
Almost no required transitive dependencies to get started with QueryDSL.
And no more conflicts with Guava versions required by your other tools or own application. - #2025 -
joda-time:joda-time
is no longer a required dependency forquerydsl-sql
.
By default, the Java 8 date/time API is used for date/time operations.
Thejoda-time:joda-time
types will still be registered automatically if they are on the classpath. - #2215 - MongoDB 4 support through the Document API
- #2697 - Allow
com.querydsl.core.alias.Alias.*
to be used on a JRE by relying on ECJ as compiler - #2479 - Swap out JSR305 for Jetbrains Annotations.
Because the Jetbrains Annotations, contrary to the JSR305 annotations, use a Class retention level, Jetbrains Annotations
does not have to be available at runtime and is not a transitive dependency. - #658 - Added
JPAExpressions#treat
which can be used to generate JPA 2.1 Treated path expressions. - #2666 - More descriptive error message when using unsupported query features in JPA.
- #2106 - Support NullsLast ordering in
querydsl-collections
. - #2404 - Upgrade of JTS / Geolatte in
querydsl-spatial
- #2320 - Make Spatial support available to
HibernateDomainExporter
andJPADomainExporter
. - #2612 - Support jakarta.* packages for new Jakarta EE releases (available through the
jakarta
classifiers for Maven) - #1376 - Return typed expression from
nullif
andcoalesce
methods. - #1828 - Kotlin Codegen support
- #2798 - Java Record support
Bugfixes
- #2579 - Count query generation in
JPASQLQuery
- #2671 - Fixed a concurrency issue in
Alias.*
.Alias.*
is now Thread safe. - #2053 - Work around issues with
AbstractJPAQuery#fetchResults
andAbstractJPAQuery#fetchCount
in a query with a having clause by using an in-memory calculation. - #2504 - Work around issues with
AbstractJPAQuery#fetchResults
andAbstractJPAQuery#fetchCount
in a query with multiple group by expressions by using an in-memory calculation. - #2663 - Fix issues with the JPA implementation of
InsertClause
. - #2706 - Fix a memory leak in
TemplateFactory
. - #2467 - Prevent
ExtendedBeanSerializer
from generatingtoString
method twice - #2326 - Use JPA indexed parameters instead of HQL's legacy positional parameters
- #2816 - Generated JPA query with incorrect argument binding indexes
- #1413 - Incorrect parameter values with Hibernate custom types
- #1429 - Reusing of constants in JPQL generation causes issues with hibernate query caching
Breaking changes
- Java 8 minimal requirement. If you still rely on Java <7, please use the latest 4.x.x version.
JavaSE6SQLExceptionWrapper
and other parts regarding pre-Java 7 exception handling are removed.- Removed bridge method that were in place for backwards compatibility of legacy API's. This may lead to some breaking API changes.
- Removed Guava as a dependency. If your application relies on Guava, make sure to add it as a direct dependency for your project and not rely on QueryDSL shipping it transitively.
- In order for Guava to be removed Mysema Codegen had to be rereleased as QueryDSL Codegen Utils.
Therefore, the classes in this module moved to a different package:com.mysema.codegen
is nowcom.querydsl.codegen.utils
.
This for example affectscom.mysema.codegen.model.SimpleType
.
Although many applications won't touch the codgen internal classes, custom APT extensions might be affected by this. - Due to the removal of Guava, any method that received an
ImmutableList
as parameter, now accepts anyList
instead.
Normal code should handle this signature just fine.
However, make sure to check any reflective uses of these parameters. - The
querydsl.variableNameFunctionClass
property for theDefaultConfiguration
should now be provided as ajava.util.function.Function
instead of acom.google.common.base.Function
. CodeWriter#beginStaticMethod
now takes ajava.util.function.Function
instead of acom.google.common.base.Function
.AbstractLuceneQuery
now takes ajava.util.function.Function
instead of acom.google.common.base.Function
.AbstractMongodbQuery
now takes ajava.util.function.Function
instead of acom.google.common.base.Function
.com.querydsl.codegen.NamingFunction
,EvaluatorFunction
,DefaultVariableFunction
now extendjava.util.function.Function
instead ofcom.google.common.base.Function
.- Any constructor that received a
javax.inject.Provider
, now takes ajava.util.function.Supplier
instead. In most cases you can replace the argument withprovider::get
. - This release targets Hibernate 5.2 in the Hibernate integration. If you need Hibernate 4 dialect specific workarounds, use the
HQLTemplates
instead of theHibernate5Templates
. - Removal of various deprecated methods.
joda-time:joda-time
is now an optional dependency. If your application relies onjoda-time:joda-time
make sure to specify it as a direct dependency rather than relying on QueryDSL to include it transitively.com.google.code.findbugs:jsr305
is no longer a dependency. If your application currently relies on QueryDSL shipping JSR305 transitively, you should add JSR305 as a direct dependency to your project.- MDC keys now use an underscore instead of a dot as separator:
querydsl.query
now isquerydsl_query
andquerydsl.parameters
isquerydsl_parameters
. - Removal of
PolyHedralSurface
inquerydsl-spatial
andquerydsl-sql-spatial
due to the upgrade ofgeolatte-geom
. com.querydsl.apt.Extension
moved tocom.querydsl.codegen
and now resides in thequerydsl-codegen
module.com.querydsl.apt.SpatialSupport
moved tocom.querydsl.spatial.apt.SpatialSupport
and now resides in thequerydsl-spatial
module.com.querydsl.sql.codegen.SpatialSupport
moved tocom.querydsl.sql.spatial.SpatialSupport
and now resides in thequerydsl-sql-spatial
module.SQLServerGeometryReader
inquerydsl-sql-spatial
is removed in favour oforg.geolatte.geom.codec.db.sqlserver.*
.PGgeometryConverter
in `...
4.4.0
Merge pull request #2649 from querydsl/querydsl-4.4.0 Querydsl 4.4.0
4.3.1
Merge pull request #2549 from querydsl/querydsl-4.3.1 Querydsl 4.3.1
4.2.2
Verify the release process works
4.2.1
Fixes issues https://github.com/querydsl/querydsl/issues?q=milestone%3A4.2.1
Download for non-Maven users : http://www.querydsl.com/static/querydsl/4.2.1
Reference docs : http://www.querydsl.com/static/querydsl/4.2.1/reference/html/
Javadoc API : http://www.querydsl.com/static/querydsl/4.2.1/apidocs/
4.2.0
Replaced by 4.2.1 because of buggy release artifacts
4.1.4
Fixes issues https://github.com/querydsl/querydsl/issues?q=milestone%3A4.1.4
Download for non-Maven users : http://www.querydsl.com/static/querydsl/4.1.4
Reference docs : http://www.querydsl.com/static/querydsl/4.1.4/reference/html/
Javadoc API : http://www.querydsl.com/static/querydsl/4.1.4/apidocs/
4.1.3
Fixes issues https://github.com/querydsl/querydsl/issues?q=milestone%3A4.1.3
Download for non-Maven users : http://www.querydsl.com/static/querydsl/4.1.3
Reference docs : http://www.querydsl.com/static/querydsl/4.1.3/reference/html/
Javadoc API : http://www.querydsl.com/static/querydsl/4.1.3/apidocs/