diff --git a/iot-starter/src/main/java/cc/iotkit/config/EmbeddedElasticSearchConfig.java b/iot-starter/src/main/java/cc/iotkit/config/EmbeddedElasticSearchConfig.java index 35f2e241..32a63d38 100644 --- a/iot-starter/src/main/java/cc/iotkit/config/EmbeddedElasticSearchConfig.java +++ b/iot-starter/src/main/java/cc/iotkit/config/EmbeddedElasticSearchConfig.java @@ -23,10 +23,10 @@ import java.util.Collections; @Component public class EmbeddedElasticSearchConfig { - @Value("${spring.elasticsearch.embedded.enabled}") + @Value("${spring.elasticsearch.embedded.enabled:false}") private boolean embeddedElasticsearchEnabled; - @Value("${spring.elasticsearch.embedded.port}") + @Value("${spring.elasticsearch.embedded.port:9200}") private Integer esPort; @PostConstruct diff --git a/iot-starter/src/main/java/cc/iotkit/config/EmbeddedRedisConfig.java b/iot-starter/src/main/java/cc/iotkit/config/EmbeddedRedisConfig.java index 6b61574d..182396e0 100644 --- a/iot-starter/src/main/java/cc/iotkit/config/EmbeddedRedisConfig.java +++ b/iot-starter/src/main/java/cc/iotkit/config/EmbeddedRedisConfig.java @@ -20,9 +20,9 @@ import javax.annotation.PostConstruct; @Component public class EmbeddedRedisConfig { - @Value("${spring.redis.embedded.enabled}") + @Value("${spring.redis.embedded.enabled:false}") private boolean embeddedRedisEnabled; - @Value("${spring.redis.port}") + @Value("${spring.redis.port:6378}") private Integer redisPort; @PostConstruct