# S4 E11: Fast SQL Queries on Streaming Data with Arjun Narayan of Materialize

Published: 2021-03-16
Duration: 1559s
Audio: https://pdst.fm/e/pscrb.fm/rss/p/audio4.redcircle.com/episodes/a925002b-7e08-4abe-9e25-d646417ce87b/stream.mp3

## Key Takeaways
- Compute Layer, Not Pipes: Materialize leaves data movement to tools like Kafka and focuses on keeping SQL query answers up to date as streams change, even at hundreds of thousands of new data points per second.
- Cutting Persistence to Ship: Early on, Materialize chose not to store data itself, relying on Kafka and similar systems so the team could focus on a differentiated compute and query engine. Persistence was on the 2021 roadmap.
- A Database Needs the Whole Car: Frank McSherry had built the core engine for about four years before the company began. It then took a solid year to build the rest of the database to even a minimal acceptable standard.
- Engineers Talk to Customers: SQL outlines what to build but not the order, so the whole engineering team spends significant time with users. Arjun says they could have started this earlier than they did, after about six months heads-down.
- Write the Culture Down: Weekly all-hands are written as multi-page documents, so new hires can trace how the company's thinking evolved. Arjun sees this as a way to keep early grit while the team, then about 25, aimed to double.

Arjun Narayan grew up in India, programming as a kid. He came to America for college, thrown into the scene cold but really liked it. He studied computer science at Williams College in Massachusetts, and did his PHD at Penn, focusing on distributed systems, security, privacy and scalability. His doctorate taught him how to write at length, but out of the norm, he knew early on he didn't want to be an academic.

  

He is married, with a young son - and he really enjoys being a father. Today, his life consists of his startup and his young family, which are about the same age.

  

As he was as grad student doing his PHD, he came across a set of papers written by his co-founder - about a more capable, incremental compute engine. After several years of persuasion, Arjun convinced him that they needed to start a company to commercialize the solution.

  

This is the creation story of Materialize.

  

Sponsors

