Since I spent about six months of my professional life working on TripAdvisor’s hotel availability comparison feature, I thought a little writeup about it here would be appropriate. If you fill in the form over on the right you will be taken to a page on TripAdvisor that shows hotels that are available for the dates that you chose.
- Accepts your specific information (destination, dates, number of guests)
- Shows you only hotels which have rooms available for your dates. Availability is gathered from the big on-line travel agencies and individual hotel chain websites.
- Sorts hotels by TripAdvisor’s popularity index so you are sure to get a hotel with a good reputation in which you will have an enjoyable stay.
- You get all the information you need to choose your hotel:
- User reviews
- Price information
- Use TripAdvisor’s QuickCheck feature to find the best price for the hotel from the various vendors and then book your room.
Behind the Scenes
On the fly, TripAdvisor fetches pricing and availability information from the vendor websites and shows you hotels that are available as they are found. That is a fairly tall order. Two engineers worked on the project non-stop for six months while another two engineers helped out for a couple months each.
- Hotel database – We used the existing list of hotels along with the links to the hotel on various vendor sites that is one of TripAdvisor’s main assets.
- Crawlers – To fetch information from vendor sites
- Permission – To run crawlers that would fetch thousands of pages from the vendor sites every day.
- Scalability – Multiple machines to run these queries and report back to the web servers
- User interface – Web page that would dynamically update as the crawlers found hotels.
If you refresh a page, the hotels will all appear immediately because it caches the results of the crawls for a while. You also may see all the hotels appear right away if you search for a popular city with the default dates. In that case somebody else may have requested that the crawls happen.
The search component that support the destination field just “does the right thing” most of the time. If you enter “Paris”, it knows you mean Paris France not Paris Texas. But if you enter Portland, it will let you choose between Portland Oregon and Portland Maine. It even accepts quite a wide variety of common misspellings.