-
Notifications
You must be signed in to change notification settings - Fork 131
Description
HI, I was looking at the Kotlin extensions Criteria.CriteriaStep.isEquals that now is deprecated
spring-data-r2dbc/src/main/kotlin/org/springframework/data/r2dbc/core/CriteriaStepExtensions.kt
Lines 26 to 28 in 23dbcc1
| @Deprecated("Deprecated in favor of Spring Data Relational's Criteria") | |
| infix fun Criteria.CriteriaStep.isEquals(value: Any): Criteria = | |
| `is`(value) |
I guess that is because org.springframework.data.r2dbc.query.Criteria is as well deprecated and we should use org.springframework.data.relational.core.query.Criteria instead, but I can not find and extension similar to the previous isEquals for Kotlin.
Before deprecation, I could do something like:
import org.springframework.data.r2dbc.core.from
import org.springframework.data.r2dbc.core.isEquals
import org.springframework.data.r2dbc.query.Criteria.where
....
databaseClient
.select().from<Foo>()
.matching(where("id").isEquals("bar"))
.fetch().one()Now I need to do:
import org.springframework.data.r2dbc.core.from
import org.springframework.data.relational.core.query.Criteria.where
....
databaseClient
.select().from<Foo>()
.matching(where("id").`is`("bar"))
.fetch().one()Maybe there are new extensions for org.springframework.data.relational.core.query.Criteria that I not aware of?
I can contribute with some, but that may imply dependency on the Kotlin runtime in spring-data-relational, maybe we should have something like https://github.com/reactor/reactor-kotlin-extensions ?
Thanks