[Reactive Mongo] Reactive MongoDB QueryDSL 버전 충돌
22.08.22 기준 latest version
querydsl-mongodb (5.0.0)
-> mongo-java-driver (3.12.11)
org.mongodb:mongodb-driver-reactivestreams (4.7.1)
-> mongodb-driver-core (4.7.1)
MongoDB 3.X -> org.mongodb:mongo-java-driver 사용
MongoDB 4.X -> org.mongodb:mongodb-driver-core 사용
reactiveMongo로 QueryDSL 사용은 mongoclient 버전이 맞지 않아 쓸 수 없다.
https://github.com/querydsl/querydsl/issues/3134
Legacy MongoDB driver included as dependency · Issue #3134 · querydsl/querydsl
Observed vs. expected behavior QueryDSL has been updated to support the MongoDB 4.x API, per #2689 (addressing #2681). However, querydsl-mongodb exports the 3.x driver as a compile-time dependency....
github.com
관련된 이슈가 등록 된지 1년이 넘어도 아직까지 bug 해결 및 지원 업데이트가 없다.
또한 QueryDSL 5.0.0 release 자체가 1년이 넘어가는 것 보면 QueryDSL은 Spring Framework에서 공식적으로 지원하지 않는 이상 오픈소스로써 기한을 다한듯 싶다.
reactive Mongo의 동적쿼리는 MongoTemplate를 써야할 것 같다.
https://github.com/querydsl/querydsl/issues/3131
Querydsl 5.0.0 not generating QClasses with apt-maven-plugin and jpaAnotationProcessor · Issue #3131 · querydsl/querydsl
My QClasses are not generated anymore. Error in the console : cannot find symbol : class QInsertionEntity. For each of the classes that use QClasses/Entities. I try to upgrade my querydsl to 5.0.0 ...
github.com
JPA 또한 이슈가 있어 보인다. 결과적으로 현재 QueryDSL은 Spring boot 버전을 못 따라가는 것 같다.