Skip to content

Hooks for post-processing response of get() #35

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

Closed
wants to merge 2 commits into from

Conversation

alanjds
Copy link
Contributor

@alanjds alanjds commented Jan 16, 2015

For post-processing the response of get(), one can now reimplement the methods got_miss(...), got_hit(...) and got_stale(...)

This is util if you need to mark the answer based on the fact that it is from a cached resource

got_miss(...), got_hit(...) and got_stale(...)
@codeinthehole codeinthehole added this to the 1.0 milestone Jan 21, 2015
@codeinthehole
Copy link
Owner

Thanks for the PR. I'm not quite sure on what the right API is - I tinkered around with it to use a simpler API here: bf7e025

Seem ok to you?

@alanjds
Copy link
Contributor Author

alanjds commented Jan 29, 2015

Seems ok for me. I like separate methods, but if I want to segregate, I can make implement process_response to do the internal routing for me.

@alanjds
Copy link
Contributor Author

alanjds commented Jan 29, 2015

Anyway, I had some experimentation on HIT-STALE and HIT-FRESH. Your version eases it. Expect some PR about this ;)

@codeinthehole
Copy link
Owner

Anyway, I had some experimentation on HIT-STALE and HIT-FRESH. Your version eases it. Expect some PR about this ;)

Does mean you're happy to go with my version?

@alanjds
Copy link
Contributor Author

alanjds commented Jan 31, 2015

Yes. I will take some time to refactor my systems, but your version is more future-proof. Please stick with your API

@codeinthehole
Copy link
Owner

Cool - now merged.

@alanjds
Copy link
Contributor Author

alanjds commented Feb 18, 2015

Closing, as it is "now merged" by @codeinthehole

@alanjds alanjds closed this Feb 18, 2015
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.

2 participants