Live data from Hacker News

Backend of Meta Threads is built with Python 3.10

twitter.com

101–110 of 458 posts

Re: Backend of Meta Threads is built with Python 3.10

#101

No tweaks mentioned at all inside. The title is wrong. Kinda weird to start a new project that needs to scale with Python though (I use Python most of the time).

As far as I can tell from my prior experience of working at Insta is that all the work is done by various services written in C++/hack. Python/Cinder would be just interface layer routing the incoming request/response from/to client.

Re: Backend of Meta Threads is built with Python 3.10

#102
post #96
post #55

Really, all the performance intensive parts are in various c++ aggregator and recommendation type services. But the webserver is Django, yes.

Interesting and lovely to hear they decided to use Django. What is your source, though?

Instagram devs have given a lot talks about python and django at conferences. As far as I know IG is still running on django so it makes sense that the dev team would stick with it for something new.

Re: Backend of Meta Threads is built with Python 3.10

#103
post #96

Earlier quoted context omitted.

Interesting and lovely to hear they decided to use Django. What is your source, though?

How is Django now? I’m a long time python dev (data eng space) but new-ish to web dev. I started a Flask project 2 years ago and found it to be pretty full of footguns, mixed messaging on best practices for scalable apps, and the ecosystem feels overbloated with vapor ware extensions. Is this just a Flask problem, or does Django have the same issues?

Django is fantastic. It's much bigger than flask, and has one of the best ORMs I've ever used. Also comes with a built in admin panel which is always nice. You will want to use Django REST Framework to make REST APIs, but if getting a site up and running is all you want, it's perfect.

If you want to purely make APIs though, give FastAPI a try.

Re: Backend of Meta Threads is built with Python 3.10

#105
post #58
post #11

Earlier quoted context omitted.

Yet here it is ... powering a global scale app. Too weak for someones hobby project, strong enough for global scale.

Off-topic: it is not yet [global scale] because it is only available in US. Here in EU, I still get “not available in your country”.

it is not yet [global scale] because it is only available in US. Here in EU, I still get “not available in your country”.

It's not only available in the U.S. It's available in 100 countries. There's more to "global" than the E.U.

Re: Backend of Meta Threads is built with Python 3.10

#106
post #54

Earlier quoted context omitted.

A fair point that it's stupid to implement a mostly plain text publishing site that doesn't support linking to any of the text published there. Edit: Someone kindly pointed out that you can see the content in the browser without an account from following a direct link. (You just can't have the app installed or it will open that and drop you on the login page.) This makes me a lot happier with the product!

You can link to it, what are you talking about? An example fetched from a verge article -> https://www.threads.net/t/CuVaOg1PgU4/

This is the first time I'm seeing this. I'm surprised they have a .net domain and that the design is so terrible.

They just extracted Instagram comments and threw them in a sea of whitespace. No thought is given to anchoring content by importance or context, nor is there any esthetic apeal to it.

Re: Backend of Meta Threads is built with Python 3.10

#107
post #60
post #55

Really, all the performance intensive parts are in various c++ aggregator and recommendation type services. But the webserver is Django, yes.

Thanks for your comment. I'm really interested in this topic. How do you know the web server is Django? I searched but couldn't find this. Why would they use Django? I did some small projects in it but I assumed it wasn't very fast and wouldn't be suitable for a big app like this. I would like to know the pros and cons. Why didn't they build up something in C++ or Rust? Won't python limit the speed of responses despi…

Whether it's in C++ or Rust or Python, almost all of any slowness would be from database waiting anyway.

Re: Backend of Meta Threads is built with Python 3.10

#108

Python is just the web server. All the truly performance-sensitive components--edge proxy, load balancers, backend services, databases, caches, and storage services--are mostly C++.

I would argue a web server which processes all (or most) requests is a performance sensitive part of the system. Straightforward rewriting from Python to Go in many cases gives at least 2x-3x performance improvement which on FAANG scale can mean huge difference in hardware cost.

Re: Backend of Meta Threads is built with Python 3.10

#109
post #96
post #55

Really, all the performance intensive parts are in various c++ aggregator and recommendation type services. But the webserver is Django, yes.

Interesting and lovely to hear they decided to use Django. What is your source, though?

It's a heavily modified internal fork of Django. Source: I work on our Python Language Foundation team.
Post reply on HN