Live data from Hacker News

Costs of running a Python webapp for 55k monthly users

keepthescore.co

251–260 of 264 posts

Re: Costs of running a Python webapp for 55k monthly users

#251

Earlier quoted context omitted.

> Amtrak is owned by the US government. Irrelevant. The actual railroads are private, and Amtrak gets shafted. Look at the state of US passenger railways, and compare them to trains in France or Spain. All countries with successful passenger rail have them public. You will find find same pattern for all examples given.

So your only example of the ills of privatization, is a company that wasn’t ever really privatized?

I can't help you if you intentionally misconstrue everything I write.

If you wish to continue believing that privatisation can never have negative results, please do. But even a casual reading of history or economics will demonstrate that's wrong.

Re: Costs of running a Python webapp for 55k monthly users

#252
post #250

Earlier quoted context omitted.

This is only true, if you do not value your free time. In your example, you've spent 4h to save 200$, so your work was worth 50$/hour. A freelancer with a 100$/hour rate might do 2 hours of work instead, spend the money, and gain 2 hours of free time. There are other factors of course, but in general, many people come up with a rate for their own free time (which is often higher than the actual rate they charge clien…

It’s not only true if you don’t your free time. It’s only true if you’re a freelancer that is turning down hours at a higher rate than what you’re saving. Many people working on products, both on their own and within a company, aren’t turning down other profitable work to optimize existing solutions. If I watch a two hour movie instead of spending two hours saving $100/month, it doesn’t matter how much I value my tim…

There's a difference between the initial example and watching a movie. That's what I summed up with "there are other factors (than money)". If I'm only interested in the _outcome_ and I treat the way to achieve it as work, I definitely weight the time cost vs benefit (and I am not a freelancer). If it is something I enjoy doing (which may or may not be true for the initial example), I'll take this into account as well. Time is a limited resource, and I treat it as such.

Re: Costs of running a Python webapp for 55k monthly users

#253
post #185
post #172

Earlier quoted context omitted.

What's blocking is number of http connections between browser and server. Most browsers only allow 6, each tile takes about 100ms so getting 10 in under second doesn't always happen.

Do you know if the old open street map trick of having multiple tile servers (that are each just aliases of the same server) still works? I think this was how they tried circumventing the 6 connection limit

That's no longer necessary thanks to HTTP/2

Your webserver still has to spin off a thread for each request if you want to do substantial CPU work for each request, but rest assured you'll get all the requests at once from the browser. Not 6 at a time like in the dark ages

The RFC recommends at least 100 streams. See SETTINGS_MAX_CONCURRENT_STREAMS https://tools.ietf.org/html/rfc7540#section-6.5.2

Re: Costs of running a Python webapp for 55k monthly users

#254

Earlier quoted context omitted.

So your only example of the ills of privatization, is a company that wasn’t ever really privatized?

I can't help you if you intentionally misconstrue everything I write. If you wish to continue believing that privatisation can never have negative results, please do. But even a casual reading of history or economics will demonstrate that's wrong.

I’ve done far more than a casual reading of economics, and since you can’t provide a single example of the ills of privatization I suspect your reading barely reached casual levels.

Re: Costs of running a Python webapp for 55k monthly users

#255

Earlier quoted context omitted.

I can't help you if you intentionally misconstrue everything I write. If you wish to continue believing that privatisation can never have negative results, please do. But even a casual reading of history or economics will demonstrate that's wrong.

I’ve done far more than a casual reading of economics, and since you can’t provide a single example of the ills of privatization I suspect your reading barely reached casual levels.

If you are going to taunt me, put in some effort and bring something to the table. Present your point of view and contribute to the conversation instead of just criticising and nitpicking.

You are just asking me to google things for you.

With your great knowledge of economics I am sure you can summarise the history of privatisation far better than I ever could, so please share your wisdom with us.

Re: Costs of running a Python webapp for 55k monthly users

#256

Earlier quoted context omitted.

I’ve done far more than a casual reading of economics, and since you can’t provide a single example of the ills of privatization I suspect your reading barely reached casual levels.

