Hristo
Hristo

Reputation: 780

Is it possible to write node.js addons in go?

I guess it's all about whether libuv and the other c/cpp glue can be somehow imitated from within a go executable. Is it possible? If yes, could you provide some guidance on where to start?

Thanks!

Upvotes: 0

Views: 359

Answers (1)

thwd
thwd

Reputation: 24848

At the moment it is not possible (read very complicated) to build shared objects with Go, as to dynamically link them into a system. It's for this same reason that Go can only interface with other web servers through CGI or Fast-CGI.

So my answer would be not directly. maybe you could achieve something through IPC and a small C-"proxy" that's linked into node.

Upvotes: 1

Related Questions