From 1f07924cd2f619d0c0b3c0bf21e3d9cd5a1541b7 Mon Sep 17 00:00:00 2001 From: Bjoern Teipel Date: Mon, 21 Sep 2015 12:50:31 -0500 Subject: [PATCH] Implement fact caching Fact caching will improve general Ansible performance by default. This has the biggest performance gain on very large environments. This implementation will use the JSONfile configuration because it has no new dependencies and will provide a similar performance gain as noted through the use of Redis. Notes: * The facts can purged or read by interacting with the default JSON file. * The caching behavior can be turned off by removing the parameter fact_caching from the playbook/ansible.cfg file. DocImpact UpgradeImpact Co-Authored-By: Kevin Carter Implements: blueprint build-facts-archive Closes-Bug: 1498111 Change-Id: I95ab1c2f8567d6af68feb53d7c14b8997eef5c89 --- playbooks/ansible.cfg | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/playbooks/ansible.cfg b/playbooks/ansible.cfg index 9487a90afd..50c93114a9 100644 --- a/playbooks/ansible.cfg +++ b/playbooks/ansible.cfg @@ -5,6 +5,12 @@ filter_plugins = plugins/filters action_plugins = plugins/actions gathering = smart + +# Fact caching +fact_caching = jsonfile +fact_caching_connection = /etc/openstack_deploy/ansible_facts +fact_caching_timeout = 86400 + hostfile = inventory host_key_checking = False