micronaut是否有一种方法可以使"Spring Data JPA"成为可能.从像春天这样的界面自动生成的存储库? [英] Is there with micronaut a way to have the "Spring Data JPA" repository autogenerated from an interface like in spring?

查看:267
本文介绍了micronaut是否有一种方法可以使"Spring Data JPA"成为可能.从像春天这样的界面自动生成的存储库?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用micronaut设置新的微服务,并希望它通过jpa/hibernate访问数据库.

Im setting up a new micro service with micronaut and want it to access a database over jpa/hibernate.

是否有一种简单的方法可以像使用spring这样从接口自动生成"Spring Data JPA"存储库实现?

Is there an easy way to have the "Spring Data JPA" repositories implementation to be autogenerated from the interface like with spring?

interface ExampleRepository {
    fun FindById(id: String): Example
}

理想情况下,我可以通过DI将ExampleRepository导入到我的服务中.

Ideally i would the be able to import an ExampleRepository over DI into my service.

Micronaut数据正在发布过程中: https://github.com /micronaut-projects/micronaut-data

Micronaut Data is in the process of being released: https://github.com/micronaut-projects/micronaut-data

推荐答案

目前尚未计划,尽管将来计划使用此功能.

Not currently, although such a feature is planned for the future.

这篇关于micronaut是否有一种方法可以使"Spring Data JPA"成为可能.从像春天这样的界面自动生成的存储库?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