After my post How Hotel Reservations Work did so well I want to follow up with the Flight version. Flight reservations are such a complicated mess it will take at least 2 or even 3 posts, the first more high level and the last will have to wait until I can verify more of the ugliness that lives far from my area.
Compared to hotels air is more complex, more political, more competitive and less comprehendible than almost anything else in the world of software and data. Just getting answers to many of my questions is going to take a long time so I will have to put those in the last post. Since I live nearer the client side of things (mobile) much of the backend nightmare is still unclear.
Firstly, some terms and crap you should understand. Note that although these seem to be fairly obvious like everything in air there are always exceptions. Even the exceptions have exceptions. So remember everything I say may not be 100% true.
A flight segment is basically plane goes up plane goes down. So fly from JFK via DFW to LAX is two segments.
A flight leg is you get on you get off. So you get on at JFK and get off at LAX. A one way is just that, a round trip would be JFK to LAX and later LAX back to JFK. A multi-leg trip might be something like JFK to LAX and then later LAX to SFO and finally SFO-JFK. A single leg can be from 1 to 4 segments typically. You can change planes during a leg but it's still a leg if you continue on. If you stay long enough it might be considered two legs but there is no exact definition I know of. You can also have two one-ways instead of a round trip.
A flight is a numbered trip on a single airline (or partners or code shares) usually from a start airport to an end airport with one segment or many segments. Normally these are scheduled in advance and usually repeat on some regular basis. These generally use the same equipment but that can change.
A trip consists of one or more people traveling together through one or more segments. These can cross flights as needed. They can cross airlines as needed, though not all combinations are acceptable. Generally a trip is booked together and paid for together. Usually you can't have people get on and off during the trip, though I don't know if that's 100% true.
Equipment means a plane. Planes have a fixed set of seats where the layout and count is dependent on the airline that owns or leases the plane and can even vary depending on the age of the plane. Usually a flight has equipment assigned to it so that reservations can be made knowing how many people the plane can hold. Sometimes the equipment can be changed at any time until you take off, so this makes reservations get complicated.
A seat is what you sit in, and there has to be one for every passenger except for lap children. Ultimately this is what you are "renting" and what a ticket is supposed to give you access to. Determining who gets that seat for a particular combo of flight and date is the heart of the mess.
Dates are the date/time of when a leg starts, usually in the local timezone. This is when your butt hits the seat. When you take off is the only time that the connection between you and the seat is known for sure. Up until that time it's a web of caches, guesses and voodoo. The latter is why getting an assigned seat is often a lie to make you feel important.
Making a reservation means your trip exists somewhere (where I'll cover later). Booking/ticketing a trip means you paid for a reservation and are likely to show up and want a seat. Generally reservations not ticketed in 24 hours are likely to be cancelled.
Now things get messier.
Airlines create and manage the flights, sometimes purely under their logo, sometimes with partners or alliances, sometimes the flight is managed by one airline and operated by another. In most countries the first airline that you see is ultimately responsible but what the hell that means is dependent on where you are, where the airline is based, and mostly random cosmic particles as far as I can tell.
Airlines both own and lease equipment and generally get to decide how many seats are on it, the layout, and the number of cabin types. Since the income of the airline may depend mostly on the number of people they can fit on a single plane they go to great lengths to optimize the seating. Often the usage of a plane will dictate the layout so short-haul planes and overseas planes are rarely interchangeable. Even the size of the plane can be optimized based on typical demand but airlines don't like to switch equipment too often as that screws up reservations.
There are a lot of airlines in the world, but no central listing exists so you can't really know. Most of the recognizable airlines belong to IATA. Airlines often belong to large alliances which help to drive traffic between the partners and provide other benefits. Some airlines exist only to serve smaller flight routes for their big partners.
Now the two biggest parts of the whole flight system that most people want to know is, how do I book a trip, and what will it cost? The answer is a giant messy ugly crappy monstrosity.
So more definitions are needed now. Airline is obvious, they schedule the flights, own the equipment, and want your money in exchange for a seat. Most airlines' reservations are actually managed by a GDS company which stands for Global Distribution System but may also be known as a Computer Reservation System. These companies manage the data associated with a reservation and generally contract with a set of airlines. There are a little more than a dozen of these. The first major one was SABRE, a joint project between American Airlines and IBM, back in the early 60's. Most of the GDS companies date themselves back to the 60's and 70's and during the era of regulated airfares. Following the end of deregulation travel agents all gained access to these systems, so the model became Airline <-> GDS <-> Agent. At the same time GDS system started to contract with many airlines and become independent companies.
Once the internet appeared a new kind of seller appeared, the OTA, or Online Travel Aggregator (or Agency if you prefer). These were websites that offered the services of a travel agent but in a more automated environment. Today there are many OTA's but the majority are brands owned by Priceline, Expedia, Travelocity and Orbitz plus a host of smaller or focused companies. In most cases the OTA's contract with GDS systems and the airlines to provide reservations and ticketing. At the same time the airlines also put up websites and provided similar features. Travel agents continue to exist, though generally more as specialists. So with so many people providing access to reservations, everyone is a partner and competitor at the same time, and everyone needs and hates everyone else.
Additionally there are OTA like organizations (often owned by existing OTA's or GDS's) that cater specifically to contracted business organizations. Rarely a big business might manage their own travel but today it's mostly contracted.
With all of these people providing overlapping competing services, combined with often ancient backend technology, makes for a very complex and volatile stew. Even though there exists somewhere a plane with seats at a point in the future, there is no easy source of who is going to be on that plane and sit in those seats. What you have is a complex set of cached views shared among a host of online and offline systems that are updated on different timescales. It looks like a kind of Schroedinger's cat where the seat might be filled or not, and it depends on who is looking and when.
It's certainly possible that the last seat on a flight at some future date is shown as available on many different places at the same time. If many people try to reserve it, it is certainly possible that the seat might be held by all of them or none of them. This type of multiple-truth problem is not easy to solve with so much latency in the system and can lead to overbooking. Of course airlines know this and might encourage things to lead to overbooking but I don't know how easy this is to "encourage".
People always complain when a flight is shown as available in a search but after hitting the Book button it is no longer available or the price has changed. This isn't someone trying to screw you but a side effect of the latency and all the layers of caches that exist. At the point of the search the server thought it had seats or that the pricing was X, but especially today and in the next few days, the last seats can cause the data to become stale quickly. Like in hotels, the final book operation is more likely to reach a lower level of staleness and result in an upgraded version of the truth. As you can see even if you get a ticket, you might not be the only one holding it at that moment.
This post is getting too long and I still have a ton of stuff to talk about, so I guess we might be getting 3 parts.
Next up, how does a search pick flights, and what about pricing, and how politics, competition and profit muddle it all up.