Friday, January 6, 2017

Open source contributions

Open source contributions

Facebook is both a consumer of and contributor to free and open source software.[188] Facebook's contributions include: HipHop for PHP,[189] Fair scheduler in Apache Hadoop,[190] Apache Hive, Apache Cassandra,[191] and the Open Compute Project.[192]
Facebook also contributes to other opensource projects such as Oracle's MySQL database engine.[193][194]
Facebook open source projects[195]
Logo Project Notes Languages Website
Webysther 20160330 - HHVM.svg
HipHop Virtual Machine open-source virtual machine based on just-in-time (JIT) compilation that serves as an execution engine for the PHP and Hack programming languages. C++, OCaml www.hhvm.com
Webysther 20160330 - Hack (language).svg
Hack Open-source programming language for the HipHop Virtual Machine (HHVM), created by Facebook as a dialect of PHP. The language implementation is open-source, licensed under the BSD License PHP dialect http://hacklang.org/
React.js logo
React open-source JavaScript library for data rendered as HTML. JavaScript facebook.github.io/react

Presto open source SQL query engine optimized for high-speed interactive analytics at scale.
https://prestodb.io/
Rocksdb-logo.png
RocksDB embedded database for key-value data C++ www.rocksdb.org

Website

Profile shown on Thefacebook in 2005
Previous Facebook logo in use from August 23, 2005 until July 1, 2015

Technical aspects

The website's primary color is blue as Zuckerberg is red-green colorblind, a realization that occurred after a test undertaken around 2007; he explained in 2010: "blue is the richest color for me—I can see all of blue."[196][197] Facebook is built in PHP which is compiled with HipHop for PHP, a 'source code transformer' built by Facebook engineers that turns PHP into C++.[198] The deployment of HipHop reportedly reduced average CPU consumption on Facebook servers by 50%.[199]
Facebook is developed as one monolithic application. According to an interview in 2012 with Chuck Rossi, a build engineer at Facebook, Facebook compiles into a 1.5 GB binary blob which is then distributed to the servers using a custom BitTorrent-based release system. Rossi stated that it takes approximately 15 minutes to build and 15 minutes to release to the servers. The build and release process is zero downtime and new changes to Facebook are rolled out daily.[199]
Facebook used a combination platform based on HBase to store data across distributed machines. Using a tailing architecture, new events are stored in log files, and the logs are tailed. The system rolls these events up and writes them into storage. The User Interface then pulls the data out and displays it to users. Facebook handles requests as AJAX behavior. These requests are written to a log file using Scribe (developed by Facebook).[200]
Data is read from these log files using Ptail, an internally built tool to aggregate data from multiple Scribe stores. It tails the log files and pulls data out (thus the name). Ptail data is separated out into three streams so they can eventually be sent to their own clusters in different data centers (Plugin impression, News feed impressions, Actions (plugin + news feed)). Puma is used to manage periods of high data flow (Input/Output or IO). Data is processed in batches to lessen the number of times needed to read and write under high demand periods (A hot article will generate a lot of impressions and news feed impressions which will cause huge data skews). Batches are taken every 1.5 seconds, limited by memory used when creating a hash table.[200]
After this, data is output in PHP format (compiled with HipHop for PHP). The backend is written in Java and Thrift is used as the messaging format so PHP programs can query Java services. Caching solutions are used to make the web pages display more quickly. The more and longer data is cached the less realtime it is. The data is then sent to MapReduce servers so it can be queried via Hive. This also serves as a backup plan as the data can be recovered from Hive. Raw logs are removed after a period of time.[200]
On March 20, 2014 Facebook announced a new open source programming language called Hack. Prior to public release, a large portion of Facebook was already running and "battle tested" using the new language.[201]
Facebook uses the Momentum platform from Message Systems to deliver the enormous volume of emails it sends to its users every day.[202]

History

On July 20, 2008, Facebook introduced "Facebook Beta", a significant redesign of its user interface on selected networks. The Mini-Feed and Wall were consolidated, profiles were separated into tabbed sections, and an effort was made to create a "cleaner" look.[203] After initially giving users a choice to switch, Facebook began migrating all users to the new version starting in September 2008.[204] On December 11, 2008, it was announced that Facebook was testing a simpler signup process.[205]

Notes

Facebook Notes was introduced on August 22, 2006, a blogging feature that allowed tags and embeddable images. Users were later able to import blogs from Xanga, LiveJournal, Blogger, and other blogging services.[39]

Chat

Facebook Chat was added April 6, 2008. It is a Comet-based[206] instant messaging application[207] which allows users to communicate with other Facebook users in a way similar in functionality to instant messaging software.

Gifts

Facebook launched Gifts on February 8, 2007, which allows users to send virtual gifts to their friends that appear on the recipient's profile. Gifts cost $1.00 each to purchase, and a personalized message can be attached to each gift.[208][209]

Marketplace

On May 14, 2007, Facebook launched Marketplace, which lets users post free classified ads.[210] Marketplace has been compared to Craigslist by CNET, which points out that the major difference between the two is that listings posted by a user on Marketplace are seen only by users in the same network as that user, whereas listings posted on Craigslist can be seen by anyone.[211]

Messaging

A new Messaging platform, codenamed "Project Titan", was launched on November 15, 2010. Described as a "Gmail killer" by some publications, the system allows users to directly communicate with each other via Facebook using several different methods (including a special email address, text messaging, or through the Facebook website or mobile app)—no matter what method is used to deliver a message, they are contained within single threads in a unified inbox. As with other Facebook features, users can adjust from whom they can receive messages—including just friends, friends of friends, or from anyone.[212][213] Email service was terminated in 2014 because of low uptake.[214] Aside from the Facebook website, messages can also be accessed through the site's mobile apps, or a dedicated Facebook Messenger app.[215]

Voice calls

Since April 2011, Facebook users have had the ability to make live voice calls via Facebook Chat, allowing users to chat with others from all over the world. This feature, which is provided free through T-Mobile's new Bobsled service, lets the user add voice to the current Facebook Chat as well as leave voice messages on Facebook.[216]

Video calling

On July 6, 2011, Facebook launched its video calling services using Skype as its technology partner. It allows one-to-one calling using a Skype Rest API.[217]

Video viewing

In September 2014, Facebook announced that it delivers 1 billion video views per day and that it would begin showing everyone view counts on publicly posted videos from users, Pages, and public figures. It also confirmed that it is recommending additional videos to users after they have watched a video. Sixty-five percent of Facebook's video views are coming from mobile where Facebook's user base is shifting, and views grew 50 percent from May to July, in part thanks to the viral ALS Ice Bucket Challenge finding a home on Facebook.[218]

Tor hidden service

Main article: facebookcorewwwi.onion
In October 2014, Facebook announced[219] that users could now connect to the website through a Tor hidden service using the privacy-protecting Tor browser and encrypted using SSL.[220][221][222] Announcing the feature, Alec Muffett said "Facebook's onion address provides a way to access Facebook through Tor without losing the cryptographic protections provided by the Tor cloud. […] it provides end-to-end communication, from your browser directly into a Facebook datacentre."[220] Its URL address facebookcorewwwi.onion is a backronym, which stands for Facebook's Core WWW Infrastructure.[219]

No comments:

Post a Comment