Postgres עם 100% CPU עבור מסדי נתונים גדולים, Discourse 2.7.7

This query seems to come from Jobs::BadgeGrant.