Overview
pTwitter is one of the most prominent social networks worldwide. As with all social networks, Twitter’s performance gets measured by its number of monthly active users (MAU); the company reported 336 million MAUs during its recent first-quarter 2018 earnings call. Year over year, those users have increased their active use of Twitter by 10 percent. After many years of steep losses, Twitter has managed to have back-to-back quarters in the black, with a profit of $61 million in the first quarter of 2018./pSupernova Award Category
Tech Optimization and Modernization
The Problem
pBecause its service is free to consumers, Twitter is always under pressure to reduce costs. The more efficient Twitter’s infrastructure is, the better for Twitter’s profitability. And because financial analysts value profitability, Twitter must focus on cost efficiency in its operations. At the same time, Twitter—in its role as an advertisement service—cannot skimp on uptime and reliability. When Twitter is down, no ads can be served and no advertisement revenue flows. With © 2018 Constellation Research, Inc. All rights reserved. 5 advertising representing more than 80 percent of total revenue for Twitter, any downtime has immediate implications on the bottom line. Beyond immediate cost pressures, Twitter also needs to account for its future viability as a platform and its attraction as an employer to developers. The future of social media is not cast in stone. That means different services and media may be needed a few years from now. At the same time, information science graduates often change their preferences for what development languages they want to use in their first professional jobs. Therefore, a more language-agnostic platform would benefit Twitter in both investment security and talent acquisition/pThe Solution
pGiven these three challenges—cost pressures, future-proofing and talent acquisition—Twitter implemented the Oracle Graal compiler. Engineers had to convince the owners of the microservices to implement them in production. A few gave it a try, and as they showed positive results, more and more microservice owners have switched over to Oracle Graal, to the point that most of Twitter runs on Oracle Graal today. Twitter started with smaller microservices to test the performance and stability of Oracle Graal but quickly gained the confidence to move the quintessential Tweet microservices to Oracle Graal. As of summer 2017, the three major services of Twitter—Tweet, Social and News—have been running in production powered by the Oracle Graal compiler./pThe results
pTwitter is seeing substantial benefits from using Oracle Graal, as expected on the hardware side, in tangible cost savings, but also longer term in terms of platform flexibility and talent acquisition./p p• Server savings. Twitter’s hardware and IT costs are proprietary and cannot be shared. But with Graal, Twitter can run about 10 percent more load on the same infrastructure. This is a remarkable result that normally can be achieved only with changes to the underlying code. The impressive results delivered by Oracle’s Graal compiler, applied to the average CPU cost of a server run by a public cloud provider, is about $127 per year and CPU. For enterprises operating hundreds or thousands of servers, this quickly results in substantial savings. /p p• Platform benefits.Twitter gains the flexibility to create capabilities beyond its current assets that are written in Scala. Future requirements may create the need to support other languages that are more suitable to the use case to be addressed. Acquisitions happen often, and integrating new capabilities with existing ones is a key success factor. With the multilanguage support in Oracle Graal, Twitter gains substantial platform freedom and flexibility. Time to market of in-house-built and potentially acquired new capabilities will be shorter while keeping the economies of scale in place that a common platform provides./pMetrics
ul liBeing able to see 8–11 percent performance improvements on the same hardware without having to change the underlying code is a once-in-a-lifetime event, leading to substantial cost savings and future flexibility for Twitter./li liEarly experiments have shown a potential total savings of 13 percent CPU time compared with the baseline./li /ulThe Technology
pUsing a polyglot compiler like Oracle Graal is a key step toward future-proofing a platform, both in terms of load flexibility in the short run and, more strategically, regarding programming language artifacts running on the same infrastructure and server fabric. Moving to Oracle Graal opens software creation to additional programming languages, insulating enterprises in regard to running heterogeneous codes and enabling them to hire programmers proficient in other languages./pDisruptive Factor
pTalent acquisition gains. If there is one thing that is certain about the future, it’s that recruiting developers will get increasingly difficult, especially in Silicon Valley. At the same time, the programming languages of choice are changing fast. What used to be C became Java and is now Python. Running on a platform that supports multiple languages adds substantial benefits because Twitter will be able to tap into a larger talent pool for acquiring new employees. At the same time, the company likely won’t have to retrain new employees because they are able to program in the language they already know best./pShining Moment
pThe adoption of Oracle Graal has quantitative and qualitative benefits. On the quantitative side, average CPU savings of 10 percent result in substantial server savings—or additional capacity. Of course, savings will vary by application, platform, language and utilization. But given that no code needs to be touched, savings in this range justify an isolated functional and then performance test./p