Earlier quoted context omitted.
These are not really an issue in vfx production and other things Python is used for.
It’s a problem for lots of things Python is used for, but maybe not vfx (whatever that is).
Python at Netflix
221–230 of 250 posts
Re: Python at Netflix
#222Interesting. I had it in my head that Netflix was a pure Java shop. Was I wrong in the first place, or has something changed?
Re: Python at Netflix
#223Re: Python at Netflix
#224Interesting. I had it in my head that Netflix was a pure Java shop. Was I wrong in the first place, or has something changed?
Re: Python at Netflix
#225> The ability to drop into a bpython shell and improvise has saved the day more than once. what do you really do here - connect to the flask instance and route requests manually ?
Re: Python at Netflix
#226Re: Python at Netflix
#227Earlier quoted context omitted.
> I fail to understand the use of python in a distributed environment while the language has such poor concurrency support Because it's a distributed environment probably is exactly why. Python has (arguably) great concurrency support apart from Multi-threading. https://www.youtube.com/watch?v=MCs5OvhV9S4 So if you need concurrency in the context of a single thread, then Python's GIL is a non-starter. But a distribut…
Even if your app is IO bound, Python's concurrency is painful. Because it's not statically typed, it's too easy to forget an `await` (causing your program to get a Promise[Foo] when you meant to get a Foo) or to overburden your event loop and such things are difficult to debug (we've had several production outages because of these class of bugs). Never mind the papercuts that come about from dealing with the sync/asy…
Re: Python at Netflix
#228Earlier quoted context omitted.
You think you're being downvoted because people like dynamic typing very much. You're being downvoted because: A) You left a comment with a strong opinion without expressing it while dismissing other peoples' experience B) Python is in fact a type safe language for a while now https://docs.python.org/3/library/typing.html - you have pluggable "a la bracha" types.
> Python is in fact a type safe language for a while now I like the idea of type annotators but they do not make it a type safe language because types are not checked and they are more like comments. Python will remain a dynamically typed language, and the authors have no desire to ever make type hints mandatory, even by convention. [1] [1]: https://www.python.org/dev/peps/pep-0484/#non-goals
Not that i like it but just to show that a lot of languages require a properly set up configuration and CI-infrastructure to make them safe and useful. mypy should be considered equal to -Wall -Werror and anyone who doesn't run it is frankly a bloody idiot.
Re: Python at Netflix
#229> The ability to drop into a bpython shell and improvise has saved the day more than once. what do you really do here - connect to the flask instance and route requests manually ?
Our python code does not handle user requests directly. Our team uses python to control the control plane of traffic — we flip dns records, control cross-region proxying, re-steer cdn-based reverse proxying and scaling of the hundreds of micro services that power the Netflix experience. We’ve improvised various custom traffic distribution patterns, operated outside of our normal traffic-shifting workflows, and writte…
I would love to setup an architecture like this that lets me connect to stuff through a CLI. Also, I'm assuming you are on kubernetes (or something). How does this bpython business work through all those layers ?
Re: Python at Netflix
#230Earlier quoted context omitted.
> I fail to understand the use of python in a distributed environment while the language has such poor concurrency support (on top of the lack of a type system). You can make your application HA, but they are obviously not trying to squeeze out every CPU cycle. You're conflating several things that are orthogonal imo. A system can be distributed without concurrency. A concurrent system need not be distributed. Either…
> A system can be distributed without concurrency. A concurrent system need not be distributed. The only justification for such design I can think of is HA. I.e. you have very light workload that does not saturate a single machine, but nonetheless you create a distributed system with two machines for HA. Such light workload is probably not often the case at Netflix.
I'm not trying to justify any particular design. I'm just saying that concurrency and distributed processing are different things. And I'm no expert, but I continue to be confused as to what saturation, whether of cpu or i/o - you don't specify - has to do with concurrency? If I have for example n http servers all running one thread and handling enough traffic that they are all at 100 percent CPU that is by some minimal definition a distributed system, but none of the processes in it are concurrent. If the http servers read and write a database then the database is almost certainly concurrent, so then you have a distributed system that has both concurrent and non-concurrent processes collaborating.