Live data from Hacker News

Where's the fastest place to put my server? How much does it matter?

calpaterson.com

41–50 of 124 posts

Re: Where's the fastest place to put my server? How much does it matter?

#42
post #35
post #8

Shameless plug: https://fly.io We built Fly _specifically_ so you can run servers close to your users. We do a lot for you on the network side, too, like terminate TLS in all our regions. One thing to note, though, is that latencies between cities are surprisingly different than their theoretical max. We have apps on Fly with lots of South American users. It's frequently faster for people in Argentina to connect to M…

The applications I work on do several database calls for single user HTTP request. Shouldn't the application server be as close as possible to the database, rather than to the user? I struggle to think of an example where your model is useful, unless your application has no database.

App servers should have a fast access to data! Which either means running caches alongside the app servers, or doing clever things with databases.

We just released a preview Postgres + regional replicas. This setup keeps the postgres leader in one region and lets people add replicas in other regions they're interested in. It works really well for typical full stack apps.

We've also found a surprising number of customers who want to run in only one specific region. They don't spread apps out geographically, they just have a concentrated population of users in, say, Sydney. We're increasingly becoming "Heroku for ".

Re: Where's the fastest place to put my server? How much does it matter?

#43
post #12

Many years ago (2006 and 2009, respectively) I had to choose European and Asian locations for rsync.net storage arrays. My primary, overriding criteria in choosing locations was what would be the coolest, most interesting place to visit for installs and maintenance . I chose Zurich and Hong Kong. Measured results have exceeded my initial models.

I’ve nothing against Switzerland (it’s nice) but you’re the first person I’ve ever come across to suggest Zurich (or anywhere in Switzerland) as the coolest and most interesting place in Europe!

I’m genuinely interested to hear more.

Re: Where's the fastest place to put my server? How much does it matter?

#44
post #35
post #8

Shameless plug: https://fly.io We built Fly _specifically_ so you can run servers close to your users. We do a lot for you on the network side, too, like terminate TLS in all our regions. One thing to note, though, is that latencies between cities are surprisingly different than their theoretical max. We have apps on Fly with lots of South American users. It's frequently faster for people in Argentina to connect to M…

The applications I work on do several database calls for single user HTTP request. Shouldn't the application server be as close as possible to the database, rather than to the user? I struggle to think of an example where your model is useful, unless your application has no database.

If it‘s feasable to shard data by user, you could put it in a close shard, most users don‘t move continents that much. I have never done this but as a latency nut I would like to try it sometime. Seems like Cloudflare‘s Persistent Objects kind of promises to do this automatically.

Then there are a lot of requests you can serve from read replicas or caches that can be close.

Re: Where's the fastest place to put my server? How much does it matter?

#45
post #17

Earlier quoted context omitted.

The edge is getting to be really important for high quality interactions, but there are some caveats. In systems in which there is common shared state between all participants (e.g. Fortnite), you fundamentally must have a form of centralized authority somewhere. In these cases, you do not gain very much by pushing things to the edge if most interactions require taking a round trip through the business state machine.…

> In systems in which there is common shared state between all participants (e.g. Fortnite), you fundamentally must have a form of centralized authority somewhere. I wonder if there's any big online game already which does match making preferring local servers. And I don't mean local as in "people registered in us-east region", but rather "there are 4 people ready to play in Chicago, spawn an instance there and conne…

I am almost certain this already a metric used by matchmaking in certain FPS games like Overwatch.

Re: Where's the fastest place to put my server? How much does it matter?

#46
post #44
post #35

Earlier quoted context omitted.

The applications I work on do several database calls for single user HTTP request. Shouldn't the application server be as close as possible to the database, rather than to the user? I struggle to think of an example where your model is useful, unless your application has no database.

If it‘s feasable to shard data by user, you could put it in a close shard, most users don‘t move continents that much. I have never done this but as a latency nut I would like to try it sometime. Seems like Cloudflare‘s Persistent Objects kind of promises to do this automatically. Then there are a lot of requests you can serve from read replicas or caches that can be close.

Cockroach has a neat and almost transparent way of doing this. If you key your tables by customer, it'll happily move those chunks of data to the nodes that need them most often.

We almost shipped cockroach but it's missing some Postgres features that most full stack frameworks rely on.

Re: Where's the fastest place to put my server? How much does it matter?

#47
post #31

I make MMOs, and there are only two "large" cloud providers that have machines in central US: Google and IONOS.

Azure has two central US locations: one in Iowa and one in Texas. They are probably larger than GCP and IONOS put together.

Re: Where's the fastest place to put my server? How much does it matter?

#48
post #35
post #8

Shameless plug: https://fly.io We built Fly _specifically_ so you can run servers close to your users. We do a lot for you on the network side, too, like terminate TLS in all our regions. One thing to note, though, is that latencies between cities are surprisingly different than their theoretical max. We have apps on Fly with lots of South American users. It's frequently faster for people in Argentina to connect to M…

The applications I work on do several database calls for single user HTTP request. Shouldn't the application server be as close as possible to the database, rather than to the user? I struggle to think of an example where your model is useful, unless your application has no database.

It can work as a "smart cache" - like for example:

https://fly.io/docs/app-guides/graphql-edge-caching-apollo/

I'm not entirely convinced this is a great idea (and apparently the example uses plain http between the graphql prox/cache and openlibrary.org - that might be considered a bug, I suppose: https://github.com/fly-apps/edge-apollo-cache/blob/master/sr... At any rate I'd assume whatever source you're proxying (eg your own openapi rest end points) - you might want ssl - or connect the db/api to fly.io via vpn a la: https://fly.io/blog/building-clusters-with-serf/ See also the linked: https://fly.io/blog/incoming-6pn-private-networks/ ).

Re: Where's the fastest place to put my server? How much does it matter?

#49
post #45

Earlier quoted context omitted.

> In systems in which there is common shared state between all participants (e.g. Fortnite), you fundamentally must have a form of centralized authority somewhere. I wonder if there's any big online game already which does match making preferring local servers. And I don't mean local as in "people registered in us-east region", but rather "there are 4 people ready to play in Chicago, spawn an instance there and conne…

I am almost certain this already a metric used by matchmaking in certain FPS games like Overwatch.

Ditto CS:GO, when I was playing with a friend in Sweden (vs Australia), we’d all have to increase our max allowed ping to the server, or the game would never find us a party.

Re: Where's the fastest place to put my server? How much does it matter?

#50
post #12

Many years ago (2006 and 2009, respectively) I had to choose European and Asian locations for rsync.net storage arrays. My primary, overriding criteria in choosing locations was what would be the coolest, most interesting place to visit for installs and maintenance . I chose Zurich and Hong Kong. Measured results have exceeded my initial models.

This might set the record as the Pinboard-iest post that didn't actually come from Pinboard.
Post reply on HN