You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With kotlin and smallyre sometimes I need to declare the type again.
Additional details
Examples:
.transformToMulti { fetch(it.bananas).onItem().disjoint<Banana>() }
Without <Banana> it doesn't know that I fetch the Bananas.
.call { it -> if (it.type?.entityType == Apple) serviceApple.updateBy(it) else createUniFrom().nullItem<Apple>() }
Without <Apple> it doesn't know that it should return a nullItem with this type.
But shouldn't it know it already, because I return an Uni in the true case?
PS: nullItem<Void> and nullItem<Unit> are working too, which confuses me more.
There is .voidItem(), but that I would otherwise need to declare the type confuses me.
Maybe the java code of smallrye confuses kotlin?
Maybe we need kotlin classes as a layer in smallrye which optimize the kotlin compatibility?
As far as I know the Quarkus Framework uses this approach.
PS: I like the word confusing
The text was updated successfully, but these errors were encountered:
Like the idea and would love to investigate, unfortunately, I'm blocked for the next month. @MartinX3 how about meet at https://www.cloudland.org/ and discuss in person? ;)
@heubeck Sadly it's too expensive for me and I use Mutiny only for my job.
I don't use it in my volunteer tasks and my studies, so I also don't have time as well.
I found a new issue
It needs the type for the mapping function.
So .map(List<Double>::average) and .map { it.average() } are working, but .map(::average) throws an error.
With kotlin and smallyre sometimes I need to declare the type again.
Additional details
Examples:
.transformToMulti { fetch(it.bananas).onItem().disjoint<Banana>() }
Without
<Banana>
it doesn't know that I fetch the Bananas..call { it -> if (it.type?.entityType == Apple) serviceApple.updateBy(it) else createUniFrom().nullItem<Apple>() }
Without
<Apple>
it doesn't know that it should return a nullItem with this type.But shouldn't it know it already, because I return an Uni in the true case?
PS:
nullItem<Void>
andnullItem<Unit>
are working too, which confuses me more.There is
.voidItem()
, but that I would otherwise need to declare the type confuses me.Maybe the java code of smallrye confuses kotlin?
Maybe we need kotlin classes as a layer in smallrye which optimize the kotlin compatibility?
As far as I know the Quarkus Framework uses this approach.
PS: I like the word
confusing
The text was updated successfully, but these errors were encountered: