This commit is contained in:
lcj
2025-08-26 11:17:15 +08:00
commit 10c49e4518
1183 changed files with 797027 additions and 0 deletions

View File

@ -0,0 +1,25 @@
package org.dromara.common.elasticsearch.config;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.env.EnvironmentPostProcessor;
import org.springframework.core.Ordered;
import org.springframework.core.env.ConfigurableEnvironment;
/**
* 健康检查配置注入
*
* @author Lion Li
*/
public class ActuatorEnvironmentPostProcessor implements EnvironmentPostProcessor, Ordered {
@Override
public void postProcessEnvironment(ConfigurableEnvironment environment, SpringApplication application) {
System.setProperty("management.health.elasticsearch.enabled", "false");
}
@Override
public int getOrder() {
return Ordered.HIGHEST_PRECEDENCE;
}
}

View File

@ -0,0 +1,17 @@
package org.dromara.common.elasticsearch.config;
import org.dromara.easyes.spring.annotation.EsMapperScan;
import org.springframework.boot.autoconfigure.AutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
/**
* easy-es 配置
*
* @author Lion Li
*/
@AutoConfiguration
@ConditionalOnProperty(value = "easy-es.enable", havingValue = "true")
@EsMapperScan("org.dromara.**.esmapper")
public class EasyEsConfiguration {
}

View File

@ -0,0 +1,2 @@
org.springframework.boot.env.EnvironmentPostProcessor=\
org.dromara.common.elasticsearch.config.ActuatorEnvironmentPostProcessor

View File

@ -0,0 +1 @@
org.dromara.common.elasticsearch.config.EasyEsConfiguration