-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
password is not passed #304
Comments
it is my understanding that the password has to be included as part of the Redis URI. See https://lettuce.io/core/release/api/io/lettuce/core/RedisURI.html for the syntax |
@graemerocher graemerocher, Yes its true, however, considering the documentation: https://lettuce.io/core/release/reference/#connecting-redis I can use separately password and URL. Does Micronaut-Redis support that feauter? Now I should replace bean in micronaut by this: @Bean
@Replaces
@Primary
public RedisClient redisClient(AbstractRedisConfiguration configuration) {
return RedisClient.create(configuration);
} Information about password is set in |
@graemerocher The document just said:You can customize the Redis configuration using any properties exposed by the DefaultRedisConfiguration class. |
Are there any updates on this issue, please? It still seems not possible to specify the password separate from the URI. Since we are running the application in Kubernetes, I would like to specify the password from a Kubernetes Secret and it's available as an environment variable. If it has to be passed as part of the RedisURI in the |
Expected Behavior
Class
AbstractRedisClientFactory
has the methodpublic RedisClient redisClient(AbstractRedisConfiguration config, @Nullable ClientResources optionalClientResources, @Nullable List<ClientResourcesMutator> mutators) { //...
. The method have the following expression:Optional<RedisURI> uri = config.getUri();
The problem is that password is not copied, when I configured inapplication.yaml
For example:So I receive error:
io.lettuce.core.RedisCommandExecutionException: NOAUTH Authentication required.
Actual Behaviour
I expect that
config.getUri();
return the password writed inapplication.yaml
Steps To Reproduce
docker-compose up -d
My Password from application.yaml: null
. It is not expected password that I wrote.Environment Information
Example Application
https://github.com/rost5000/demo-lettuce-micronaut-bug
Version
v3.5.1
The text was updated successfully, but these errors were encountered: