D and microservices
Russel Winder via Digitalmars-d
digitalmars-d at puremagic.com
Wed Oct 7 03:47:43 PDT 2015
On Wed, 2015-10-07 at 07:15 +0000, extrawurst via Digitalmars-d wrote:
> […]
>
> I have never used Go, but isn't what you describe exactly what
> vibe.d is doing using Fibers ?
As I understand it, vibe.d is a single threaded event-loop with fibres.
In this sense it is equivalent in architecture to Node except that
vibe.d allows for blocking fibres where Node required non-blocking
approaches. Thus I would choose vibe.d over Node any day, except…
Go has a task pool (goroutines), but underneath is a thread pool not a
single thread. This means that multiple goroutines can be executing
concurrently, that means in parallel (*). GPars has an approach similar
to Go. Go is way more efficient though as it uses the kernel threads
directly, GPars has to fight with the JVM threads.
(*) It is a pity that computing and the rest of the world have
different meaning for concurrent and parallel, it leads to lots of
wonderful confusion.
--
Russel.
=============================================================================
Dr Russel Winder t: +44 20 7585 2200 voip: sip:russel.winder at ekiga.net
41 Buckmaster Road m: +44 7770 465 077 xmpp: russel at winder.org.uk
London SW11 1EN, UK w: www.russel.org.uk skype: russel_winder
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: This is a digitally signed message part
URL: <http://lists.puremagic.com/pipermail/digitalmars-d/attachments/20151007/8e3edeb9/attachment.sig>
More information about the Digitalmars-d
mailing list