spring-batch
spring-batch copied to clipboard
Add item reader/writer for Redis
Add support to read data from and write data to Redis based on Spring Data Redis.
Reference: https://stackoverflow.com/questions/24703753/does-spring-batch-have-a-redis-itemreader-in-the-roadmap
Hello @benas, I would like to work on this. Any chance that you can provide some guidance ?
@santfirax Thank you for your offer to help! The writer could be based on KeyValueItemWriter for consistency with other key/value writers. For the reader, I need some time to reflect on the best way to read data from Redis (ie make the reader use a RedisTemplate or a Redis Repository). But I'm open to ideas, so you are welcome to open a PR and we can discuss it there.
Hello @benas I've created a PR for the write using RedisTemplate. https://github.com/spring-projects/spring-batch/pull/3961. Any chance that you can take a look at it ?
Hello, @benas. I have an idea about RedisRepositoryItemReader / RedisRepositoryItemWriter. They are based on RedisRepository. So ItemReader can read data that saved by RedisRepository. And ItemWriter can write data through RedisRepository. I would like to open a PR for this. Is there anything I should know?
Hi, @fmbenhassine. I wonder if this issue is handled by anyone. If not, may I try on this issue?
This was resolved in 1bd0e0c. Thanks @santfirax for the PR!
For the item reader, please join the discussion in #4446.
@fmbenhassine Thank you! I'll join above discussion.