Kyle d'Oliveira
๐ค SpeakerAppearances Over Time
Podcast Appearances
I was just going to mention one thing about includes, because I think this is another gotcha of Rails, is they don't really teach you what happens with includes. And includes actually does two things in the background. It either uses a preload or an eager load.
I was just going to mention one thing about includes, because I think this is another gotcha of Rails, is they don't really teach you what happens with includes. And includes actually does two things in the background. It either uses a preload or an eager load.
And a preload splits it off into a different query entirely, where you do something like select star from table, where ID is in this big list. But then there's eager load, which tries to smoosh it into one big query. This is something where Rails always suggests using includes because it'll handle that distinction for you. But that distinction actually makes a difference at scale.
And a preload splits it off into a different query entirely, where you do something like select star from table, where ID is in this big list. But then there's eager load, which tries to smoosh it into one big query. This is something where Rails always suggests using includes because it'll handle that distinction for you. But that distinction actually makes a difference at scale.
And when you're dealing with large tables, eager load is almost always worse.
And when you're dealing with large tables, eager load is almost always worse.
significantly and so it's almost all the time you actually want to use preload same same interface but it's just this interesting little gotcha that you don't really realize until it starts biting you and you got to remember everything is just a tool and you can either smash your finger with that hammer or you can build what you want to build with it exactly right kyle well if people want to follow you and some of the stuff that you're doing online where should they go
significantly and so it's almost all the time you actually want to use preload same same interface but it's just this interesting little gotcha that you don't really realize until it starts biting you and you got to remember everything is just a tool and you can either smash your finger with that hammer or you can build what you want to build with it exactly right kyle well if people want to follow you and some of the stuff that you're doing online where should they go
I don't really have a huge online presence. I do have a GitHub account, but that's mostly working on either public gems for the company. But what I'm trying to do is be a little bit more present in the community. So I do have some talks available at RailsConf. And my goal is to be pushing out a little bit more written content, which is available at the blogs that Clio provides.
I don't really have a huge online presence. I do have a GitHub account, but that's mostly working on either public gems for the company. But what I'm trying to do is be a little bit more present in the community. So I do have some talks available at RailsConf. And my goal is to be pushing out a little bit more written content, which is available at the blogs that Clio provides.
So I can provide a link for that in the future, as well as a link to any of the talks that I have. Unfortunately, I'm not a super user on Twitter, but I can also provide my LinkedIn where I sometimes post new information there as well.
So I can provide a link for that in the future, as well as a link to any of the talks that I have. Unfortunately, I'm not a super user on Twitter, but I can also provide my LinkedIn where I sometimes post new information there as well.
I didn't prepare anything, so I actually don't have anything that's off the top of my mind here for things to just call out.
I didn't prepare anything, so I actually don't have anything that's off the top of my mind here for things to just call out.
I'm always happy to like building tools to fix these things so that we can make the community better.
I'm always happy to like building tools to fix these things so that we can make the community better.
Yeah, it was wonderful. Thank you.
Yeah, it was wonderful. Thank you.
Take care.
Take care.