Closed jangalinski closed 1 year ago
This is a good idea. Optional in query results was introduced after I designed the API (at least as far as I know) - so yes. Optional seems nice from the Java point of view but is even more complex to use out of Kotlin.... Let's go for it
Breaking change - should be at least in a minor release...
Should we do this for 3.3.0 while adding the potentially breaking changes to the view-api data classes?
No ... moved to 3.4.0
Moved to 3.6.0
While implementing #566 I noticed, that some Task queries uses a nullable
Task?
result. I would prefer using JavaOptional
here and use the AxonResponseTypes.optionalOf(...)
for query execution.The queries with changed results are all parts of the Task API:
TaskApi
TaskForIdQuery
TaskWithDataEntriesForIdQuery
ReactiveTaskApi
TaskForIdQuery
TaskWithDataEntriesForIdQuery
In a new API all these queries return
Optional
of the target type instead of Kotlin's nullable type (T?
).This is a breaking change to Polyflow <= 3.5.0.