[PDB-1812] Some tables (value_types at least) are never analyzed Created: 2015/07/17  Updated: 2015/12/30  Resolved: 2015/07/23

Status: Closed
Project: PuppetDB
Component/s: None
Affects Version/s: PDB 3.0.1
Fix Version/s: PDB 3.0.2

Type: Bug Priority: Normal
Reporter: Rob Browning Assignee: Unassigned
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Blocks
Template:
Story Points: 3
Sprint: PuppetDB 2015-07-29

 Description   

While investigating a report of very slow fact-paths responses we discovered that analyzing the value_types table provided a roughly 4x improvement for 10.5m facts and 629k fact_values. Further examination demonstrated that the table had never been analyzed. We believe this is because the autovacuum analyzer won't look at a table until it passes certain thresholds in both size and update/delete counts.

To fix that, we're planning to add code to run a vacuum analyze (or possibly just analyze) at startup whenever at least one migration fires. In addition we'll add a new dummy migration to make sure all existing tables are analyzed.



 Comments   
Comment by Rob Browning [ 2015/07/17 ]

I've shelved this for the moment while I work on PDB-1812. I've fixed various sync issues such that we're down to some intermittent but easily reproducible failures I found after shifting to a larger scale generative test (500, though it doesn't require quite that many).

Generated at Mon Aug 19 09:48:54 PDT 2019 using JIRA 7.7.1#77002-sha1:e75ca93d5574d9409c0630b81c894d9065296414.