Skip to content

Commit

Permalink
refactor(web/test): update RedisTestConfig (#1734)
Browse files Browse the repository at this point in the history
to use the hostname and JedisPool from EmbeddedRedis
  • Loading branch information
dbyron-sf authored Nov 10, 2023
1 parent 9524bfa commit b955ddd
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,12 @@ class RedisTestConfig {
@Primary
@SpringSessionRedisConnectionFactory
JedisConnectionFactory jedisConnectionFactory(EmbeddedRedis embeddedRedis) {
return new JedisConnectionFactory(new RedisStandaloneConfiguration("127.0.0.1", embeddedRedis.port))
return new JedisConnectionFactory(new RedisStandaloneConfiguration(embeddedRedis.host, embeddedRedis.port))
}

@Bean
@Primary
JedisPool jedis(EmbeddedRedis embeddedRedis) {
return new JedisPool(new URI("redis://127.0.0.1:$embeddedRedis.port"), 5000)
return embeddedRedis.getPool();
}
}

0 comments on commit b955ddd

Please sign in to comment.