News for hackers. Stuff that matters.
Re:Rustful – A RESTful web framework for Rust by m0th87 on Wednesday October 15, 2014 @01:08PM (#8459888)
With Rust's switch to 1:1 threading (soon to be not even optional AFAIK), how will this affect the concurrency capabilities of Rust-based web servers, and servers in general?
Re:Rustful – A RESTful web framework for Rust by 15020 on Wednesday October 15, 2014 @03:30PM (#8461123)
It will have the same problems as any other webserver utilizing blocking IO.

Various people are working on async IO solutions; but it likely won't fall into the stdlib from what I can tell.

I'm currently working on a rust abstraction for epoll and kqueue to eventually be paired with a multithreaded event loop/reactor. Lots of stuff to reimplement.

Re:Rustful – A RESTful web framework for Rust by ehsanu1 on Wednesday October 15, 2014 @04:07PM (#8461371)
Is there a github repo or similar for what you're working on?
Re:Rustful – A RESTful web framework for Rust by deskamess on Wednesday October 15, 2014 @06:40PM (#8462246)
I found this... https://github.com/carllerche/mio

No windows support yet, but planned.

Re:Rustful – A RESTful web framework for Rust by Shamanmuni on Wednesday October 15, 2014 @01:33PM (#8460148)
AFAIK green threads were removed from the core language but are available as crate green (also known as greenlib). You can use that for building servers.

http://doc.rust-lang.org/green/

Re:Rustful – A RESTful web framework for Rust by ben0x539 on Wednesday October 15, 2014 @03:00PM (#8460898)
*libgreen

They're gonna get yanked out of the core distribution too and won't be integrated in the stdlib IO anymore, so it's fair to say that Rust is switching to 1:1 threading.

Re:Rustful – A RESTful web framework for Rust by kaoD on Wednesday October 15, 2014 @03:51PM (#8461268)
Any reason why? I'd love to read some discussion about it.
Re:Rustful – A RESTful web framework for Rust by ben0x539 on Wednesday October 15, 2014 @04:04PM (#8461357)
Since both threading models were supported and compatible throughout IO, concurrency primitives and other runtime bits, the design of both was considered to be constrained too much to get either model where it should be.

The decision was made around https://github.com/rust-lang/rfcs/pull/230 but I'm not sure whether there's any important prior discussion not linked from there, the topic has been kicked around for a bit.

Re:Rustful – A RESTful web framework for Rust by steveklabnik on Wednesday October 15, 2014 @09:36PM (#8462844)
We talked about it at the last work week a lot https://github.com/rust-lang/meeting-minutes/blob/master/wor...
Re:Rustful – A RESTful web framework for Rust by rubiquity on Wednesday October 15, 2014 @05:03PM (#8461725)
I only play with Rust because I'm a language junky, but I don't think Rust has been built so far with the intentions of being a great language for servers. It feels like a language targeted towards system engineering, which is a bit different than network engineering (which is where I would put web servers).

That said, with a 1:1 threading model, you can still build good abstractions for asynchronous I/O onto those threads. Erlang is kind of like this in that it spawns as many threads as you have cores (unless you tell it otherwise) and uses a thread for async I/O via epoll/kqueue.