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

Async cache entry/insertion methods #63

Merged
merged 5 commits into from
Oct 28, 2020
Merged

Async cache entry/insertion methods #63

merged 5 commits into from
Oct 28, 2020

Conversation

jaemk
Copy link
Owner

@jaemk jaemk commented Oct 28, 2020

Moved from #60

@jaemk jaemk mentioned this pull request Oct 28, 2020
@jaemk jaemk merged commit 4eb2b0b into master Oct 28, 2020
@Stargateur
Copy link
Contributor

Stargateur commented Oct 28, 2020

I'm not sure change from a future to a closure that return a future is better. I follow the convention of tokio https://docs.rs/tokio/0.3.2/tokio/task/fn.spawn.html, taking a future. I'm ok with your way, anyway.

@jaemk
Copy link
Owner Author

jaemk commented Oct 28, 2020

@Stargateur that makes sense for spawn, but for other usages I think it makes more sense to follow the api's of things like https://docs.rs/futures/0.3.7/futures/stream/trait.TryStreamExt.html#method.and_then and take a closure returning an async block

@jaemk jaemk deleted the async branch January 21, 2022 19:56
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