Facebook garners big gains from tighter management of open source

Facebook is now contributing more to external open source projects and keeping closer tabs on its own open source efforts

Blake Matheny, Infrastructure Engineering, Facebook.

Blake Matheny, Infrastructure Engineering, Facebook.

Thanks to some applied discipline, Facebook is reaping greater benefits from its efforts around open source software.

The social network has relied on open source since its inception, but it didn't formalized those efforts until 2013 when infrastructure engineer Blake Matheny started overseeing its open source projects.

The company relies almost exclusively on open source to serve its billion-plus users. Having the source code for software it uses allows it to easily make changes that suit its needs. Its engineers have modified many programs, including MySQL, JavaScript and PHP, so they can better serve its massive user base.

With so many users, "we faced a lot of new challenges that the software wasn't designed for," Matheny said Wednesday in a talk at the Linux Summit in Santa Rosa, California. "So we work hard to try to improve them."

The company's React JavaScript framework, for instance, was the result of its effort to improve JavaScript, while its Hip Hop Virtual Machine optimized PHP to run more quickly. It has made both those tools open sourced to get input from other developers.

Relying on open source also helps Facebook's new technical hires get up to speed quickly. "If you have to wait six months for an engineer to get trained on some proprietary internal system, that is time wasted, " Matheny said.

Facebook has maintained 235 open source projects on GitHub, consisting of more than 10 million lines of code. The software covers all aspects of running an Internet service, including data management, security, Web design, mobile computing, and infrastructure management.

Posting code it developed in house has helped Facebook in numerous ways. "It makes us write better software," Matheny said. Knowing their work will be exposed to other developers means its engineers write cleaner, more modular code that's less inextricably tied to other Facebook programs.

When Matheny assumed the role as open source steward, he wrote a series of scripts to get information from GitHub about how the software is being used by outside parties. He can see how many external developers a project attracts, how many suggested changes or bug reports they submit and how quickly those changes are applied.

"You can see which projects are doing well and which projects have issues," Matheny said.

This data has spurred project owners to update their code more quickly. When Matheny first started keeping tabs, the average pull request, or suggested change, was over a year. That time is now down to three months.

The company has also increased its contributions to other open source projects. In 2014, Facebook engineers contributed 214 changes to the Linux kernel, up from 6 in 2013.

Having its own modifications implemented in the Linux kernel means Facebook engineers don't have to re-implement their changes each time the kernel is updated. It also ensures that Linux-tested equipment from hardware manufacturers will be ready to operate within Facebook, Matheny said.

Joab Jackson covers enterprise software and general technology breaking news for The IDG News Service. Follow Joab on Twitter at @Joab_Jackson. Joab's e-mail address is Joab_Jackson@idg.com

Join the newsletter!

Or

Sign up to gain exclusive access to email subscriptions, event invitations, competitions, giveaways, and much more.

Membership is free, and your security and privacy remain protected. View our privacy policy before signing up.

Error: Please check your email address.

Tags open sourceFacebooksoftware

More about FacebookIDGLinuxMySQLNews

Show Comments
[]