-
Notifications
You must be signed in to change notification settings - Fork 0
Conversation
@Darksonn I am updating things to use an enum over the channel: https://github.com/tokio-rs/website-next/pull/47/files#diff-f33399dccf850e6da8211133469c97b2R5 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are some files without a newline at the end that show up with a red thingy in GitHub.
Co-authored-by: Alice Ryhl <[email protected]>
@Darksonn I ran |
[dependencies] | ||
tokio = { version = "0.2", features = ["full"] } | ||
bytes = "0.5" | ||
mini-redis = { path = "/home/carllerche/Code/tokio-mini-redis" } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems like fmt
doesn't run on Cargo.toml
```rust | ||
loop { | ||
async_op(); | ||
} | ||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think something should be changed with this example, but I am not sure what exactly. Perhaps something with a tokio::spawn
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1. I think while mentioning the needs to limit concurrency is great and very important, this thing is rather weird. I think it's coming out of 2 things:
- There is no visible concurrency. It's just an endless loop.
- The whole thing might only make sense if something around it does synchronous cancellation - which is yet another orthogonal concept.
Maybe just show limiting of concurrency via an async semaphore in a function? Or a bounded channel?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The thing I'm trying to call out is, w/ other styles of async (javascript's closures, java's eager fuutres, ...) doing a loop like that will end up just queuing implicitly.
I'm trying to call this out for those who have context. I don't think I did a great job though.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think this issue should block merging the page. We can either remove the section for now or track the problem in an issue.
Co-authored-by: Alice Ryhl <[email protected]>
I'm going to merge. The outstanding issue is tracked in #49 |
No description provided.