Indexing domain object using elastichsearch, spring data and JPA -
im working on application using spring data , jpa implement rest-based service. want use elastcsearch indexing engine. domain object:
@document(indexname="elastic",type="user_demo") @entity @table(name="user_demo") public class userdemo { @org.springframework.data.annotation.id @id @generatedvalue(strategy = generationtype.identity) private long userid; private string emailaddress; private string name; private string login; private string password; ... }
on execution following exception: org.springframework.data.mapping.propertyreferenceexception: no property save found type userdemo!
if has comined jpa, spring data , spring data elasticsearch same domain object can share example.
separate repository packages above
@configuration @enableelasticsearchrepositories(basepackages = "demo.elasticrepository") @enablejparepositories(basepackages = "demo.repository") public class repoconfig { }
Comments
Post a Comment