Programming languages endorsed for server-side use at Meta

This page summarizes the projects mentioned and recommended in the original post on news.ycombinator.com

Our great sponsors
  • Scout APM - Truly a developer’s best friend
  • SonarQube - Static code analysis for 29 languages.
  • talent.io - Download talent.io’s Tech Salary Report
  • InfluxDB - Build time-series-based applications quickly and at scale.
  • cxx

    Safe interop between Rust and C++

    > Specifically, it lacks one fundamental thing: why.

    No, it's there. I can explain.

    They clearly mention that adding support for a new language is considerable effort - the language needs support for core libraries, security and privacy, developer experience etc. They also mention that a long tail of languages are "community supported", meaning the teams that use them support their own use cases.

    Let's look at it from the perspective of an infra team - let's say the ones maintaining the privacy aware database abstraction. That team has limited bandwidth so they can't support every language. They start with Hack support, because that's the biggest language. Then they add C++ support and build Python support "for free" on top of the C++ code. That's it, they've done their job.

    Now if a developer team wants access to the database, they're on their own. They need to come up with APIs to access these core abstractions. They implement it on their own, or they try to wrap the existing C++ libraries.

    This is the core philosophy - every team has the freedom to make their tech choices. Maybe in some cases the tech is compelling enough (like Haskell for a rule engine) that it's worth the investment to build those bindings. In other cases (like Go for networking tools), they might not need the bindings at all. But the important thing is that tech choices happen bottom up and not top down.

    Which also explains why Rust is now supported at Meta. Rust has a couple of advantages. Like Python, Rust can access C++ libraries with the appropriate bindings (https://cxx.rs). This reduced the friction for teams around the company to adopt Rust - the libraries they needed were mostly supported.

    This organic adoption led to leadership eventually considering if it made sense to make it "officially supported", meaning the burden of maintenance of Rust support would now by on each individual infra team. Clearly, they felt that Rust provided something that the other 3 languages didn't. That explains their decision.

    I hope that answered your question. The article isn't worthless. I would not criticise so harshly if I were you.

  • cinder

    Cinder is Meta's internal performance-oriented production version of CPython. (by facebookincubator)

    Instagram is a huge Django app and unlike all the ML libraries, Django isn't highly optimized low-level code wrapped in Python, at least not by default. That's why Facebook are putting so much work into running a more performant fork of CPython - https://github.com/facebookincubator/cinder

  • Scout APM

    Truly a developer’s best friend. Scout APM is great for developers who want to find and fix performance issues in their applications. With Scout, we'll take care of the bugs so you can focus on building great things 🚀.

  • duckling

    Language, engine, and tooling for expressing, testing, and evaluating composable language rules on input strings.

    It also powers the backend of Wit.ai which FB owns. Wit's open-source entity parser, duckling, is written entirely in Haskell. https://github.com/facebook/duckling

  • autocxx

    Tool for safe ergonomic Rust/C++ interop driven from existing C++ headers

    The areas you mentioned (CLI, web services, low level systems programming) are not mutually exclusive. Doing a good job on one doesn't mean something else is affected.

    The folks who worked on the most popular command line argument parser (https://docs.rs/clap/latest/clap/#example) made a positive contribution that didn't detract from any other use case.

    Similarly, the folks working on improving Rust for web services will also make it better for systems programming. In a blog post published today (https://blog.rust-lang.org/inside-rust/2022/07/27/keyword-ge...), they discuss keyword generics, a feature that will be equally helpful for `async` code and `const` functions evaluated at compile time.

    There is already some interoperability with C++ (http://cxx.rs) and ongoing research into automating this interoperability (https://github.com/google/autocxx, https://github.com/google/crubit). Feels like there's enough effort

  • crubit

    The areas you mentioned (CLI, web services, low level systems programming) are not mutually exclusive. Doing a good job on one doesn't mean something else is affected.

    The folks who worked on the most popular command line argument parser (https://docs.rs/clap/latest/clap/#example) made a positive contribution that didn't detract from any other use case.

    Similarly, the folks working on improving Rust for web services will also make it better for systems programming. In a blog post published today (https://blog.rust-lang.org/inside-rust/2022/07/27/keyword-ge...), they discuss keyword generics, a feature that will be equally helpful for `async` code and `const` functions evaluated at compile time.

    There is already some interoperability with C++ (http://cxx.rs) and ongoing research into automating this interoperability (https://github.com/google/autocxx, https://github.com/google/crubit). Feels like there's enough effort

  • windows-rs

    Rust for Windows

    You can have a look at its issues,

    https://github.com/microsoft/windows-rs

    Note the lack of of safe wrappers for Windows APIs, and still no good way to create the Windows Runtime objects necessary to interoperate with XAML.

    Also a note the basic examples with very little UI code on what is supposed to be a projection for a Windows UI framework.

  • httm

    Interactive, file-level Time Machine-like tool for ZFS/btrfs

    > I’m no expert but always saw Go as the better choice for CLI tooling where performance is important

    I'm no expert in golang, so golang may in fact be better(?) by some metric of better, but as the author of a Rust CLI tool[0], I will say that Rust is pretty fantastic at this use case, and it seems like a sweet spot to me.

    [0]: https://github.com/kimono-koans/httm

  • SonarQube

    Static code analysis for 29 languages.. Your projects are multi-language. So is SonarQube analysis. Find Bugs, Vulnerabilities, Security Hotspots, and Code Smells so you can release quality code every time. Get started analyzing your projects today for free.

  • slint

    Slint is a toolkit to efficiently develop fluid graphical user interfaces for any display: embedded devices and desktop applications. We support multiple programming languages, such as Rust, C++ or JavaScript.

    Well, there is Slint in that case, from former Qt devs, but it is still pretty much early days.

    https://slint-ui.com/

  • drogon

    Drogon: A C++14/17/20 based HTTP web application framework running on Linux/macOS/Unix/Windows

    > How would one go about building a rest service in C++?

    I'd use https://github.com/drogonframework/drogon if the app needs to be pure C++ or Cutelyst (https://cutelyst.org/) if it's a Qt app which needs to expose an http server

  • Cutelyst

    A C++ Web Framework built on top of Qt, using the simple approach of Catalyst (Perl) framework.

    > How would one go about building a rest service in C++?

    I'd use https://github.com/drogonframework/drogon if the app needs to be pure C++ or Cutelyst (https://cutelyst.org/) if it's a Qt app which needs to expose an http server

  • mirage

    MirageOS is a library operating system that constructs unikernels

    OCaml has Mirage (https://mirage.io) for example, and ReasonML is just another syntax for the language.

  • vectorflow

    >> Mozilla (of course)

    Mozilla is a c++ and javascript shop. What do they ship in Rust? How much of Firefox is written in rust for example?

    >> Microsoft, Meta, Google/Acrobat, Amazon

    Large firms have lots of devs and consequently lots of toy projects. Is their usage of rust more significant than their use of D? I mean Meta was churning out projects in D a while back (warp, flint, etc) and looked like it might be going all in at one point (they even hired one of the leads on D lang).

    >> That's practically all of FAANG

    Who were we missing? Netflix, they’ve dabbled with D too: https://github.com/Netflix/vectorflow

    Don’t misunderstand my point - it’s not that D is more popular than rust, it’s that rust is not used for real work in any significant capacity yet.

    Where’s the big project written in rust? Servo and the rust compiler are the only two large rust projects on github.

  • ugrep

    🔍NEW ugrep v3.9: ultra fast grep with interactive TUI, fuzzy search, boolean queries, hexdumps and more: search file systems, source code, text, binary files, archives (cpio/tar/pax/zip), compressed files (gz/Z/bz2/lzma/xz/lz4/zstd), documents etc. A faster, user-friendly and compatible grep replacement.

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts