jsonapi-suite / jsonapi_compliable

MIT License
20 stars 35 forks source link

N+1 Query with Bullet #143

Closed austinh closed 5 years ago

austinh commented 5 years ago

I am using https://github.com/flyerhzm/bullet to detect N+1 queries and anytime I use the JsonAPI Compliable resources with sideloading, it is "detecting" an N+1 query.

I believe this is because jsonapi_compliable eagerloads sideloaded assocations without using the .includes() method that bullet is trying to detect

Is there a way for this library to play nicely with bullet or other n+1 detectors - it's making our devs think we have N+1 queries when we dont.

richmolj commented 5 years ago

Sounds like a bullet issue, not sure if there's anything we can do here. But let me known if you figure something out!