spring-data-redis
spring-data-redis copied to clipboard
Duplicate code in StringToPropertiesConverter class
public class StringToPropertiesConverter implements Converter<String, Properties> {
@Override
public Properties convert(String source) {
Properties info = new Properties();
try (StringReader stringReader = new StringReader(source)) {
info.load(stringReader);
} catch (Exception ex) {
throw new RedisSystemException("Cannot read Redis info", ex);
}
return info;
}
}
Converting String type content into Properties has been defined in org.springframework.data.redis.connection.convert.Converters.
Can I try to optimize and submit a PR?
Feel free. We should actually deprecate StringToPropertiesConverter and use only the one from Converters.toProperties(…).
Hi, I noticed there is already a PR for this issue, but it seems to be inactive. Is this still being worked on?
Hi! @wendy512
If this issue is still open, I’d love to give it a shot and fix it.
Would that be alright?