Many teams are learning and researching Quora. Some time ago I saw this Quora's Technology examined, explained the technical architecture of Quora, and recorded and shared some important information.
Use cloud computing services
Quora uses Amazon EC2 and S3 services in large quantities. The operating system is deployed in Ubuntu Linux, which is easy to deploy and manage. The static content is cloudfront. service delivery, images are first transmitted to the EC2 server, using pyhon S3 "> APIAfter processing, it is uploaded to S3.
The advantage of using cloud computing services from the very beginning is that it saves a lot of costs for manual maintenance of hardware servers. Of course, this practice is not feasible in our land.
(Refer: copyright)
Web layer and "> CMS
Haproxy serves as the front-end Server Load balancer, the reverse proxy server is nginx, And the nginx is followed by pylons (pylons + paste) to undertake dynamic Web requests.
The two internal systems webnode2 and livenode undertake the responsibility of creating and managing content. webnode2 generates HTML, CSS, and JavaScript, and is slightly coupled with livenode. Livenode is used to display web page content. Written in Python, C ++, and JavaScript. Jquery and cython are used in particular. Livenode may be open-source.
Why python?
Some Python-related technical components have been mentioned earlier. Interestingly, Facebook's team actually uses python as the main development language. Quora explains this: Facebook chooses "> PHPIt is not the best choice, but for historical reasons. The Quora technical team chose python after examining multiple languages. Of course there are a lot of reasons. In general, it seems that it is not very radical.
Communication Processing
Backend communication uses thrift open-source from Facebook. In addition to the simple development interface, thrift may also become more familiar with thrift. The comet server uses tornado, it is used to process long polling and push updates (what is unknown ?), Tornado is an open-source product of the former friendfeed technical team.
Real-time search
Because sphft cannot meet the real-time requirements, Quora enables its own search engine and only uses the thrift and Python Unicode libraries. Quora has a special search function. to associate the input content with a valid prompt, you must provide a better prefix indexing function.
The implementation of Quora search is quite technical, and the query request pressure on the backend is not small (maybe the current number of concurrent requests is not that large ). For this scenario, you may wish to study it carefully. If the general framework is similar, the final cause may be those details.
Data Persistence Layer
MySQL is widely used as the storage solution and memcached is used as the cache layer. No nosql products are currently popular. Quora has its own reason for doing so, and the number of users has not reached one million. "> SNSThere is no need to use nosql for websites. Quora may be enabled later.
The Founders Charlie Cheever and Adam d'angelo are both on Facebook. Therefore, Quora's technology has a lot of Facebook genes. Quora's team size is not large, and it is estimated that more than 10 people are using technology. Such a compact team has used so many technologies and products, and many of them are versatile. This is a place for Chinese technical teams to learn from their foreign counterparts.
-- "> EOF--
This is just an overview description. If you want to know more details, please refer to the related comments on Quora. The relevant links have been provided above.
Original article address:
Http://www.dbanotes.net/arch/quora_tech.html