
Databases and Frameworks at the Edge with Glauber Costa and Igor Minar
Glauber Costa and Igor Minar join Anthony Campolo for a discussion about the future of developing web applications at the edge with databases and frameworks
Episode Description
Glauber Costa and Igor Minar discuss SQLite at the edge, the origins of Turso and libSQL, and Cloudflare's smart placement feature.
Episode Summary
Recorded live at Remix Conf, this conversation hosted by Anthony Campolo brings together Glauber Costa of Turso and Igor Minar of Cloudflare to explore the emerging landscape of edge databases and compute. Glauber traces his career from Linux kernel contributions at Red Hat through the unikernel era at Cloudius Systems and his time at ScyllaDB, explaining how those experiences led him to co-found ChiselStrike, which eventually pivoted to Turso — a managed SQLite-based edge database. He explains why SQLite's efficiency makes it uniquely suited for resource-constrained edge environments and reveals that Turso actually runs libSQL, an open-contribution fork of SQLite that adds features like write-ahead log access and WebAssembly user-defined functions. Igor then shares his transition from leading Angular at Google to joining Cloudflare's developer platform team, where he works on products like Workers, Pages, D1, and R2. The two guests converge on the central challenge of edge computing — data locality — and Igor introduces Cloudflare's upcoming "smart placement" feature, which automatically positions server-side compute near a centralized database rather than blindly running everything at the edge. The discussion highlights how edge computing is less about where servers sit and more about abstracting away regional concerns so developers can build truly global applications without managing infrastructure complexity.
Chapters
00:00:00 - Introductions and Glauber's Open Source Origins
Anthony Campolo opens this live podcast recording at Remix Conf and introduces Glauber Costa, whose company has gone through several name changes from ChiselStrike to simply Turso. Glauber begins recounting his career, starting around the year 2000 when he defied friends' advice and pursued Linux kernel development — a move widely considered foolish at a time when open source had no clear business model and operating systems seemed like a dead-end career path.
Despite the skepticism, Glauber's kernel contributions led to a job at Red Hat, which had pioneered the model of giving away software and charging for support. He spent roughly a decade doing low-level Linux work, establishing deep expertise in operating systems and open source community dynamics that would shape everything he built afterward. His early career illustrates how betting on open source before it was mainstream could pay off enormously.
00:04:35 - From Unikernels and ScyllaDB to the Database World
Glauber describes joining a startup founded by the creator of the KVM hypervisor to build unikernels — minimal operating systems designed to run a single application inside a VM for better performance. When Docker and containers emerged and the unikernel concept failed to gain traction, the company pivoted to become ScyllaDB, a C++ reimplementation of Apache Cassandra that delivered performance numbers ten times higher through techniques borrowed from kernel engineering.
Although Glauber had never planned to work on databases, the pivot brought him deep into that world. He became closely involved with customers, marketing, and sales, gaining firsthand insight into how database purchasing decisions were made — typically by DevOps or infrastructure personas rather than application developers. This observation would become central to the thesis behind his next venture.
00:08:22 - The ChiselStrike Experiment and Pivot to Turso
Glauber explains how platforms like Cloudflare Workers were shifting database decisions toward application developers who didn't want to deal with SQL or traditional database management. ChiselStrike's original approach bundled a database with an ORM, combining Deno and SQLite so developers could define schemas in TypeScript without writing SQL. While people found it interesting, it never achieved the traction the team wanted, partly because it required its own runtime instead of deploying directly on platforms like Cloudflare.
What consistently drew attention was the underlying SQLite work. The team decided to strip away the API layer and ship just the database product, which proved extremely successful. This pivot mirrored Glauber's earlier experience at Cloudius Systems, where the original vision didn't land but something valuable emerged from the exploration. The lesson reinforced that building what people actually want to buy matters more than what you want to sell.
00:13:19 - Why SQLite and the Birth of libSQL
Glauber explains that while SQLite is technically public domain rather than open source, it is not open to outside contributions — a constraint that frustrated many companies trying to adapt it for edge use cases. Rather than building workarounds like others were doing, Turso simply forked SQLite into libSQL, a fully open-contribution project. The fork adds features like improved access to the write-ahead log and WebAssembly user-defined functions, while continuing to back-merge changes from upstream SQLite.
The conversation turns to why SQLite is ideal for edge computing. Glauber distinguishes the edge from the cloud by emphasizing two factors: the abstraction layer that removes regional awareness from application code, and the economic reality that edge locations have fewer resources than massive data centers. SQLite's small memory footprint and efficient compute requirements make it uniquely suited to run affordably across dozens of locations — Turso can operate in 34 regions for under $200 per month.
00:24:58 - Getting Started with Turso and Transition to Igor
Glauber walks through Turso's developer onboarding: sign up at turso.tech with a GitHub account to access the free tier, which includes a billion row reads per month across three global locations. He discusses the upcoming $29/month plan offering six locations, and notes that the local development experience mirrors production — developers simply swap a file path for an HTTPS URL to go from local SQLite to a globally distributed Turso database.
Anthony then transitions the conversation by bringing Igor Minar on stage. Igor introduces himself as a member of Cloudflare's developer platform team, having spent over a decade at Google working on Angular and front-end infrastructure before joining Cloudflare to focus on uniting client-side and server-side development through edge computing. He sees the client side as reaching its limits and believes the real gains now come from combining both sides in new ways.
00:29:52 - Cloudflare's Developer Platform and D1
Igor describes his work on Cloudflare's developer platform, which encompasses Workers, Pages, D1, R2, and Wrangler. When Anthony points out that D1 is technically a Turso competitor since both offer SQLite at the edge, both guests handle it gracefully — Glauber jokes about a post-conference fight while Igor explains Cloudflare's broader motivation. Their primary goal is building low-level primitives that make products like D1 possible, then exposing those primitives so anyone can build similar services on top.
Igor highlights Cloudflare's unique infrastructure advantage: over 275 data centers built over 13 years with so much bandwidth that products like R2 can offer S3-compatible storage without egress charges. The vision is for developers to either deploy applications directly on Cloudflare or for partners like Turso to build their own solutions using Cloudflare's underlying primitives, creating a platform ecosystem rather than competing on every individual product.
00:33:28 - Smart Placement and the Edge Compute Dilemma
Igor reveals Cloudflare's upcoming "smart placement" feature, which addresses a fundamental problem with naive edge deployment. When a Remix application is deployed to the edge but its database lives in a single region like US East, users far from that database experience compounded latency as server-side rendering triggers multiple round trips between the edge compute and the distant data store. The result can actually be worse performance than centralized hosting.
Smart placement solves this by monitoring application behavior and automatically positioning compute near the data source rather than at the edge. Static assets still serve from edge locations, but dynamic server-side rendering runs close to the database. The developer simply opts in without choosing regions, and Cloudflare handles the routing. Glauber notes this aligns with his own definition of edge computing — it's less about where servers physically sit and more about abstracting away infrastructure concerns so developers can build globally without thinking about placement.
00:40:03 - Wrap-Up and Where to Find the Guests
Anthony closes the live recording by noting how well Turso and Cloudflare's approaches complement each other — one brings data to the edge while the other intelligently moves compute to the data. Glauber directs listeners to his Twitter handle @glcst and the Turso database account, while Igor points people to his personal site at igor.dev for easy contact.
The segment ends with thanks to the live audience and to Remix Conf for hosting the recording. The conversation demonstrated that the edge computing ecosystem is maturing through multiple compatible strategies rather than a single winner-take-all approach, with both data distribution and smart compute placement playing important roles in making globally performant applications practical for everyday developers.
Transcript
00:00:05 - Anthony Campolo
Alrighty. Well, hello everyone. Thank you so much for joining us. My name is Anthony Campolo. I'm here reppin' JavaScript Jam, which is a podcast hosted by Edgio. If you check us out, we are the very bottom-right corner there on the sponsors page. And we have Glauber here joining us from Turso/ChiselStrike. We'll talk a little bit. Just Turso now. ChiselStrike is dead. Never to return.
00:00:34 - Glauber Costa
It's a company name, right? It happens.
00:00:37 - Anthony Campolo
Why don't you go ahead and introduce yourself and explain to people what all these names mean.
00:00:42 - Glauber Costa
That's right. Thank you. So thanks for having me, and it is a pleasure and an honor to be recording a podcast with
00:00:48 - Anthony Campolo
an audience. I know.
00:00:49 - Glauber Costa
Is this your first time as well?
00:00:51 - Anthony Campolo
Yes. Yeah. First time hosting a live podcast. I've been hosting podcasts for many, many years. This is the first time doing one live. So very much appreciate you all joining us for this.
00:01:02 - Glauber Costa
Awesome. So thanks for having me.
00:01:03 - Anthony Campolo
Yeah. So tell the audience a little bit about your background. You have an illustrious career in open source. You've worked on the Linux kernel, worked on ScyllaDB. You've done a lot of really cool stuff. So why don't you give kind of a couple-minute, compacted history of where you came from.
00:01:18 - Glauber Costa
Awesome. So I started my career around the year 2000. And this is one of the things we were talking about today: how at the time, much like today, everybody was kind of scared because of the crisis. And, you know, 2001 was a bubble. I'm not going to go into whether it was bigger than today or not. Everyone has an opinion, but it was quite disastrous in a lot of senses as well. And I started my career essentially doing open source. I took a liking to the Linux kernel. It is something that all my friends at the time told me not to do.
00:01:49 - Anthony Campolo
The words that they used... that's incredible. This is why I tell people not to take advice from people, because people give overwhelmingly bad advice.
00:01:59 - Glauber Costa
Yeah. And the other thing about advice is that if you ask 10 people
00:02:02 - Anthony Campolo
you get 10 different answers. Yeah, totally.
00:02:05 - Glauber Costa
But the reason people told me back then, like, "Don't do it," and the words that they would use were like, "This is completely stupid. This is the worst decision you can ever make in your life," like that kind of flair. And the reason for that is that, first of all, it's an operating system.
00:02:21 - Anthony Campolo
Right.
00:02:22 - Glauber Costa
There's no innovation happening in operating systems, even if you like computers. Because on top of everything, I actually ended up graduating in CS. But when I started university, I was doing mechanical engineering, right? So I was doing this because I liked it, right? Open source and Linux, I just took a liking to it. And so first of all, it's an operating system. Even if you want to go more toward that, look at the web, look at this stuff, look at etcetera. Where is the innovation? What kind of career can you build in that? And second of all, open source is the worst idea the world has ever had. I mean, it's all free. How are you going to make money off of it?
00:02:59 - Anthony Campolo
Who's going to work for free?
00:03:00 - Glauber Costa
And it's funny because today this is such an established thing, it became the other way around. If you have infrastructure software like a database like we do today, and you're not open source, people don't even look at you because then there's trust issues. But at the time, the database that everybody used was Oracle, and the operating system that everybody used was Microsoft Windows.
00:03:22 - Anthony Campolo
The worst of all worlds.
00:03:24 - Glauber Costa
And it could have been Microsoft Access as the database, but it wasn't like it is today. So you're really going to bet your career and change everything you're doing to go do operating systems for free? That sounds stupid. But I guess I was stupid back then, and it paid off. So I stayed around. "Stupid like a fox," yeah. Much to my detractors' surprise, there was a company that started doing better and better and better, and they had this idea that nobody truly understood: we'll give you our software for free, and we're just going to charge you for the support of that software. It was called Red Hat, and they just hired me out of my contributions to the Linux kernel, and there we had the money problem essentially solved, at least to some extent, right? And I stayed. I did some quite small things here and there for other companies, but Red Hat was the bulk of my Linux career overall. It lasted around 10 years. I was doing that up until 2012, and then I joined another startup. Red Hat was not a startup when I joined it. It was already a public company, a small public company, but still.
00:04:35 - Glauber Costa
And then I joined a startup at the time that was founded by the creator of the KVM hypervisor, with whom I became friends through my Red Hat days. And what they were trying to do... Docker was not a thing, containers were not a thing. And what we were trying to do at the time was something called the unikernel. And a unikernel is...
00:04:52 - Anthony Campolo
I've heard that term before.
00:04:53 - Glauber Costa
Yeah, yeah. It's a kernel that can run a single thing at a time. And because of that you've applied a bunch of optimizations, and the thinking behind it was that everything is going to the cloud, everything is virtualized now. So instead of running Linux on top of Linux, let's run this other thing on top that we just wrote in C++ called OSv. And it's going to be 20% faster, 30% faster, whatever, because you don't have the overhead of a full operating system. Because at the end of the day, we noticed people were running a single application per VM. That's how they did it back then. Docker showed up, other things happened. I don't think people actually took a liking to the concept to begin with. That didn't quite work. And then we pivoted to a database company called Scylla. So at the time the company was called Cloudius Systems.
00:05:42 - Anthony Campolo
Right.
00:05:42 - Glauber Costa
And it pivoted to...
00:05:44 - Anthony Campolo
Yeah, because I've heard of Scylla in the past. I was someone who studied databases a little bit a couple years ago. That was one that came up frequently.
00:05:51 - Glauber Costa
Yes.
00:05:51 - Anthony Campolo
And I think it was like a multimodal kind of database?
00:05:55 - Glauber Costa
Some people still are not that familiar with Scylla today, which is a shame. But lots of people are familiar with Apache Cassandra. So you're probably familiar with Apache Cassandra. Scylla outgrew this concept to some extent, but what it was, was a reimplementation of Apache Cassandra in C++.
00:06:16 - Anthony Campolo
so wide column store.
00:06:17 - Glauber Costa
Yeah, essentially the same. But not only was it C++, we were bringing a lot of techniques from the kernel and stuff like that, like direct I/O, like we were not using memory-mapped files. And that, for the time and place where we were doing this, was quite novel. And because of that we could actually post performance numbers 10 times higher consistently, 10x and sometimes more than Apache Cassandra. And that was our play: we're going to do this. So I stayed doing this for... I was always joking that back then, if you invited me to join a database company, my answer would have been hell no. But then the database company joined me, in a sense, because I joined a kernel operating system company, which is what I was trying to do.
00:07:02 - Anthony Campolo
So how does Scylla get to ChiselStrike?
00:07:04 - Glauber Costa
Well, at some point I just left, right? And then I wasn't a founder, but I was employee number two.
00:07:09 - Anthony Campolo
So you saw that you had database experience enough to where you felt that you could start your own database company?
00:07:15 - Glauber Costa
Broadly speaking, yes. I had a year at Datadog in the meantime. That was in 2020, driven by... I'm not gonna put all of it into the pandemic, but to some extent everything was changing very rapidly.
00:07:30 - Anthony Campolo
I mean, everyone's life was like...
00:07:31 - Glauber Costa
[crosstalk]
00:07:32 - Anthony Campolo
I feel like they have a pivot point at the pandemic one way or the other.
00:07:35 - Glauber Costa
That is not why I left Scylla, but this is why I didn't start a startup right away.
00:07:40 - Anthony Campolo
Okay.
00:07:40 - Glauber Costa
That makes sense, right? And my plan was like, hey, I'm gonna be here doing, you know, maybe a couple of years, three or four years.
00:07:49 - Anthony Campolo
Did you just have the idea yourself you wanted to build a company or it was an opportunity kind of presented to you?
00:07:53 - Glauber Costa
It was both. I always wanted to build a company. That's always something that I wanted to do. But in my timeline, it was going to be after three years at Datadog, four years at Datadog, something like that. But then an opportunity arose for us to found ChiselStrike. And just because you mentioned it, the idea of ChiselStrike was this: we had this understanding that with platforms like Cloudflare becoming dominant, database decisions were not made by the same people that made them before, like when we were selling Scylla.
00:08:27 - Anthony Campolo
Did you feel like the DBA is dying?
00:08:29 - Glauber Costa
Well, I mean, all those things about this is dying, this is dying. Nothing in our industry truly dies.
00:08:35 - Anthony Campolo
But do you feel like the DBAs have a monopoly on database decisions?
00:08:40 - Glauber Costa
Yeah, exactly right. And that's the best way to frame it. It used to be the case, like when we sold Scylla. And I mean, I'm an engineer by trade. As I said, I spent 20 years essentially doing heavy low-level coding. But I took a liking as well to going and doing business. And at Scylla, when we started gaining customers, I wanted to be close to those customers and help them in any way I could. So I helped the marketing team. Needless to say, the CEO loved me because I was always involved with marketing, with sales, with support, and etcetera, coming from this deep engineering background. I wrote large parts of the database, so I knew I was in a position to help those folks. And every time we sold into a deal, again, the profile of the person involved in that decision was very similar. It was no longer really a DBA; it was more like a DevOps persona or infrastructure persona, but it wouldn't be you as a frontend or application developer. What we started to notice is that with platforms like Cloudflare becoming dominant, you have now an application developer.
00:09:43 - Glauber Costa
They say, "Hey, I don't need to manage my whole backend anymore. I can just start firing those functions," which is great. But then the next step is that this person now is so much closer to the database decision that they might as well start making the database decisions. And we're seeing this more and more: those people are application developers making some of the database decisions, not all. On top of that, Cloudflare has this edge story. And obviously there are other players, but we do consider Cloudflare to be the main player here. They have this edge story where your compute is going everywhere.
00:10:22 - Anthony Campolo
Yeah, yeah. The data part is the hard part. What everyone's trying to figure out right now,
00:10:27 - Glauber Costa
which is eventually what we're trying to do. So you have this idea that this is a different persona, and there is a different characteristic in this market, which is that this thing really needs to be at the edge. And again, we have had this thesis from day one, which is why I still talk about it. And that didn't change. And this is the part where you're all allowed to laugh at me. And starting with... get ready... we thought, like, imagine... I always think of that meme of that guy carrying the skateboard: "Hey, kids."
00:10:57 - Anthony Campolo
Hello, fellow kids.
00:10:58 - Glauber Costa
Hello, fellow kids. Because it's a bunch of low-level kernel nerds.
00:11:04 - Anthony Campolo
Hello, fellow database developers.
00:11:06 - Glauber Costa
Hello, fellow frontend developers. So our initial approach of ChiselStrike was a little bit like that: how about I give you a database? Because you're a frontend developer, you probably don't like SQL because you're telling me you hate databases, right? Because you don't understand... I'm a frontend developer.
00:11:21 - Anthony Campolo
I'm using Prisma. I'm not writing any SQL.
00:11:23 - Glauber Costa
Oh yeah, but Prisma is still SQL
00:11:25 - Anthony Campolo
in a sense that, I mean, it's an ORM. So it's like... you can write raw SQL. Most people aren't writing a SQL query.
00:11:34 - Glauber Costa
In my defense, we knew that, for example, people like ORMs and people don't like databases from the application world. And look, it's not that I like databases. As I said, they're...
00:11:48 - Anthony Campolo
That you need a database. No one wants a database. They need a database.
00:11:52 - Glauber Costa
Not even I like databases. But what we thought is: what if we get a database and an ORM bundled together, and we build this thing around SQLite as well? To the extent that instead of doing SQL, you have a layer on top of that where you can essentially do TypeScript. So we found a way to put Deno and SQLite together, and this is now your compute and data, and you can just program your database. You start from TypeScript types, something similar to what Drizzle is doing. For example, we didn't have a code generation step. You define your database types in TypeScript. We do all the migrations automatically.
00:12:35 - Anthony Campolo
You get end-to-end type safety. If you're using TypeScript on the frontend, then you get nice autocomplete and all that stuff.
00:12:41 - Glauber Costa
It got some interest, but never the amount of traction that we would have liked. And moreover, every time we went to talk to my fellow frontend developers, what I kept hearing was that this is cool. Nobody ever told us this is not cool. But I kind of like to have a SQL layer that is well defined. And moreover, even the platform that we focused on most of the time, which was Cloudflare, gave us a lot of trouble integrating because people would ask us, "Okay, so how do I deploy this on Cloudflare?" And I would have to explain to them, no, you don't deploy this on Cloudflare because, again, we have our own runtime.
00:13:19 - Anthony Campolo
Yeah. So let's get into SQLite here because Cloudflare now does have a SQLite kind of thing and a lot of companies are trying to figure out how to put SQLite on the edge. So let's hone into that and be like, why SQLite?
00:13:35 - Glauber Costa
But just to finish this: we were always talking to those folks, and they would say, "This is cool and all, but I don't like this, I don't like that. But the SQLite stuff you guys are doing is pretty cool," right? So we started noticing that the interest was around that. And funny enough, we were actually not doing it that much because we were really focusing on the API. We were like, we're gonna figure out the data distribution later, right? And then this later never came because we were so focused on getting the API right. And at some point we just decided, look, let's put a product out. Let's sit down together, spend a couple of months with the whole company focused together, put out a product that is just the database layer, remove the API stuff, and see what happens. It was extremely successful.
00:14:23 - Anthony Campolo
Right.
00:14:23 - Glauber Costa
So that's why. And essentially it's a story very similar to the story that I had in Scylla. You try something, you have some usage, it doesn't quite work, but
00:14:33 - Anthony Campolo
you see what happens.
00:14:34 - Glauber Costa
Out of that comes something, right, that you really want to sell. You always want to sell everything, but the question is: do people want to buy?
00:14:42 - Anthony Campolo
Yeah.
00:14:43 - Glauber Costa
But now to your question: why SQLite? And just a clarification, what we run is not actually SQLite. This is something that lots of people don't know, but SQLite is a technically open source project, a spiritually open source project, but not technically, because it's actually public domain. That's a technicality, but they're not licensed under any open source license. The code is just public domain. It doesn't have a copyright.
00:15:12 - Anthony Campolo
That sounds way better.
00:15:14 - Glauber Costa
It is in some senses way better. From your usage point of view it's way better. But they're not open to contributions.
00:15:24 - Anthony Campolo
Right. And this is an important point: just because everyone can see the code doesn't mean anyone is allowed to actually make a change to the code.
00:15:31 - Glauber Costa
And they say it on their website: this is not open contribution. And we were seeing all of those companies, as you said, looking at SQLite for the edge. We were not the only ones, by and large. And they're all dancing around the fact that, hey, I wish I could change SQLite to make it do...
00:15:47 - Anthony Campolo
So people wanted to be able to kind of fork it and do whatever they want with it.
00:15:50 - Glauber Costa
But I don't want to fork it
00:15:51 - Anthony Campolo
because it's like a... yeah, because then you lose your upstream. Yeah, I forgot how to say it, whatever.
00:15:57 - Glauber Costa
And so I'm going to build something around it. That's what everybody was doing. I think we're just crazy. I don't know. We just said, let's just fork this thing.
00:16:07 - Anthony Campolo
And as I said, you did fork it?
00:16:08 - Glauber Costa
I did fork it.
00:16:09 - Anthony Campolo
Okay, cool.
00:16:09 - Glauber Costa
So what we're running...
00:16:11 - Anthony Campolo
Did you give it a cool name when you forked it?
00:16:12 - Glauber Costa
libSQL.
00:16:13 - Anthony Campolo
libSQL.
00:16:14 - Glauber Costa
So if you go to our website, we are telling people that, yeah, this is SQLite. The delta between those two things is very small. It will grow over time, I believe. We're still back-merging from SQLite. We want to keep libSQL close. Also, again, compared to Linux, it's a very small codebase.
00:16:35 - Anthony Campolo
I mean, anything compared to Linux, it's
00:16:37 - Glauber Costa
going to be simpler, but SQLite is relatively simple. So it felt feasible. And I personally don't like forks. The reason I don't like forks is that in Linux, soft forks were very well received. Like, let me fork this stuff and go explore this stuff.
00:16:54 - Anthony Campolo
It's like a distro.
00:16:55 - Glauber Costa
Yeah, but hard forks were not. And the reason for that is that it fragments the community.
00:17:00 - Anthony Campolo
Right. And then you end up with different people working on similar things.
00:17:02 - Glauber Costa
[crosstalk]
00:17:03 - Anthony Campolo
You rebuild stuff a million times.
00:17:04 - Glauber Costa
But there is no community with SQLite of developers. When I say community here, I mean developers.
00:17:09 - Anthony Campolo
Which is so interesting because it's allegedly what I've heard, the most used database in the world.
00:17:13 - Glauber Costa
It is, yes.
00:17:14 - Anthony Campolo
Yeah. And that's kind of incredible.
00:17:15 - Glauber Costa
But then again, this is why the public domain thing gets tricky because, again, this is according to the website, one of the reasons they're not open to contributions is to make sure that they're public domain. Because if you take a contribution from somebody else, then you need a license. It's harder. That's what open source licenses are designed to do. Here's this license, right? So they can use...
00:17:40 - Anthony Campolo
I have lots of thoughts on open source licenses.
00:17:43 - Glauber Costa
They can use the code, etcetera. And we just forked it and then we added a bunch of functionality that we believe is important for the edge. One of them is a much easier and more robust way to tap into the stream of changes of SQLite called the write-ahead log. And we built a distributed service around it. And to finally answer your question, I did warn you that I talk a lot, right? To finally answer your question, why SQLite? Be it our fork or SQLite or whatnot, people keep asking me: what is the difference between the cloud and the edge?
00:18:20 - Anthony Campolo
Yeah, there's a whole discussion right now, honestly, about edge. It's complicated.
00:18:26 - Glauber Costa
It's fair, right? I think as a community, as an industry, we're used to people just tossing out buzzwords out there.
00:18:35 - Anthony Campolo
Yeah.
00:18:35 - Glauber Costa
So it is a fair concern. But I do view the edge and the cloud as very different.
00:18:40 - Anthony Campolo
And the way I would... before you say that, I would say the cloud is someone else running your server. The edge is someone else running your server all across the world close to the users.
00:18:52 - Glauber Costa
Well, I think it's part of that. It's not only that you're running the service. The analogy that I like to use is that when you moved from private data centers to the cloud, it was not only who runs it and who owns it that changed. It was the fact that an abstraction layer around provisioning servers changed so radically that it enabled different use cases. And in the case of the cloud, it's the fact that I could commission a service and wait a week, versus now in the cloud I can commission a service and wait five minutes. Right? So this changes the way you build your applications. And what I see with the edge is that I could go on AWS and build a service in five different regions, but I have to be very aware of the fact that I'm doing this.
00:19:46 - Anthony Campolo
Yeah, you've got to click around, right? Pick your region. Then if you build it in one and you want to tear it down in another, you've got to go back.
00:19:54 - Glauber Costa
And the application has to be very aware of the fact that this is happening. So this awareness disappears with the edge, because what the edge enables you to do is write an application that's truly global and you don't care as the application writer where it's going to happen. So it's not just the fact that the servers are now spread around. It is the fact that you have this abstraction layer that removes this concern from your mind. And the second thing, which is a result of that to some extent, is that if you really want to put servers in all of those locations, you can put AWS US-East-1 in 100 places. It's a data center. So you build this abstraction layer and then you put 100 massive data centers on top. How much is this going to cost? It costs a lot. So the reason people don't put 100 big data centers out there is not because it's not technically possible. It's because it's not economically feasible. So the edge has fewer resources available to you. And SQLite is the database that really allows you to use those resources in the best way.
00:21:06 - Glauber Costa
It is a cheap database to run. It is a very efficient database to run. I mean, we'll get into more details about Turso and our offering hopefully soon, but with the limits that we're going to put on the website, which is around 10 billion rows read per month, I can run you in 34 locations for less than $200. So if you want to put MySQL in 34 locations, it's going to cost you a little bit more than $200. And again, why is that? Because we can run this with a very efficient memory footprint. We can use this in very efficient compute substrates. So it's very efficient to run, and everybody kind of knew that, which is why I believe everybody was chasing the thing about, hey, SQLite. And again, I think what we did differently is that we just forked it. Our fork, by the way, is fully open contribution. We don't want to be the only company and group contributing to that. We actually are welcoming...
00:22:07 - Anthony Campolo
Are there other companies that are using it?
00:22:09 - Glauber Costa
There is another company that is finishing their contribution to enable CRDTs in libSQL natively, which I love, which is something that soon, hopefully, we're going to be able to even offer... we haven't really figured that out yet. CRDTs, for those who don't know, is essentially conflict... I always forget. Conflict-free replicated data types. What that allows you to do is something in between eventual consistency and...
00:22:38 - Anthony Campolo
All I know is it's the thing that makes something like Google Docs work.
00:22:41 - Glauber Costa
Yeah, you could use CRDTs for that. And it's a little bit stronger than eventual consistency, but not as strong in terms of consistency as a fully consistent SQL database. And again, this is fairly interesting, I think, for the edge. This company is not affiliated with us. They've been contributing things to that. We have other things that we contributed ourselves, let's say, to kickstart the community. They're not immediately useful for Turso, although they might be one day. For example, you can write WebAssembly user-defined functions in our fork of SQLite, which I believe is quite interesting as well. But we just forked it and we built a service around it. That service keeps the same developer experience as SQLite. And what that means is that you can develop everything locally, you can test your database locally, you can put your database in your CI with local database files. And to do that, you just write in your client connection file, colon, and the name of the file. But then if you go to the same client and do HTTPS and then the address of your Turso database, now you're deployed at the edge, and we do all the routing for you as well.
00:23:52 - Glauber Costa
Which is again really relying on what I believe to be the defining characteristic of the edge. You replicate it in all of those locations, but your client doesn't have to choose the location. If you're running on Cloudflare, from your Workers you're going to fire a request to a single URL, a Turso URL, and we will figure out what replica is closest to you. And then you can create more replicas, ad hoc replicas. I mean, creating a replica is very
00:24:24 - Anthony Campolo
easy, and that's the core of the data-at-the-edge problem.
00:24:27 - Glauber Costa
We focus a lot on making the experience of bringing up a new location extremely easy. So you can say, well, let's say I want to be really efficient and spend as little money as possible, and I want to run five regions. But then I start noticing that there's a bunch of users coming from Japan, and I create a new location in Japan. It takes you a couple seconds, right? So this is how we're focusing on building this product because we really...
00:24:58 - Anthony Campolo
I'm going to pause you right here. Is Kent or Igor here?
00:25:01 - Glauber Costa
Yeah.
00:25:02 - Anthony Campolo
Awesome. Were we going to get you up here? I'm just thinking about time right now, so I just want to make sure I'm managing that correctly. It's gonna be a big guess-who's-who, right? I'll give this another five or ten minutes, then we can get you up here. Awesome. So you'll want to talk to the sound guys, make sure you get a headset and all that. Does anyone in the crowd have a question right now? If anyone wants to ask questions, we love to make this interactive, so feel free. Just throw your hand up and I'll call on you. Otherwise, we'll just keep rolling here. All right, cool. Great.
00:25:32 - Glauber Costa
Let's do it. So that's it. That's the offer. We have a booth right outside.
00:25:38 - Anthony Campolo
Awesome. So how would a developer get started if they wanted to build something right now? What's the best way to get started with Turso?
00:25:44 - Glauber Costa
The best way to get started, you go to turso.tech. It's T-U-R-S-O dot tech, and you're going to sign up with your GitHub account to our free tier. Our free tier is going to give you three locations already.
00:26:02 - Anthony Campolo
You don't like giving away your work for free?
00:26:04 - Glauber Costa
What? I'm not going to go there because I talk a lot, but essentially it's the same social media stuff. We have a free tier, which is different from saying our product is free, so I kind of tolerate that. But I don't like free products because it's not free.
00:26:18 - Anthony Campolo
Nothing's free. Nothing in life is free.
00:26:20 - Glauber Costa
So, I mean, you're selling yourself.
00:26:22 - Anthony Campolo
No free lunch.
00:26:23 - Glauber Costa
But again, a free tier is different. It's essentially a limited way for you to get acquainted with the platform. So by signing up and starting to use the free tier, our free tier is going to include 1 billion rows read a month.
00:26:49 - Anthony Campolo
I don't even know. These numbers are meaningless to me.
00:26:51 - Glauber Costa
But other databases like talking in the billions because it's a wow factor. And three locations. So again, for free from the start, we're already talking about something that you can run in the United States, in Europe, and in Asia, for example, with a free database.
00:27:12 - Anthony Campolo
Right.
00:27:13 - Glauber Costa
And hopefully around the month, we're going to have a plan for $29 a month that you can run from six locations with larger allowances as well.
00:27:25 - Anthony Campolo
Very cool.
00:27:25 - Glauber Costa
We have a Discord channel. I'm not going to...
00:27:27 - Anthony Campolo
Yeah, feel free. We're about to switch out here. But yeah, feel free to give any links or how people can find you or anything like that.
00:27:33 - Glauber Costa
Do I stay or do I go?
00:27:34 - Anthony Campolo
I mean, you can stay, yeah, if you want to participate for sure. But yeah, just go ahead and give some links about how to find it and then we'll transition to Igor.
00:27:42 - Glauber Costa
Awesome. Well, nice to see you, Igor.
00:27:46 - Anthony Campolo
Yeah. Hey, what's up, man?
00:27:47 - Glauber Costa
Hey.
00:27:48 - Anthony Campolo
I'm good.
00:27:49 - Igor Minar
Thanks for inviting me.
00:27:49 - Anthony Campolo
I'm not sure if your mic is on yet. Go ahead and just give him a little check, check.
00:27:54 - Igor Minar
Hello.
00:27:54 - Anthony Campolo
There we go. Okay, yeah, sounds good. So yeah, feel free to introduce yourself and let our audience know who you are and what you do.
00:28:01 - Igor Minar
Cool, thanks for having me. So my name is Igor. I'm with Cloudflare and I do web stuff.
00:28:11 - Anthony Campolo
I think we all do web stuff here.
00:28:12 - Igor Minar
We do. All of us do web stuff here. In the past, I've done Angular for over a decade.
00:28:19 - Anthony Campolo
I wrote my first line of Angular code just a month ago actually. But do you know Brandon Roberts? Yeah, yeah, of course, yeah. Oh my God. Everyone knows Brandon if you're into Angular.
00:28:28 - Igor Minar
Yeah, he's awesome.
00:28:30 - Anthony Campolo
Analog. Yeah, Analog.
00:28:32 - Igor Minar
We need more, more of like projects like Analog.
00:28:35 - Anthony Campolo
I'm hyped on Analog.
00:28:36 - Igor Minar
Yeah. So I spent more than a decade at Google working on the frontend infrastructure, Angular and other things. And about a year and a half ago, I joined Cloudflare to refocus a little more. Not necessarily abandon the client side, but expand it to the server side and combine the two together. Because I definitely started to see that we're exhausting the possibilities on the client side, and there was so much to be gained by uniting the client side and server side in a way that hadn't been done before. And it was edge computing that enabled it. And Cloudflare is one of the really cool companies in that space, even though it's not so well known for edge computing.
00:29:25 - Anthony Campolo
I mean, I would disagree. I would say that Cloudflare Workers is how the vast majority of people are introduced to the idea of edge functions.
00:29:32 - Igor Minar
I'm surprised to hear that, and I will agree with him. Okay, cool. I think there are people in the community that are aware of Workers and Cloudflare Workers and edge computing, but it's definitely not the mainstream understanding today. Interesting. But I think that's about to change.
00:29:52 - Anthony Campolo
So what do you do specifically? Are you on a specific team on Cloudflare or a specific product?
00:29:56 - Igor Minar
I work on the developer platform team. So I'm with my colleague Nivi here, and together we work on anything developer related.
00:30:09 - Anthony Campolo
So like, do you interface with like pages or something like that?
00:30:12 - Igor Minar
Yes, pages fall into my purview.
00:30:15 - Anthony Campolo
Cool. I've got to sign on. Pages.
00:30:18 - Igor Minar
Yeah, yeah. So Pages, Workers, D1, R2, Wrangler...
00:30:24 - Anthony Campolo
D1 being a Turso competitor, technically.
00:30:27 - Glauber Costa
We're friends. We're friends.
00:30:29 - Anthony Campolo
No, I think it's SQL on the edge, like by definition it's kind of like...
00:30:33 - Igor Minar
You can say that it's a competition. Yes, I think it's right to say it's a competition, but we don't see...
00:30:39 - Anthony Campolo
And I mean competitor in an animosity way. You know, just that you're building a similar thing that could solve a similar problem.
00:30:45 - Glauber Costa
Actually, we're fighting after this. Selling tickets, covering ourselves with mud, and we're just going to...
00:30:53 - Igor Minar
The reason why we are doing D1, the main motivation here is we want to build awesome primitives, low level primitives that make something like D1 possible. And the best way to do that is actually to try to build a higher level product and then derive what the primitives should be. And our goal is to actually expose the primitives to everybody so that anybody can build something like D1 on top of the primitives. Because the thing that we have that is very unique to us is this infrastructure that is global that we've been building over 13 years. We have over 275 data centers around the world with a lot of capacity, both in terms of CPU memory as well as bandwidth. We have so much bandwidth that we give away a lot of it for free. We built R2, which is a clone of S3.
00:31:48 - Anthony Campolo
Yeah, I've got a R2 blog post
00:31:50 - Igor Minar
in the works right now because we don't need to charge people for egress. We have so much bandwidth, we can
00:31:55 - Glauber Costa
just give it away.
00:31:58 - Igor Minar
We want people to come and build on top of us and either build applications, like use Remix and deploy directly to us, or we're looking for partners that are interested in building their solutions, like Turso or others, on top of the primitives that we offer.
00:32:16 - Anthony Campolo
So I'd be curious then: he was talking about SQL and SQLite and how it's this weird kind of open source, community-managed gray area type thing. So have you had to deal with that as well?
00:32:29 - Igor Minar
A little bit. But actually I didn't know about this fork, so this whole discussion is very interesting.
00:32:34 - Glauber Costa
Matt knew. He should have told you.
00:32:38 - Igor Minar
I'm not deeply involved in the D1 project. I'm helping with the DX and some of the integrations, but not necessarily with the implementation. So that is not my area of expertise. But I'm glad to hear that there is a fork that welcomes open source contributions. I spent over a decade on Angular, and it was always open to contributions. We built Angular with the community, for the community. It was not a Google project. We just were secretly...
00:33:10 - Anthony Campolo
It's not dead yet, so it couldn't have been.
00:33:12 - Igor Minar
Yeah. So that's the true open source. That's how you do open source. It does take extra energy, but it makes the project more resilient.
00:33:22 - Anthony Campolo
So what are you working on right now in Cloudflare that you're excited about and you want people to know about?
00:33:28 - Igor Minar
Oh my gosh, so much. How many beans can I spill? All the beans.
00:33:36 - Anthony Campolo
This is the bean spilling arena.
00:33:38 - Igor Minar
When is this going to be released, this recording? We have a big announcement, a week full of announcements, coming up starting Sunday.
00:33:48 - Anthony Campolo
Okay. It'll be after that.
00:33:49 - Igor Minar
Okay. So on Sunday we'll be announcing lots of things.
00:33:52 - Anthony Campolo
Lots of you guys are getting the hot gossip right now.
00:33:55 - Igor Minar
One of the cool things that we announced today, pre-announced today, was smart placement.
00:34:00 - Anthony Campolo
Smart what?
00:34:01 - Igor Minar
Smart placement. Okay, so Nivi and I, my colleague, we gave a presentation here at Remix about edge. What is edge? What is it good for?
00:34:15 - Anthony Campolo
And just real quick, I work at a company called Edgio. We do a lot of Edge stuff. So I give a quick plug.
00:34:23 - Igor Minar
What is it good for? How do you use it, and when should you not use it?
00:34:28 - Anthony Campolo
Right, yeah. And that's the big question because there's this push to edge everything, and that might not necessarily be the right thing to do.
00:34:37 - Igor Minar
Sometimes it's a terrible idea, right?
00:34:39 - Anthony Campolo
Yeah.
00:34:40 - Igor Minar
If you foolishly go and just follow buzzwords and just be like, let's do edge for the sake of edge, it might not end up well. And one of the solutions is actually Remix use cases. When you have an application like Remix and you want to do server-side rendering, then if you deploy it to the edge, the server-side rendering happening at the edge may or may not be a good idea. And it depends on where your data lives.
00:35:07 - Glauber Costa
Well, with Turso it lives close to you.
00:35:09 - Igor Minar
Well, so that's what I'm saying. It depends on where your data lives. Most applications today, most companies, have centralized data stores, right? They might live in AWS or GCP, but it's pretty much locked into one location. In the worst case, it's on-premise in some closet that you manage. Too many companies have that situation. So you have data in one location if server-side rendering is happening at the edge. Now imagine the situation where you have your Remix application deployed to the edge, your database is in US East, and your user is in India. You provision the compute in India, you load the Remix application, the Remix application wakes up, and the Remix application starts talking to the database in US East. And it doesn't take one database request to render a Remix application. It's many of them, depending on the complexity of the application. So now you're paying for the latency from the edge to US East over and over for every single Remix request.
00:36:13 - Anthony Campolo
The most important thing is understanding where these bottlenecks actually come in, what the bottleneck is, and how you manage it.
00:36:19 - Igor Minar
So if you foolishly run to the edge and deploy your Remix application on the edge while your data is centralized, your application may work great if you as a user are near the data, because then the compute is provisioned near you, which then happens to be near the data. But if you as a user are far away from the data, then the compute is provisioned near you, but that compute needs to talk to the database far, far away. And that results in lots of bottlenecks and bad performance.
00:36:51 - Glauber Costa
Even though my product is designed to address exactly this question, I fully agree with that.
00:36:55 - Igor Minar
So you have two options, basically. Either bring data to the edge, which is what Turso's doing. Turso is a way to bring data to the edge. It's great for some use cases, it's great for greenfield projects, it's great if you can quickly migrate to this kind of different, slightly different data model. But some companies just have ginormous databases
00:37:21 - Glauber Costa
And database sales cycles are sometimes things that take years.
00:37:25 - Igor Minar
Yeah, they're locked into their Oracle whatever agreement, license, they bought for the next five years. So for the next five years they'll have this database that they already paid for, and there's almost no way that they'll abandon it because it would just not make sense. So you either bring data to the edge or you slightly abandon the edge and move the compute closer to data. And that's the thing we talked about today in our talk, and what we refer to as smart placement.
00:37:58 - Anthony Campolo
So with Cloudflare, just real quick, we're going to be closing out in the next five, 10 minutes, so people do have questions. Now would be the time. So feel free to raise your hand if you got one. Cool.
00:38:10 - Igor Minar
So Cloudflare, for the longest time, was edge computing really just happening at the edge. We had a few products, like durable objects, where the compute was necessarily at the edge. But with the feature that... and it's really a feature that we are announcing... all the existing applications that you're deploying to Cloudflare today, whether it's Workers or Pages, you can opt into this smart placement mode. And rather than that compute being always provisioned at the edge, we will start monitoring the application, watch it for a few requests, and then we'll see, oh, this is a Remix application. It's talking to this database in US East. Let's always place it, or rather instantiate it, in US East near the database, regardless of where the user is entering. So if the user is in India, they will enter the Cloudflare network in India in the nearest data center that we own there, and then we'll create this magic tunnel all the way to US East where we'll spawn the application. The application will talk to the database very quickly, will generate the response, and the response is then relayed back to India. But this only happens for server-side rendering.
00:39:24 - Igor Minar
If you're doing static asset hosting, that still happens at the edge, because edge for static asset hosting is the best place to host it. So depending on the use cases, this is why it's called smart, because we observe and determine...
00:39:39 - Anthony Campolo
You decide? The developer doesn't have to.
00:39:42 - Igor Minar
Exactly. So the developer doesn't need to think about regions.
00:39:45 - Glauber Costa
I don't think you're bending the edge because in the definition that I gave about the edge, that's exactly what it is. The fact that you can now write this global application without you worrying about this stuff, because the platform does it for you.
00:39:56 - Igor Minar
Yeah, this is where edge is a cool buzzword because nobody can agree on what the heck it is.
00:40:03 - Anthony Campolo
Yeah, it's a little bit of a cluster trying to figure out what all these buzz terms mean. Well, thank you so much. I'm really glad we got to have this conversation with both of you because you're working on such compatible tech. So before we close it out, let everyone know: where can they find you on the socials? Start with Glauber.
00:40:21 - Glauber Costa
I am on Twitter @glcst. That's my handle. And also follow Turso Database.
00:40:28 - Anthony Campolo
All right. And Igor?
00:40:30 - Igor Minar
You can just go to igor.dev, I-G-O-R, igor.dev.
00:40:34 - Anthony Campolo
That's a sweet domain.
00:40:38 - Igor Minar
So, yeah, easy.
00:40:40 - Anthony Campolo
Cool. And thank you so much, everyone who was here to watch this. This is super fun. And thank you to Remix Conf for hosting us. And this is going to close out for us, so thank you very much.
00:40:51 - Igor Minar
Thank you.
00:40:55 - Glauber Costa
Thanks a lot.