Spring Data REST does not seem to be working with elasticsearch
The workaround is to add
@EnableElasticsearchRepositories(repositoryFactoryBeanClass = RestElasticsearchRepositoryFactoryBean.class)
annotation to the application class where RestElasticsearchRepositoryFactoryBean is defined as
@SuppressWarnings("rawtypes")public class RestElasticsearchRepositoryFactoryBean extends org.springframework.data.elasticsearch.repository.support.ElasticsearchRepositoryFactoryBean { @SuppressWarnings("unchecked") @Override public void afterPropertiesSet() { setMappingContext(new org.springframework.data.elasticsearch.core.mapping.SimpleElasticsearchMappingContext()); super.afterPropertiesSet(); }}