[swift-server-dev] Prototype of the discussed HTTP API Spec
paulo at zewo.io
Tue May 30 11:44:18 CDT 2017
Yeah, it's important to distinguish:
They're all separate concepts that might go together sometimes. Johannes
point was about lack of support for cooperative scheduling in Swift, but he
presented it as a sync API issue.
On Tue, May 30, 2017, 13:39 Michael Chiu <hatsuneyuji at icloud.com> wrote:
> I don't quite see why we need (or should even offer) a synchronous API for
> anything that involves IO (disk, network, ...). Sure, many of us would like
> to have a synchronous and non-blocking programming model, that'd be great.
> Today in Swift unfortunately we can only go asynchronous&non-blocking or
> synchronous&blocking (causing undefined behaviour  with setjmp/longjmp
> to get synchronous&non-blocking is cool but certainly not supported today).
> I’m a bit confused here, synchronous&non-blocking can be done by
> kqueue/epoll/select/poll in swift.
> It is true that kqueue and epoll are some low level C API but not having
> synchronous API basically screwed everyone who prefer to do their own
> scheduling for whatever reason.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the swift-server-dev