News for hackers. Stuff that matters.
Re:Why did we choose Rust to develop TiKV? by steveklabnik on Wednesday September 27, 2017 @02:21PM (#15350702)
Thanks!

Yeah, so this is basically the result of two things:

1. Rust-the-language focused on making concurrency safe, and getting primtives right

2. The higher-level aspects of the story are still shaking out.

The core primitives are very simple: Sync and Send, two traits which let you declare invariants. But most people don't want to be programming with primitives. So there's been a lot of iteration on what a higher-level story looks like. There are a ton of options, and we've been iterating through them to figure it out. The stuff you're seeing is the result of that process, so you're seeing how the sausage is made, which can definitely be confusing. It's all under active work, and then, once the pieces are in place, getting the right docs/tutorials there.

So, yes. Thanks. It's a good reminder. We'll get there :)

One last thing, as a small amount of food for thought:

> I feel in general Go's CSP model is more "powerful" and more "generic" than futures

In some senses, yes, but they also come with tradeoffs, like any technical choice. Specifically, in order to do concurrency this way, you must go with green threads. And green threads lead to smaller stacks, which leads to non-zero cost of calling into C code, which is a drawback that Rust can't sustain. It works great for Go, but can't really work in Rust, generally. I mean, you can do it, yes, but that drawback doesn't work for the majority of our audience.

It's these kinds of tricky, in-the-weeds stuff that makes designs hard and take time.

There are no comments on this comment yet.