4 ms·
So, as far as I can tell, you have failed to demonstrate that Twisted Web with PyPy is not a viable alternative, which is disappointing. Also, uWSGI's core tea
by MostAwesomeDude 13y ago
So, as far as I can tell, you have failed to demonstrate that Twisted Web with PyPy is not a viable alternative, which is disappointing.
Also, uWSGI's core team doesn't have any faith in their own code; they use Apache instead of dogfooding. (And they're moving all hosting and development to sites like Github.) Twisted, at least, is confident enough in the quality of their code to self-host.
- zeeg 13y agoPyPy uses too much memory and isnt that much faster for many things. (Sorry PyPy guys!) I dont have numbers/charts to pull up for this right now, but I was testing it out to see if I could push more cpu on a server, and the memory cost was insane for the minimal test case. Twisted also is not a web server, it's a framework. Same with Tornado, and honestly, the same with gevent/etc.
- MostAwesomeDude 13y ago$ twistd -n web --wsgi your.wsgi.app You have been misinformed.
- sillysaurus 13y agoHow much memory usage is "insane"? Are you sure the memory cost grows with the size of the application? It sounds like you tested a minimal test case, saw high memory usage, then didn't bother to test a large application. Maybe the memory usage is constant.
- zeeg 13y agoI saw 5x memory usage, which was already something I was trying to optimize. There's a ticket I opened on the PyPy tracker, but this is sort of expected if I understand JITs correctly. I didn't exhaustively benchmark it, but the initial results were too far outside the bounds of my limitations.
- sillysaurus 13y ago5x memory usage of what? You're not giving actual numbers, nor the benchmark you used.
- coldtea 13y ago>5x memory usage of what? Of what he was seeing without PyPy. He doesn't want advice on how to lower that. He wants to get the same memory usage or better out of the box.
- deleted 13y ago[deleted]
- zeeg 13y agoNo I wanted reasonable tradeoffs. e.g. 20% faster execution for 100% more memory In my case it was 15% faster execution (give or take), with a 400% memory increase. This was on a simple view which did nothing, so it's hard to tell how it'd handle more complex views in the app. Either way this is a huge detour from what this actual topic is about, whether you use PyPy or CPython
- deleted 13y ago[deleted]
- zeeg 13y agoI have absolutely no idea how HN replies work, but this is in response to the PyPy memory usage. I'm optimizing for my application. If you want to use PyPy, use it. I couldn't care less. If I was having a hard time already maxing CPU due to memory constraints, how does switching to something that will use a very large amount of memory (relative to the CPU gains) make any sense at all? Do you really think "more complex code" is going to use less memory? If you want benchmarks, go find some, or go create some. It has absolutely nothing to do with the gains I'm pointing out by simple webserver choices and minor tuning.
- corford 13y agoI'm pretty sure Roberto De Ioris (the creator of uwsgi and lead dev) has complete faith in his code (as he should do because it's awesome). unbit.it (an Italian hosting company) employ him full time to work on uwsgi and they use it extensively throughout their production infrastructure.
- HNLogInShit 13y ago"dogfooding". Uh-huh.
- rdeioris 13y agoWe use Apache as a frontend because we are an hosting company and customers want .htaccess (sad but true). But behind Apache frontend (read: frontend) there is ALWAYS uWSGI (even for php). Unbit.it uses uWSGI for everything (even for load balancing MX servers ;) and i am proud we are the first (only...) company giving php hosting on uWSGI by default. Finally, we moved to github because customers/contributors wanted it, i was perfectly fine with self-hosted mercurial, but customers are more important than my taste :)