diff --git a/backend/src/main/java/ai/basic/x1/adapter/api/config/RedisConfig.java b/backend/src/main/java/ai/basic/x1/adapter/api/config/RedisConfig.java index 01cf9930..0c07f40e 100644 --- a/backend/src/main/java/ai/basic/x1/adapter/api/config/RedisConfig.java +++ b/backend/src/main/java/ai/basic/x1/adapter/api/config/RedisConfig.java @@ -33,6 +33,9 @@ public class RedisConfig { @Value("${spring.redis.password}") private String password; + @Value("${spring.redis.database}") + private int database; + @Bean public GenericJackson2JsonRedisSerializer jsonRedisSerializer( Jackson2ObjectMapperBuilder objectMapperBuilder) { @@ -55,6 +58,7 @@ public Jackson2HashMapper hashMapper(ObjectMapper objectMapper) { public LettuceConnectionFactory redisConnectionFactory() { var serverConfig = new RedisStandaloneConfiguration(host, port); serverConfig.setPassword(password); + serverConfig.setDatabase(database); var clientConfig = LettucePoolingClientConfiguration.builder() .readFrom(REPLICA_PREFERRED) diff --git a/backend/src/main/resources/application.yml b/backend/src/main/resources/application.yml index b99cd323..5eb0b692 100644 --- a/backend/src/main/resources/application.yml +++ b/backend/src/main/resources/application.yml @@ -2,8 +2,8 @@ debug: false logging: level: - org.springframework.web.filter.CommonsRequestLoggingFilter: info - ai.basic.basicai.user.adapter.port.dao.mybatis.mapper: info + org.springframework.web.filter.CommonsRequestLoggingFilter: debug + ai.basic.basicai.user.adapter.port.dao.mybatis.mapper: debug request: maxPayloadLength: 100000