Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a Redis backend #225

Closed
wants to merge 1 commit into from
Closed

Add a Redis backend #225

wants to merge 1 commit into from

Conversation

saimn
Copy link
Contributor

@saimn saimn commented Jan 8, 2018

I use this since a few months and it allows me to run multiple doit processes in parallel on different machines (with a shared NFS folder). I guess it should possible to run the test on Travis, I can try if you like the idea.

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.4%) to 99.333% when pulling 0988900 on saimn:redis into 6006b54 on pydoit:master.

@schettino72
Copy link
Member

This is pretty cool. I think lots of people (including myself) will like using this. Thanks.

But no way redis can be a dependency for doit.
I would like to see this as a doit plugin [1].
What do you think?

Testing code needs to be improved a bit so we dont need to check for DB type.

[1] http://pydoit.org/extending.html#plugins

@saimn
Copy link
Contributor Author

saimn commented Jan 18, 2018

redis could be just an optional dependency. I was not aware that it was possible to use the plugin system for backends, so yeah maybe it can be a plugin. Given the limitations of the other backends and the fact that redis a well-know solution for this, I think it deserves to be in core, but no strong feelings.

@schettino72
Copy link
Member

Given the limitations of the other backends and the fact that redis a well-know solution for this, I think it deserves to be in core, but no strong feelings.

I agree it is a limitation for some use-cases.

I know setting up a full project for some small plugins is very annoying. I dont want to put much burden on people contributing plugins, but on the other hand I dont have enough bandwidth to maintain even core doit... and I keep very high standard on doit that needs tests and reviews. In this point a plugin gives more freedom to developers.

redis is something I would definitely want as an "official" plugin. So we can use the docs and maybe even the same GIT repository. Would that be a good compromise?

ps. sorry for delay, but I will be able to (maybe) really do some work again on doit in february.

@saimn
Copy link
Contributor Author

saimn commented Jan 18, 2018

Yes having some plugins in core can be a compromise, as you prefer (I understand the maintenance burden, no worries).

I looked quickly and it seems that there are packages to mock redis for tests:
https://github.com/jamesls/fakeredis
https://github.com/ClearcodeHQ/pytest-redis
https://github.com/locationlabs/mockredis
This will make it easier to test, the most difficult part is probably choosing one of the packages ;)

@saimn
Copy link
Contributor Author

saimn commented Mar 19, 2018

@saimn saimn closed this Mar 19, 2018
@saimn saimn deleted the redis branch March 19, 2018 10:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants