Actions
Bug #16576
closedStructured facts importer is extremely slow
Description
After upgrading to 1.13.0-RC1, our Foreman server consumed all available resources and became effectively unusable with response times of 25k to 175k ms. This seems directly related to the changes made in #4528, as Api::V2::HostsController#facts is where the application spends 99% of its time after upgrade according to NewRelic.
Updated by Brandon Weeks about 8 years ago
This was mostly caused by a massive numbers of orphaned rows in the fact_names table. Here is a SQL query that removes any fact_names without corresponding values.
DELETE
FROM fact_names
WHERE fact_names.id NOT IN (SELECT DISTINCT fact_name_id FROM fact_values);
Updated by Dominic Cleal about 8 years ago
- Translation missing: en.field_release set to 160
Updated by Dominic Cleal about 8 years ago
- Status changed from New to Assigned
- Assignee set to Dominic Cleal
Updated by Dominic Cleal about 8 years ago
- Related to Feature #4528: Support Facter 2 structured facts added
Updated by Dominic Cleal about 8 years ago
- Related to Feature #12163: Add ability to expire facts based on fact name. added
Updated by Lukas Zapletal about 8 years ago
- Related to Bug #9016: Fact import code consumes lot of memory added
Updated by Lukas Zapletal about 8 years ago
This patch #9016 fixes it, we are just finishing the review process. Could you try it and share some numbers?
Updated by The Foreman Bot about 8 years ago
- Status changed from Assigned to Ready For Testing
- Pull request https://github.com/theforeman/foreman/pull/3852 added
Updated by Dominic Cleal about 8 years ago
- Status changed from Ready For Testing to Closed
- % Done changed from 0 to 100
Applied in changeset e5381d3ff9001d9fe3ce8d0f90afeec591571e97.
Actions