Having a requirement to add a custom query to a specific DB instance to get metrics. The same server have other instances running on it. When we add the custom query to schema.json based on the documentation Viewing additional metrics of SQL Server, the custom query runs on other instances as well and it generates an error.
Is there a way we can make the extension to run the custom query on 1 specific instance ?
Please consider installing 2 instances of APMIA MSSQL agents as a possible workaround setup with one agent instance being configured to use this particular instance-specific custom query in its modified schema.json and the other agent instance being configured to use the more commonly shared query in the default schema.json.
The issue has been resolved by using separate schema files for individual instances as suggested above.