Based in Tel Aviv, Inneractive is a mobile ad exchange that provides technologies for the buying and selling of mobile advertising space. The company provides mobile app developers with access to an international portfolio of advertising networks, connecting brands to applications. It has about 80 employees, half of whom concentrate on research and development (R&D), and it serves content to more than 450 million unique users a month. Inneractive has grown rapidly since it was founded in 2007, and will soon add a Beijing office to its existing locations in Tel Aviv, London, New York, and San Francisco.
R&D Group Manager Gal Aviv explains some of the technical challenges the company faces: “The load on servers is very high,” he says. “Providing this many ads creates a few billion requests on our servers each day—around three to five million per minute. We handle tens of millions of transactions per minute, and aggregate roughly 15–20 terabytes of raw data each day. Analyzing this data helps improve performance and generate revenue for our app publishers.”
Uptime is absolutely key for Inneractive. “We can’t allow services to be disrupted even for a second. Serving up a black square in place of an ad would make for a terrible user experience,” says Aviv. Latency is just as important, because users don’t want slow ads to hamper their mobile browsing. “We can’t go over 200 milliseconds, on average, to serve an ad,” says Aviv. “Most of the time it’s about 100–150 milliseconds. That’s a big ask when you’re dealing with tens of thousands of incoming requests per second.”
Inneractive has based its entire ad exchange infrastructure on Amazon Web Services (AWS) since 2010. It currently operates three fleets of Amazon Elastic Compute Cloud (Amazon EC2) instances to ensure it is always running as cost-effectively as possible. For base capacity, Aviv and his team have up to 100 Amazon EC2 Reserved instances. Inneractive saves money by paying in advance for instances that exist for one to three years, rather than paying the on-demand price. The company’s next, and largest, fleet of Amazon EC2 instances is made up of around 800 Spot instances. This tier provides the best cost-performance. The prices of Spot instances fluctuate according to demand. Users submit a fixed bid for an EC2 instance, and as soon as the Spot market price of an instance drops below the bid, the user gets their instance for as long as its price stays below their bid. But as soon as the market price exceeds the bid, the instance is terminated.
To stop its jobs from being interrupted by terminating Spot instances, Aviv tried to write scripts in-house, but, he says, “It proved to be a bit of a headache.” By working with AWS partner Spotinst, Aviv was able to guarantee capacity and service levels for Inneractive’s Spot instances so he can maintain performance and keep costs down. The company’s EC2 Spot instances are all managed through a dashboard provided by Spotinst.
“Making the most of the Spot market and running cost-aware applications using Reserved instances purchasing options can be a long, complicated, and time-consuming process, even for mature companies with sophisticated R&D programs and extensive cloud experience,” says Amiram Shachar, CEO of Spotinst. “Spotinst allows any company to outsource management and provision of their entire EC2 resources so they can focus on the core elements of their business.”
A final “top-up” layer of on-demand instances exists to fulfill any need beyond the first two layers. Aviv says, “Providing this multitier architecture gives us full redundancy and stability. We know we can remain up all the time, and it’s the most cost-effective option because of the Spot instances.” Inneractive also uses Amazon ElastiCache to provide an in-memory cache for its MySQL databases, Amazon Redshift as a fully managed data warehouse, and Amazon Simple Storage Service (Amazon S3) to house its analytics data. Amazon Glacier provides further low-cost storage for data archiving and backup. Inneractive can operate its cloud infrastructure from within secure sub-networks by using Amazon Virtual Private Cloud (Amazon VPC), and it can monitor its resources with Amazon CloudWatch.
By partnering with Spotinst and using Spot instances, Inneractive has saved money while maintaining performance of its platform. Aviv says, “The company has saved tens of thousands of dollars. That’s between 20 and 30 percent of our total monthly AWS bill. I was able to maintain good performance more easily, while further reducing infrastructure costs. Our board is very happy.”
It took the DevOps team at Inneractive just two days to configure its infrastructure to run on Spot instances. “Our setup is complicated because we have a lot of different Auto Scaling groups,” says Aviv, “but the Spotinst dashboard is easy to work with and we get a good overview of stats.”
Inneractive also tuned configuration for optimal performance per instance type. “We identified six instance types and configured for the best performance on each one,” says Aviv. “When we have more time we might look at other types and refine our app for even better performance.”
Inneractive’s next step with AWS is to provide full multi-region support for its infrastructure. “We’d like to merge and aggregate data worldwide to make our service even better, so a request generated in Europe will be served in Europe,” says Aviv.
- A Technology Partner of the AWS Partner Network (APN), Spotinst offers a cloud-cost management platform to help AWS and customers save money while ensuring high availability and performance.
- Using advanced machine learning, Spotinst provides an automated IaaS (Infrastructure as a Service) platform for both enterprises and startups that optimizes their AWS deployments.
- For more information about how Spotinst can help your company build and manage your AWS environment, see Spotinst’s listing in the AWS Partner Directory.
To learn more about how EC2 Spot instances can make computing more cost effective, visit our Spot instances details page.