Open 0xFelix opened 2 months ago
Thanks for your Ansible docs contribution! We talk about Ansible documentation on matrix at #docs:ansible.im and on libera IRC at #ansible-docs if you ever want to join us and chat about the docs! We meet there on Tuesdays (see the Ansible calendar) and welcome additions to our weekly agenda items - scroll down to find the upcoming agenda and add a comment to put something new on that agenda.
Hey @0xFelix - do you have details from your discussions that you can add here to the issue?
From discussion with @bcoca I gathered:
Adding more to the pile:
vars plugins
the same way, they were designed as a more direct way of doing this. The host_vars
/group_vars
vars loading, for example, is implemented via the host_group_vars
vars plugin but there are vars plugin that query APIs, just like inventories (still working on a way to avoid overlapping/reuse credentials across them).
After recent discussions I learned that if dynamic inventories cache their facts on a per host basis, then their cache can become interoperable with fact caching in Ansible.
Unfortunately this is nowhere documented and I couldn't find a single inventory that implements caching in this way. If I'm not mistaken, then all of the inventories included in the Ansible distribution only make use of source caching, to avoid load on the inventory's data source.
It would be great if more examples could be added to Developing dynamic inventory to show how caching can be made more efficient.