stevearc / pypicloud

S3-backed pypi server implementation
MIT License
506 stars 141 forks source link

Support redis-cluster as a cache option #308

Closed yannayh closed 2 years ago

yannayh commented 2 years ago

Hello!

I think it would be great if pypicloud would support redis-cluster, in order to work with high load and high performant setups.

The changes needed are adding an option to the redis configuration whether or not the redis is clustered, and if so - in the code, use the RedisCluster class instead of StrictRedis, as in newer versions of redis python package there is support for Redis in clustered mode. The interface of the classes is the same, and the code won’t need to change much.

Would love for the support in order to create huge pypicloud instances holding hundred thousand of packages.

Thanks!

stevearc commented 2 years ago

Sounds like a pretty straightforward change. I would happily review a PR for it!

yannayh commented 2 years ago

Opened #309 Would love a review 😃

yannayh commented 2 years ago

Hey @stevearc Can you release a new version of the package and build a new docker image?

stevearc commented 2 years ago

New release is out, and docker images are being uploaded