4 ms·
Have you ever heard the concept of the common antipattern of n+1 queries that the back-end developers try to avoid? What you are suggesting would create that pa
by yxhuvud 7y ago
Have you ever heard the concept of the common antipattern of n+1 queries that the back-end developers try to avoid? What you are suggesting would create that pattern on the front-end too.
- felixfbecker 7y agoThe backend can batch deletes made in the same timeframe in the same HTTP/2 session, like how you can batch queries with Facebook Dataloader in GraphQL APIs to avoid the n+1 query problem.
- treve 7y agoYes, I understand the concept. I totally get that certain situations call for batching operations, including things that need to work transactional. I think though that most operations don't need this. It's not an optimization I would blindly add to any operation, unless there's a specific case that warrants it. I don't think that this is an anti-pattern. Most APIs do '1 thing at a time'.