Skip to main content

One post tagged with "athena"

View All Tags
86 lines of code → $25,000 a year saved on Athena queries that read 38 KB and paid for 10 MB

86 lines of code → $25,000 a year saved on Athena queries that read 38 KB and paid for 10 MB

· 8 min read
Samuel Cozannet
Co-founder & CPTO, Cloud ex Machina

86 lines of code → $25,000 a year saved.

That's what one team got for batching a set of tiny Athena queries. In a sample, each one read about 38 KB, and Athena's 10 MB minimum charged it for roughly 260 times that. The production account sent 810,000 of them on a median weekday.

The queries also opened a lot of small files in S3. In one month the account paid $1,848 for S3 GET requests, against $15 for the storage. On the first weekday after the change, Athena and S3 GET cost together came to $39, down from $128 the day before.

This is the fourth post of Feedback loops from the FinOps trenches, after a Lambda function whose 100 workers had the throughput of 10.