正如您所看到的,我需要创建一个新的DefaultEntityMapper mapper = new DefaultEntityMapper();实例,但事实并非如此,因为它应该可以@Autowire EntityMapperDescription:
Field entityMapper in com.example.elasticsearch5.es.cluster.repository.impl.CustomizedCluserRepositoryImplrequired a bean of type 'org.springframework.
Spring-boot文档只提到它将从类路径中自动检测要使用的连接池,但默认情况下使用的是哪个实现?目前,在我的项目中,我有Commons DBCP,所以我假设它将是BasicDataSource?从spring-boot文档:
spring.datasource.type= # Fully qualified name of the connection pool implementation