What performance implications are there for eager vs lazy loading?
Loading
Type
Pros Cons
Eager Fewer queries, good for large data
sets
Loads everything even if not used
Lazy Loads only when needed Risk of N+1 queries, more
round-trips
Explicit Fine-grained control More code complexity
✅ Eager is best for performance when you know you'll need related data.
❌ Lazy can hurt performance unless used carefully (e.g., in UI apps).