3 ms·
It's written in Go. Another key bit of infrastructure moves to a safer language. "This is not the end. It is not even the beginning of the end. But it is, per
by Animats 11y ago
It's written in Go.
Another key bit of infrastructure moves to a safer language.
"This is not the end. It is not even the beginning of the end. But it is, perhaps, the end of the beginning."
- deleted 11y ago[deleted]
- pron 11y agoIn this project -- as in Docker and rkt -- Go serves as little more than a glue language, replacing the role of Python (in fact, it could have possibly been written in bash) -- not C. The core functionality is part of the kernel and is written in C (or C++ in the case of Windows, I believe).
- AaronFriel 11y agoYou might be overstating the "safer language" aspect. As another commenter suggests, they are using Go as little more than glue to the C or C++ kernel and libraries that run the important bits. And these searches should instill a bit of fear in your heart when running Docker: https://github.com/docker/docker/search?utf8=%E2%9C%93&q=unsafe https://github.com/docker/docker/search?utf8=%E2%9C%93&q=uns... https://github.com/docker/docker/search?type=Code&utf8=%E2%9C%93&q=pointer https://github.com/docker/docker/search?type=Code&utf8=%E2%9... Docker has such prodigious and repeated use of "unsafe" that it makes one wonder what, if anything, using Go has bought them in terms of safety or reliability? It seems like virtually every interface used in the Docker source code relies on unsafe casts to pointers, and I hesitate to say I am not sure how well the Go garbage collector meshes with casting pointers and providing them to the kernel and other libraries. Something like Rust's native ability to ensure a pointer provided to external code lives long enough would be very useful.
- zeckalpha 11y agoOnly incrementally safer.