Redis – Spring Boot use component in a custom class?
I have a redis util : @Component public class RedisUtil { @Autowired private StringRedisTemplate stringRedisTemplate; public StringRedisTemplate getStringRedisTemplate() { return this.stringRedisTemplate; } } I want to use it in my custom class which I don't want to be a component…