• Tan Le's avatar
    Avoid N+1 queries when fetching author name · e1b22cc5
    Tan Le authored
    For audit event view, we need to fetch author and the associated
    name, and this results in unnecessary extra SQL calls. This change
    introduces `BatchLoader` to lazily load associated authors and speeds up
    audit events queries via both web application and API.
    e1b22cc5
preloader_spec.rb 1.08 KB