1. 07 Feb, 2019 1 commit
  2. 10 Oct, 2018 5 commits
  3. 21 Dec, 2017 1 commit
  4. 07 Aug, 2017 1 commit
  5. 13 Jun, 2017 1 commit
  6. 06 Jun, 2017 6 commits
  7. 05 Jun, 2017 8 commits
    • Russell Mull's avatar
      (PDB-3518) More specific join for certname->reports · 65c7a936
      Russell Mull authored
      Previously, queries which cross certnames and reports via latest_report_id would
      sometimes get a degenerate query plan due to the presence of
      idx_certnames_latest_report_id. The planner was led to believe that this index
      made starting with a filtered version of the reports table and then joining that
      to certnames was a good plan; it is not.
      
      By adding an additional condition to the join which touches the certname table,
      we encourage the planner to deal directly with rows which include both report.id
      and certname.certname. The most direct way to do this is to scan down certnames
      and pull each latest_report using the main report id index. This is the plan it
      makes now, and it's a lot faster.
      65c7a936
    • Rob Browning's avatar
      (PDB-3541) Don't hang on unsupported database · a8559cfe
      Rob Browning authored
      Instead of calling System/exit, use the trapperkeeper shutdown service
      to shut down when an unsupported database is detected.  Previously pdb
      would just hang.
      
      One drawback to this approach is that it looks like the only way to
      get trapperkeeper to shut down and exit with a non-zero status is to
      throw an exception, and we'd prefer to avoid the backtrace since the
      problem has already been described in the log and on stderr.
      
      Hopefully trapperkeeper will add something more suitable, and then we
      can use it.
      a8559cfe
    • Nick Walker's avatar
      (PDB-3529) Fix latest-report test and add new test for old reports · 2fcfdc92
      Nick Walker authored
      Prior to this commit, the latest-report test was comparing
      end_time instead of producer timestamp which was incorrect.
      
      After this commit, the latest-report test compares producer timestamp
      and has a new test that ensures a report with an older timestamp than
      the current latest report will not overwrite the latest report.
      2fcfdc92
    • Nick Walker's avatar
      01db2684
    • Nick Walker's avatar
      (PDB-3529) Check latest_report_timestamp in one query · 3cda79aa
      Nick Walker authored
      Prior to this commit, we found the latest_report_timestamp in a
      select query and then compared it to the producer timestamp being
      processed in clojure.
      
      After this commit, we just submit an UPDATE query with a
      WHERE clause that will only update if the producer timestamp being
      processed is newer than the one already stored in the certnames
      table.
      3cda79aa
    • Nick Walker's avatar
      (PDB-3529) Check latest report on certnames instead of reports · 6c617ce3
      Nick Walker authored
      Prior to this commit, we calculated the latest report for a node
      by querying the reports table, sorting all the records, and grabbing
      the most recent report id.
      
      After this commit, we store the latest report timestamp in the
      certnames table with the report-id.  This allows us to compare
      each new report with the latest report timestamp as they come in
      and decide whether this report is the latest report or not without
      querying the reports table.
      6c617ce3
    • Russell Mull's avatar
      b5340b84
    • Russell Mull's avatar
      (PDB-3515) Add edges_certname_fkey constraint · 87afd6ff
      Russell Mull authored
      We had this before, but it was lost in a migration which rewrote the certnames
      table but neglected to restore all of the foreign key constraints. This adds a
      migration to recreate the constraint and clean up any orphaned data.
      87afd6ff
  8. 02 Jun, 2017 7 commits
  9. 01 Jun, 2017 2 commits
  10. 31 May, 2017 1 commit
  11. 30 May, 2017 2 commits
  12. 25 May, 2017 3 commits
  13. 17 May, 2017 2 commits