If you are going to taunt me, put in some effort and bring something to the table. Present your point of view and contribute to the conversation instead of just criticising and nitpicking. You are just asking me to google things for you. With your great knowledge of economics I am sure you can summarise the history of privatisation far better than I ever could, so please share your wisdom with us.

You made your claims, I clearly debunked them. I decline to spend my time to continue your free education any further, unless you put the effort in.

Re: Costs of running a Python webapp for 55k monthly users

#257

Earlier quoted context omitted.

If you are going to taunt me, put in some effort and bring something to the table. Present your point of view and contribute to the conversation instead of just criticising and nitpicking. You are just asking me to google things for you. With your great knowledge of economics I am sure you can summarise the history of privatisation far better than I ever could, so please share your wisdom with us.

You made your claims, I clearly debunked them. I decline to spend my time to continue your free education any further, unless you put the effort in.

You demonstrate hypocrisy and blatant disrespect for your interlocutor.

Your 'debubking' is low-effort critisism. You've contributed nothing factual or informative. You don't even bother making claims, or aswering any of my direct questions.

Re: Costs of running a Python webapp for 55k monthly users

#258

Earlier quoted context omitted.

You made your claims, I clearly debunked them. I decline to spend my time to continue your free education any further, unless you put the effort in.

You demonstrate hypocrisy and blatant disrespect for your interlocutor. Your 'debubking' is low-effort critisism. You've contributed nothing factual or informative. You don't even bother making claims, or aswering any of my direct questions.

You claimed Amtrak is an example of the ills of privatization, when it’s owned by the federal government. And attributed the effects of strong government regulation in the healthcare and broadband markets to “privatization”.

My criticism is only low effort because you know so little of the subject that your world view is built on obvious misinformation.

Re: Costs of running a Python webapp for 55k monthly users

#259

Earlier quoted context omitted.

You demonstrate hypocrisy and blatant disrespect for your interlocutor. Your 'debubking' is low-effort critisism. You've contributed nothing factual or informative. You don't even bother making claims, or aswering any of my direct questions.

You claimed Amtrak is an example of the ills of privatization, when it’s owned by the federal government. And attributed the effects of strong government regulation in the healthcare and broadband markets to “privatization”. My criticism is only low effort because you know so little of the subject that your world view is built on obvious misinformation.

Your critisism is so low effort you don't even bother reading - I never mentioned Amtrak. You did not bother to mention structural differences between railway networks in France and Uk, to give any example of succesfull private passenger rail, to deal with my claim that all sucessfull mass transit is public, to comment on the fact that Uk privatised national rail but they went bancrupt and the public had to pick up the tab. That despite their 'private' nature we still provide subsidies and build infrastructure.

Maybe you should be spend less time judging worldview of others and more contributing something of value to the discussion.

Re: Costs of running a Python webapp for 55k monthly users

#260

Earlier quoted context omitted.

We use Google cloud run for this. They bill per request and you can run whatever docker container you want. I currently have a small setup with two separate kotlin based server applications running there (one based on spring boot and one on ktor). We use firestore as a cheap datbase (billed per read & write). Both have a free tier. So it's costing us next to nothing currently because neither docker container is getti…

how does the kotlin server perform on cloud run? is the startup time slow? does spring take a lot of memeory etc?

I bumped the memory limit from 256MB to 1GB. 2GB is the maximum on cloudrun. You pay a combination of CPU/Memory per request obviously. Beyond that, it scales by firing up more containers as your request load increases to a default maximum of 1000 (we set it at 2).

Obviously don't use this if you have a lot of cpu/memory requirements but otherwise this should be fine for a well crafted stateless server.

Startup is fine with both ktor and spring-boot but obviously takes a bit of time. I noticed there's startup overhead if your container gets shut down because there is no traffic. In that case, it takes around 30 seconds for the first request to go through. That includes everything from booting the container and then starting the process. I imagine simply pinging the server regularly should keep it running. Alternatively, you can configure a minimum amount of servers.

Post reply on HN