Forest header image

Symfony Finland
Random things on PHP, Symfony and web development

Facebook is an Open Source Powerhouse

Facebook as a company has become a major influence in lives of millions of developers. At first thought Facebook is the company which provides unstable APIs and annoying sharing widgets. But the work done by the Open Sourcing of internal products is changing this.

Many developers see Facebook similar to what Microsoft was in the nineties. The epitome of evil. And every once in a while there is someone announcing loudly that they've quit Facebook and are never going back. Mark Zuckerberg is the modern day Bill Gates to some.

Meanwhile the same people are becoming increasingly dependent on technologies and concepts developed at Facebook and then unleashed to the public domain via Open Source.

The rationale of Open Sourcing?

Open Source has made many branches of software a commodity. Web Content Management Systems like StoryServer whose pricing started at tens of thousands of Dollars and ended in millions have in many cases been rendered obsolete by free options.

Granted that cloud and integrated services like Adobe Experience Manager continue to have their place, but the technology itself is no longer a competitive advantage.

This is similar to Facebooks domain itself. They started on the web using Open Source technologies like Linux, Apache, MySQL, PHP. They created an application that had few unique technical innovations in itself, but the software was merely means to an end.

Since enjoying explosive growth Facebook has become large enough to require unique technologies and innovations. There are some core technologies that they will continue to keep in house, but for many cases they have open sourced their tools. And some have become very popular too.

I see Facebook as a very developer driven company. Maybe because of their background they are very aware of how disposable software really is. There are few drawbacks for giving away something that is common; generating karma and accelerating development. That's good legacy.

I don't use Hack so fsck Facebook...

The most prominent and Open Source technology is HHVM. It is a runtime for the PHP and Hack languages. PHP was a core technology behind Facebook, but they needed more performance and new features. A practical solution was to create a separate PHP compatible runtime and a completely separate language, Hack.

Facebook also initiated writing a specification for PHP itself, even though they were internally switching development from PHP to Hack. Hack continues to be quite sparse outside of Facebook, and while large sites like WikiPedia run on the HHVM runtime it's been hardly a revolution some hoped for.

Benchmark articles are great clickbaits, and you can definitely do some interesting ones between PHP and HHVM. The biggest thing about HHVM was that it gave PHP core developers competition. HHVM must have influenced the development of PHP7 quite a bit, leading to what looks like a great, and timely, release of PHP 7.0.

Facebook and the Front End

Perhaps the biggest shift in web development in the recent years has been the increased reliance on the client layer. Facebook was born on the web and has kept up pace very well. Web back end technologies are by nature obscure, where as the front end has been (see WebAssembly) fully exposed.

React and Flux have been Facebook's big hit in front end development. This combination of a front end component framework and complimentary application architecture has become a staple for thousands of developers.

Unlike Angular from Google it is not an all encompassing framework, so Flux has inspired multiple competing implementations and driven the JavaScript community forward as a whole.

This avoidance of coupling also signals that Facebook is ready to kill React, just like that, if something better comes along. So don't love React, Zuckerberg does not.

Hoodie beats labcoat

At launch time Open Source from Facebook is usually very robust. This is because they dogfood it themselves by using it on a site with over a billion users. There is a limited number of companies out there that have the capability to do so. This also means that the solutions built solve real problems that people have. Complex theory and a fancy execution amount to nothing if there is no use case for software.

In addition to HHVM, Flux and React - Facebook has dozens of interesting Open Source projects. You can already see other Open Source software starting to capitalize on some of the other Facebook innovations; The future of Drupal may well be Facebook powered with BigPipe and hints from GraphQL. Popularising existing technology is something Drupal has a strong history with.

I'm sure Mark can be a dick, but give him some credit.

Written by Jani Tarvainen on Friday September 25, 2015
Permalink - Tags: facebook, react, hhvm, hacklang, php, drupal, opensource

« Video: Symfony and Content Management - BigPipe and the Symfony Framework »