Uploaded image for project: 'Ansible Automation Platform RFEs'
  1. Ansible Automation Platform RFEs
  2. AAPRFE-2143

RFE - New Azure Inventory Plugin Using Resource Graph and KQL for Improved Performance in Environments with hundreds of subscriptions

XMLWordPrintable

    • False
    • Hide

      None

      Show
      None
    • False

      • What is the nature and description of the request?{}

      We request the development of a new inventory plugin or an enhancement to the existing azure_rm_inventory plugin within the azure.azcollection Ansible Certified Collection. This plugin should leverage Azure Resource Graph (ARG) and Kusto Query Language (KQL) to retrieve virtual machine data (or other inventory data) more efficiently across large Azure environments.
      Currently, when customers use hundreds of subscriptions to retrieve their inventories, the use of the azure_rm inventory plugin results in hundreds of sequential API calls. This significantly delays inventory synchronization, often taking 3–4 hours to complete.
      The proposed plugin would use a single or minimal number of KQL queries via the ARG API to fetch metadata about Azure VMs. It would generate a structured Ansible inventory with use of group_vars and host_vars, reflecting, at minimum, the same data produced by the existing inventory plugin, including attributes such as: 

      1. OS type and version 
      2. Azure region
      3. Power state
      4. AAP_Managed and other custom tags
      5. Ansible connectivity method

      This new plugin is intended to complement, not replace, the existing azure_rm plugin.

       

      • Why does the customer need this? (List the business requirements here)

       

      1. Performance: Inventory syncs currently take several hours due to the volume of sequential API calls required by azure_rm in multi-subscription environments.
      1. Supportability: The customer has implemented an external Python script using ARG + KQL to work around the performance limitations, but these are not officially supported by Red Hat or Microsoft.
      2. Unified Experience: Customers are requesting a native, supported plugin that integrates directly into Ansible workflows and eliminates the need for external tooling or manual inventory generation.

       

      • How would you like to achieve this? (List the functional requirements here)

       

      1. A new inventory plugin in azure.azcollection that:
      1. Uses ClientSecretCredential or a comparable supported authentication mechanism.
      1. Executes a configurable KQL query through Azure Resource Graph.
      1. Outputs an Ansible-compatible inventory in YAML or JSON.
      1. Dynamically generates group_vars and host_vars.
      1. Supports filtering (e.g., by subscription name, region, or tags).
      1. Must function alongside the current azure_rm plugin.
      2. The python script and KQL filter currently used by the customer can be made available for reference. Please keep in mind the way the script uses group_vars and host_vars can be improved.

       

      • List any affected known dependencies: Doc, UI etc..

       

      • azure.azcollection
      • Documentation

       

      • Github Link if any{}

      N/A

              stevefulme1 Stephen Fulmer
              rhn-support-dleroux Daniel Leroux
              Votes:
              1 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated: