5 ms·
It's interesting that they don't break the problem apart geographically. It's inherent in Uber that you're local. But their infrastructure isn't organized that
by Animats 10y ago
It's interesting that they don't break the problem apart geographically. It's inherent in Uber that you're local. But their infrastructure isn't organized that way. Facebook originally tried to do that, then discovered that, as they grew, friends weren't local. Uber doesn't need to have one giant worldwide system.
Most of their load is presumably positional updates. Uber wants both customers and drivers to keep their app open, reporting position to Master Control. There have to be a lot more of those pings than transactions. Of course, they don't have to do much with the data, although they presumably log it and analyze it to death.
The complicated part of the system has to be matching of drivers and rides. Not much on that yet. Yet that's what has to work well to beat the competition, which is taxi dispatchers with paper maps, phones, and radios.
- asdfaoeu 10y ago> We assign cities to the geographically closest data center, but every city is backed up on a different data center in another location.
- matthewrudy 10y agoI tried to debug this from Hong Kong, and the API calls definitely go to the US. Maybe in Europe they resolve to a European data center, but in Asia they still seem to send everything via the US.
- messutied 10y agoq
- zer0gravity 10y agoYou know that saying : "I didn't have time to write a short letter so I wrote a long one". With this kind of technology stack you end up when you try to move fast. I'm sure that if more time and thought would have been put into it, it would have been more elegant and simple. But has time these days ?
- chiph 10y agoI had similar thoughts. "Wow. All those moving parts. Each one of which could fail." Each new piece of unique technology added means that it's probability of failure gets multiplied against what you already have.
- carterehsmith 10y agoAccording to the article, this is not their first take at the architecture. There are links that point to their older setups. So the current architecture is what they came up with after some time and some thought have been put into.
- daniel-levin 10y agoWell, to some extent, they do. Their geofencing [0] service takes in coordinates and returns the geofences these coordinates fall into. They make this faster by pruning irrelevant geofences: >> Instead of indexing the geofences using R-tree or the complicated S2, we chose a simpler route based on the observation that Uber’s business model is city-centric; the business rules and the geofences used to define them are typically associated with a city. This allows us to organize the geofences into a two-level hierarchy where the first level is the city geofences (geofences defining city boundaries), and the second level is the geofences within each city. [0] https://eng.uber.com/go-geofence/ https://eng.uber.com/go-geofence/
- afarrell 10y agoWhy would Uber/Lyft use be localized? I tend to use it far more when in an area where I'm unfamiliar with the local transit network.
- imaginenore 10y agoBut you are local to that unfamiliar area when you search for a ride. That's what they mean.
- genmon 10y agoUber is pretty formidable in building and growing a two-sided market. I suspect it's tuned continuously, at high resolution (in space and time), with levers I mostly don't know. And that's got to be a big contribution to the complexity of the stack. This of it this way. A standard e-commerce site, or SaaS with low-touch marketing... there are a crazy number of KPIs to monitor, loads of levers (e.g. what's the right discount to fix basket abandonment). The instrumentation to track all these conversation funnels (and to do A/B tests to see what works) is half the job. But at least we have a common understanding of the metrics and the levers -- for SaaS, say, there are tons of similar services, and the knowledge is shared in the community. Uber? How do you grow while maintaining market liquidity every evening of every week? If you artificially hike demand from passengers in a particular neighbourhood (say with coupons), does WOM amongst potential drivers work to increase the driver pool before the passengers get frustrated and move to Lyft? All of this is new. So how do you create the tech to track not just all the data you need, but all the data you might need, plus the capabilities to do tests to figure out what levers to pull? Hard. I have no particular insight into this. But my guess is that Uber isn't flying blind - their growth has been no accident - and the complexity of their tech is due to instrumentation not operations.
- matthewrudy 10y agoI work on an uber-like system, but with ~3 backend devs rather than 100s. We made the opposite decision, cloning our full stack for each new market. That's great for scalability, but is a nightmare for devops. If anything we want to find a way to move to one global system, And then slice down the bits that can be local: Eg. Create a local order matching service, but keep orders, payments, and user accounts global
- brianwawok 10y agoIf you are doing devops, wouldn't deploying to 1 data center vs 20 be no more work? It's just a loop around a script.
- danpalmer 10y agoAll it takes is for one server in one datacenter to be slightly different, or perhaps you had a bugfix that needed to go out for users in one area, but you couldn't take the risk of a flaky deploy for the areas that didn't need it, now you've got a deploy that will be a lot more complicated or error-prone than a loop around deployment to one location.
- icebraining 10y agoAll it takes is for one server in one datacenter to be slightly different But doesn't a global system still run on multiple DCs, at least for redundancy? perhaps you had a bugfix that needed to go out for users in one area, but you couldn't take the risk of a flaky deploy for the areas that didn't need it But if you have a single global system, you can't even make that decision. To be clear, I'm not arguing against it, I'm just trying to understand why, since my first instinct would be to divide geographically as well.
- danpalmer 10y ago> But doesn't a global system still run on multiple DCs, at least for redundancy? If you've got 2 levels of separation - servers and 'groups' (whether they are datacenters, or whatever) - you've got 2 levels at which that special casing needs to happen. If you only have 1 level - servers - i.e. one deployment, even if that's across multiple datacenters, you only have 1 place to special case. I'd say that's easier. > But if you have a single global system, you can't even make that decision. Good point, but my point was that it will be simpler and less error prone in general. You might not be able to push the bugfix, or you might have to risk the deploy globally, but I think either would be better in the long run for a simpler deployment. It is a trade-off though.
- golergka 10y ago> Facebook originally tried to do that, then discovered that, as they grew, friends weren't local. Interesting. Do you have a link on that?
- stygiansonic 10y agoBasically, it was a way to partition users as some form of horizontal scaling. See these two Quora posts: https://www.quora.com/How-did-Zuckerberg-code-Facebook-so-fast-2 https://www.quora.com/How-did-Zuckerberg-code-Facebook-so-fa... https://www.quora.com/In-what-order-did-Facebook-open-to-college-and-university-campuses https://www.quora.com/In-what-order-did-Facebook-open-to-col...
- Animats 10y agoEE380 talk at Stanford with Facebook devs. They were there to talk about their PHP compiler, but got into how Facebook scales.
- uola 10y ago"Yet that's what has to work well to beat the competition, which is taxi dispatchers with paper maps, phones, and radios." In some part (maybe even a large part) of the world, yes. But in markets where taxis are from different companies (or in other ways make ordering one in advance more common) already has fairly sophisticated technology. Let's not promote the myth of startup exceptionalism. Uber has modern (but not futuristic) technology, but the real difference is in the business model.
- nl 10y agoYet that's what has to work well to beat the competition, which is taxi dispatchers with paper maps, phones, and radios. Taxis are a only part of the picture. Logistics is where the money is. Logistics is where network effects are important. FedEx doesn't use paper maps.
- taxicabjesus 10y ago> Yet that's what has to work well to beat the competition, which is taxi dispatchers with paper maps, phones, and radios. Large taxi companies started to switch to GPS-enabled electronic dispatch systems at least 12 years ago.
- jdavis703 10y agoRiders and drivers are also not local. I travel a lot and yet my star rating, profile picture and payment details work regardless of if I'm in the Bay Area, Berlin or DC. Further I've heard of Uber drivers giving rides to other regions, e.g. SFO airport to Sacramento (apparently fairly common as the Sacramento airport has limited service and is expensive).
- mooted1 10y agoSharding your application geographically is a quite a bit of complexity and requires a lot of work developing support infrastructure to manage load balancing, failover, and placement. One of the advantages of SOA is that different services can have different architectures. To be precise, we do do geographic sharding in the services that benefit from it, but avoid it in the services that don't. Also note that the assumption of region based partitioning doesn't extend to all applications. Analytics, for example, may want to dice and slice the data along different dimensions. Partitioning is a convenient abstraction for managing marketplace scale, as you mentioned, but inconvenient elsewhere :).