Skip to content

Feeds generate n+1 queries for related image content #47

@ckinsey

Description

@ckinsey
  • Django Wagtail Feeds version: 0.1.0
  • Python version: 3.6.5
  • Operating System: Mac OSX 10.14

Description

Extended feeds executen+1 queries to gather image content from StreamFields.

What I Did

Here's a traced transaction from our APM tool:

Screen_Shot_2019-04-08_at_3_34_19_PM

I'm not sure what tools Wagtail provides for prefetching associated images from RichTextBlocks in StreamFields, but for large feeds this can generate 100s or 1000s of database queries to render a single feed.

Happy to spend some time on this and see if I can find a fix, but wanted to make sure I wasn't missing some easily configurable thing like subclassing the feed object overriding a queryset or something.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions