Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Writing a sample server app - is forkIO unavoidable?

I haven't done anything networkish in haskell, so I'm giving that a try now. I'm using Oleg's ZFS as a template how to do that.

IIRC he wasn't using threads but was using "delimited continuations" instead so I wonder if a heavier load server app could principally also be written without using forkIO threads.

Günther

like image 951
Günther Avatar asked Jun 07 '10 15:06

Günther


1 Answers

This is really a research question. Oleg's zipperFS didn't use any of Haskell's fine concurrency mechanisms under the hood, so it wouldn't scale to many concurrent users, I'm quite certain.

I'm intrigued that you can write a web server using a zipper. Publish!

But why not just write a regular server using massive concurrency in the classic style -- one forkIO per accept?

like image 187
Don Stewart Avatar answered Sep 29 '22 21:09

Don Stewart