jpa 使用`findAll()时出现的问题:在< T>CoroutineCrudRepository上的Flow

oknwwptz  于 12个月前  发布在  其他
关注(0)|答案(1)|浏览(97)

我很确定这只是某种缺少的依赖,但我似乎不能在micronaut JPA存储库上使用CoroutineCrudRepository.findAll(): Flow<T>方法。
其他方法如预期的那样工作良好(例如,save()等),但是findAll()会导致抛出异常,如下所示:

java.lang.IllegalArgumentException: Cannot convert reactive type [class reactor.core.publisher.FluxLift] to type [interface kotlinx.coroutines.flow.Flow]. Ensure that you have the necessary Reactive module on your classpath. For example for Reactor you should have 'micronaut-reactor'.

micronaut-reactor添加到classpath并没有什么不同。我错过了什么?

相关问题