According to OOPS-1812QS3, this query is taking 3.5 seconds, but it's the next 8 seconds spent in python where the timeout occurs.
SELECT BugTask.assignee, BugTask.bug, BugTask.bugwatch, BugTask.date_assigned, BugTask.date_closed, BugTask.date_confirmed, BugTask.date_fix_committed, BugTask.date_fix_released, BugTask.date_incomplete, BugTask.date_inprogress, BugTask.date_left_closed, BugTask.date_left_new, BugTask.date_triaged, BugTask.datecreated, BugTask.distribution, BugTask.distroseries, BugTask.id, BugTask.importance, BugTask.milestone, BugTask.owner, BugTask.product, BugTask.productseries, BugTask.sourcepackagename, BugTask.status, BugTask.statusexplanation, BugTask.targetnamecache, Bug.date_last_message, Bug.date_last_updated, Bug.date_made_private, Bug.datecreated, Bug.description, Bug.duplicateof, Bug.heat, Bug.heat_last_updated, Bug.id, Bug.latest_patch_uploaded, Bug.message_count, Bug.name, Bug.number_of_duplicates, Bug.owner, Bug.private, Bug.security_related, Bug.title, Bug.users_affected_count, Bug.users_unaffected_count, Bug.who_made_private, Product.answers_usage, Product.blueprints_usage, Product.owner, Product.translations_usage, Product.active, Product.autoupdate, Product.bug_reported_acknowledgement, Product.bug_reporting_guidelines, Product.bug_supervisor, Product.bugtracker, Product.date_next_suggest_packaging, Product.datecreated, Product.description, Product.development_focus, Product.displayname, Product.downloadurl, Product.driver, Product.enable_bug_expiration, Product.enable_bugfiling_duplicate_search, Product.freshmeatproject, Product.homepage_content, Product.homepageurl, Product.icon, Product.id, Product.lastdoap, Product.license_approved, Product.license_info, Product.reviewed, Product.logo, Product.max_bug_heat, Product.mugshot, Product.name, Product.official_answers, Product.official_blueprints, Product.official_malone, Product.official_rosetta, Product.private_bugs, Product.programminglang, Product.project, Product.registrant, Product.remote_product, Product.reviewer_whiteboard, Product.screenshotsurl, Product.security_contact, Product.sourceforgeproject, Product.summary, Product.title, Product.translation_focus, Product.translationgroup, Product.translationpermission, Product.wikiurl, SourcePackageName.id, SourcePackageName.name FROM BugTask LEFT JOIN BugTask AS ConjoinedMaster ON ConjoinedMaster.bug = BugTask.bug AND BugTask.distribution = %s AND ConjoinedMaster.distroseries = %s AND NOT (ConjoinedMaster.status IN (%s)) LEFT JOIN Bug ON BugTask.bug = Bug.id LEFT JOIN Product ON BugTask.product = Product.id LEFT JOIN SourcePackageName ON BugTask.sourcepackagename = SourcePackageName.id WHERE Bug.id = BugTask.bug AND BugTask.milestone = 12698 AND ConjoinedMaster.id IS NULL AND Bug.duplicateof is NULL AND (Bug.private = FALSE OR EXISTS ( SELECT BugSubscription.bug FROM BugSubscription, TeamParticipation WHERE TeamParticipation.person = 1363376 AND BugSubscription.person = TeamParticipation.team AND BugSubscription.bug = Bug.id )) ORDER BY BugTask.status, BugTask.importance DESC, BugTask.bug, BugTask.id;
According to OOPS-1812QS3, this query is taking 3.5 seconds, but it's the next 8 seconds spent in python where the timeout occurs.
SELECT BugTask.assignee, BugTask.bug, date_assigned, BugTask. date_closed, date_confirmed, BugTask. date_fix_ committed, BugTask. date_fix_ released, date_incomplete , BugTask. date_inprogress , BugTask. date_left_ closed, date_left_ new, BugTask. date_triaged, BugTask. datecreated, distribution, BugTask. distroseries, BugTask.id, BugTask.importance, productseries, sourcepackagena me, BugTask.status, BugTask. statusexplanati on, targetnamecache , Bug.date_ last_message, Bug.date_ last_updated, made_private, Bug.datecreated, Bug.description, Bug.duplicateof, last_updated, Bug.id, Bug.latest_ patch_uploaded, of_duplicates, Bug.owner, Bug.private, related, Bug.title, Bug.users_ affected_ count, unaffected_ count, Bug.who_ made_private, Product. answers_ usage, blueprints_ usage, Product.owner, Product. translations_ usage, bug_reported_ acknowledgement , bug_reporting_ guidelines, Product. bug_supervisor, Product.bugtracker, date_next_ suggest_ packaging, Product. datecreated, Product. description, development_ focus, Product. displayname, Product. downloadurl, enable_ bug_expiration, enable_ bugfiling_ duplicate_ search, Product. freshmeatprojec t, homepage_ content, Product. homepageurl, Product.icon, Product.id, license_ approved, Product. license_ info, max_bug_ heat, Product.mugshot, official_ answers, Product. official_ blueprints, official_ malone, Product. official_ rosetta, Product. private_ bugs, programminglang , Product.project, Product.registrant, remote_ product, Product. reviewer_ whiteboard, Product. screenshotsurl, security_ contact, Product. sourceforgeproj ect, Product.summary, translation_ focus, Product. translationgrou p, translationperm ission, Product.wikiurl, SourcePackageNa me.id, me.name distribution = %s AND
ConjoinedM aster.distroser ies = %s AND NOT (ConjoinedMaste r.status IN (%s)) sourcepackagena me = SourcePackageNa me.id on.person = 1363376 .person = TeamParticipati on.team
BugTask.bugwatch, BugTask.
BugTask.
BugTask.
BugTask.
BugTask.
BugTask.milestone, BugTask.owner, BugTask.product, BugTask.
BugTask.
BugTask.
Bug.date_
Bug.heat, Bug.heat_
Bug.message_count, Bug.name, Bug.number_
Bug.security_
Bug.users_
Product.
Product.active, Product.autoupdate, Product.
Product.
Product.
Product.
Product.driver, Product.
Product.
Product.
Product.lastdoap, Product.
Product.reviewed, Product.logo, Product.
Product.name, Product.
Product.
Product.
Product.
Product.
Product.title, Product.
Product.
SourcePackageNa
FROM BugTask
LEFT JOIN BugTask AS ConjoinedMaster
ON ConjoinedMaster.bug = BugTask.bug AND BugTask.
LEFT JOIN Bug ON BugTask.bug = Bug.id
LEFT JOIN Product ON BugTask.product = Product.id
LEFT JOIN SourcePackageName ON BugTask.
WHERE Bug.id = BugTask.bug
AND BugTask.milestone = 12698
AND ConjoinedMaster.id IS NULL
AND Bug.duplicateof is NULL
AND (Bug.private = FALSE
OR EXISTS (
SELECT BugSubscription.bug
FROM BugSubscription, TeamParticipation
WHERE TeamParticipati
AND BugSubscription
AND BugSubscription.bug = Bug.id
))
ORDER BY BugTask.status, BugTask.importance DESC, BugTask.bug, BugTask.id;