Skip to content

Commit

Permalink
fix: Added ssl args to RedisContext create method
Browse files Browse the repository at this point in the history
  • Loading branch information
jruaux committed Nov 1, 2024
1 parent e3810fa commit 7bf804a
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public abstract class AbstractRedisCommand extends AbstractJobCommand {

@Override
protected void execute() throws Exception {
redisContext = RedisContext.of(redisArgs.getUri(), redisArgs);
redisContext = RedisContext.of(redisArgs);
redisContext.afterPropertiesSet();
try {
super.execute();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public abstract class AbstractRedisExportCommand extends AbstractExportCommand {

@Override
protected RedisContext sourceRedisContext() {
return RedisContext.of(redisArgs.getUri(), redisArgs);
return RedisContext.of(redisArgs);
}

protected ItemProcessor<KeyValue<String>, Map<String, Object>> mapProcessor() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ public abstract class AbstractRedisImportCommand extends AbstractImportCommand {

@Override
protected RedisContext targetRedisContext() {
return RedisContext.of(redisArgs.getUri(), redisArgs);
return RedisContext.of(redisArgs);
}

public RedisArgs getRedisArgs() {
Expand Down
6 changes: 6 additions & 0 deletions plugins/riot/src/main/java/com/redis/riot/RedisContext.java
Original file line number Diff line number Diff line change
Expand Up @@ -173,4 +173,10 @@ public RedisContext clientResources(ClientResources clientResources) {
return this;
}

public static RedisContext of(RedisArgs args) {
RedisContext context = of(args.getUri(), args);
context.sslOptions(args.getSslArgs().sslOptions());
return context;
}

}

0 comments on commit 7bf804a

Please sign in to comment.