[VirtualPBX](https://www.virtualpbx.com/)

[Imagine Golf](https://www.imaginegolf.com/)

[KIMO](https://kimo.ai/)

[Unidragon](https://unidragon.com/) *Coupon: DragonStory, 10% Discount. Expires July 1, 2021*

  

Links

- Website: [https://materialize.com/](https://materialize.com/)
- LinkedIn:[https://www.linkedin.com/in/arjunravinarayan/](https://www.linkedin.com/in/arjunravinarayan/)

  

Leave us a [review on Apple Podcasts](https://ratethispodcast.com/codestory)

 

Amazing tools we use:

- This podcast is hosted on [RedCircle](https://redcircle.com/), a FREE platform for podcasts and brands to scale their message. 
- Want to record your remote interviews with class? Then, you need to use [Squadcast](https://squadcast.fm/?ref=noahlabhart).
- Code Story uses the 1-click product [ClipGain](https://clipgain.io/?utm_campaign=clipgain&utm_medium=episode&utm_source=codestory), sign up now to get 3hrs of podcast processing time FREE
- If you want an amazing publishing platform for your podcast, with amazing support & people – use [Transistor.fm](https://transistor.fm/?via=code-story)

  

*Credits: Code Story is hosted and produced by Noah Labhart. Be sure to subscribe on *[*Apple Podcasts*](https://podcasts.apple.com/us/podcast/code-story/id1466861744)*, *[*Spotify*](https://open.spotify.com/show/0f5HGQ2EPd63H83gqAifXp)*, *[*Pocket Casts*](https://pca.st/Z1k7)*, *[*Google Play*](https://play.google.com/music/listen?pcampaignid=MKT-na-all-co-pr-mu-pod-16&t=Code_Story&view=%2Fps%2FIcdmshauh7jgmkjmh6iu3wd4oya)*, *[*Breaker*](https://www.breaker.audio/code-story)*, *[*Youtube*](https://www.youtube.com/channel/UCgjZsiUDp-oKY_ffHc5AUpQ)*, or the podcasting app of your choice.*

  

Timestamps

00:00 – Intro

04:53 – Materialize Versus Sockets and Subscriptions

08:01 – Building the Materialize MVP

10:00 – MVP Trade-offs and Tech Debt

11:17 – Building the Roadmap

12:50 – Delighting Materialize Users

13:35 – Building the Materialize Team

15:33 – Scaling Materialize

16:29 – Proudest Moment

17:32 – A Mistake and Response

18:35 – The Future of Materialize

20:40 – Influences and Role Models

22:30 – What He'd Do Differently

23:20 – Advice for Young Entrepreneurs

Times are from the episode recording; ad breaks in your player may shift them a bit later.

  

Read the key answers from this episode, with quotes and timestamps from Arjun Narayan from Materialize: [https://www.codestory.co/episodes/s4-e11-engineering-fast-materialized-views-sub-second-queries-over-live-streams-with-arjun-narayan/](https://www.codestory.co/episodes/s4-e11-engineering-fast-materialized-views-sub-second-queries-over-live-streams-with-arjun-narayan/)

  
  

Current Sponsors:

- [Tiger Data](https://tigerdata.com/)

- [Protected Harbor](http://protectedharbor.com/codestory)

- [Render](https://render.com/)

- [Fitnexa](https://www.fitnexa.com/)

- [Perplexity](https://pplx.ai/codestory)

- [Entelligence](https://entelligence.ai/)

Checkout our Stacklist! [https://stacks.codestory.co/](https://stacks.codestory.co/)

Check out our [Patreon!](https://www.patreon.com/cw/codestory)

Hosted by  [Noah Labhart | Technical Founder & Startup Mentor.](https://noahlabhart.com/)

  
  
Our Sponsors:  
* Check out Granola and use my code granola.ai/CODESTORY for a great deal: https://granola.ai  
* Check out Perplexity: https://pplx.ai/codestory  
  
  
Advertising Inquiries: [https://redcircle.com/brands](https://redcircle.com/brands)  
  
Privacy & Opt-Out: [https://redcircle.com/privacy](https://redcircle.com/privacy)

## Chapters
- 0:00 — Intro
- 4:53 — Materialize Versus Sockets and Subscriptions
- 8:01 — Building the Materialize MVP
- 10:00 — MVP Trade-offs and Tech Debt
- 11:17 — Building the Roadmap
- 12:50 — Delighting Materialize Users
- 13:35 — Building the Materialize Team
- 15:33 — Scaling Materialize
- 16:29 — Proudest Moment
- 17:32 — A Mistake and Response
- 18:35 — The Future of Materialize
- 20:40 — Influences and Role Models
- 22:30 — What He'd Do Differently
- 23:20 — Advice for Young Entrepreneurs

## Frequently Asked Questions
- **Q:** What is Materialize and what problem does it solve? — **A:** Materialize is a database built for fast-changing streaming data, keeping answers to complex SQL queries updated ahead of time instead of waiting for overnight refreshes. Arjun Narayan explains that "we can keep the SQL queries" [06:25] up to date even at very high update volumes.
- **Q:** How is Materialize different from Apache Kafka? — **A:** Arjun Narayan says Kafka and similar tools handle moving data from point A to point B, while Materialize is the compute layer where those streams are analyzed with SQL. In his words, "It's not so much the pipes, it's the" [06:36] end point you point them to that gives the most leverage.
- **Q:** Does Materialize store your data? — **A:** At the time of the interview it did not, though Arjun Narayan said a persistence layer was on the roadmap for 2021. He described the product then: "It's purely a compute plane on top of an external system for storing your streams of data." [10:46]
- **Q:** How was the first version of Materialize built? — **A:** Co-founder Frank McSherry had been building the core engine as an open source project for about four years, and the company then spent a year building out the rest of the database. Arjun Narayan likens it to selling more than an engine: "You kind of need to sell the full car." [08:56]
- **Q:** What advice does Arjun Narayan give aspiring founders? — **A:** He recommends joining a best-in-class startup in your field before starting your own, as he did at Cockroach Labs, to learn how a business is built. Arjun's advice is to "find a best-in-class business in your field and join them early at the Series A" [23:52] or Series B stage.
