小编Med*_*Med的帖子

找不到用户类型的属性索引

我正在尝试在同一项目中将ElasticSearch与MySQL一起使用。我在不同的项目中定义了两个存储库,但总是收到以下错误消息:

Exception in thread "main" org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'userController': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private com.owish.services.UserServices com.owish.controllers.UserController.userServices; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'userServices': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private com.owish.repositories.search.UserSearchRepo com.owish.services.UserServices.userSearchRepo; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'userSearchRepo': Invocation of init method failed; nested exception is org.springframework.data.mapping.PropertyReferenceException: No property index found for type User! …
Run Code Online (Sandbox Code Playgroud)

java spring spring-mvc elasticsearch spring-data

4
推荐指数
1
解决办法
5166
查看次数

标签 统计

elasticsearch ×1

java ×1

spring ×1

spring-data ×1

spring-mvc ×1