go-redis / cache

Cache library with Redis backend for Golang
https://redis.uptrace.dev/guide/go-redis-cache.html
BSD 2-Clause "Simplified" License
757 stars 95 forks source link

Use github.com/go-redis/redis/v9 #86

Closed SemanticallyNull closed 2 years ago

SemanticallyNull commented 2 years ago

PR to support github.com/go-redis/redis/v9

I couldn't open a PR to create a new branch, but happy to recreate it against a branch once it's created. I ran the tests locally with some modifications to the package name to make sure it would work:

/usr/local/opt/go/libexec/bin/go test -json ./...
=== RUN   TestGinkgo
Running Suite: cache
====================
Random Seed: 1662388083
Will run 45 of 45 specs

•••••••••••••••••••••••••••••••••••••••••••••
Ran 45 of 45 Specs in 0.786 seconds
SUCCESS! -- 45 Passed | 0 Failed | 0 Pending | 0 Skipped
--- PASS: TestGinkgo (0.80s)
=== RUN   TestTinyLFU_Get_CorruptionOnExpiry
--- PASS: TestTinyLFU_Get_CorruptionOnExpiry (2.05s)
PASS
ok      github.com/SemanticallyNull/cache/v9    3.059s

Process finished with the exit code 0
pete-woods commented 2 years ago

@vmihailenco we would be very grateful if you have time to create a v9 branch for this repo. Some Redis libraries are starting to switch to the v9 Redis client, and without a v9 branch here, it forces us into dependency conflicts.

vmihailenco commented 2 years ago

@SemanticallyNull @pete-woods thanks for the PR :+1:

vmihailenco commented 2 years ago

Also released github.com/go-redis/cache/v9 v9.0.0-beta.1