Search code examples
azureazure-data-factoryazure-application-insightsazure-log-analyticsazure-monitoring

Get data in Azure App Insights from custom tables in Azure Log Analytics


I know that App Insights stores its data in a Log Analytics Workspace where it creates some specific tables. The charts and log tables visible in App Insights pull the data from those specific tables. I just wanted to know if it is also possible to view data in App Insights from other tables in the Log Analytics.

My use case is that we have a bunch of resources that are using App Insights for logging. But Azure Data Factory only supports Log Analytics for logging, so we wanted to find a way to get all the info in one place. Obviously the better approach would be to just use Log Analytics for all, and we might start doing that, but if there is some way then a lot of re-configuration could be avoided.

I have already searched a lot on this, and what I've gathered is that this is not possible. Having said that, I haven't actually seen this specifically mentioned anywhere, neither in Microsoft docs nor in any forum. So I just wanted a final concrete statement on this, hence my question.


Solution

  • It depends on what you mean with

    [..] to view data in App Insights from other tables in the Log Analytics. [..]

    Azure Monitor & Application Insights support workbooks with lots of features like:

    • Combine data from several different sources within a single report. You can create composite resource views or joins across resources to gain richer data and insights that would otherwise be impossible. (source)

    You can visualize data from all tables in Application Insights and the Log Analytic Workspace. You can also write cross resource Kusto queries. For example:

    let AiRequests = app("/subscriptions/xxx/resourceGroups/rg-xxx/providers/microsoft.insights/components/gba-insights").requests 
    | project Time = timestamp, Name = name, Url = url;
    let wsRequests = workspace("xxx-xxx-xx-xxx-xxx").AppRequests 
    | project Time = TimeGenerated, Name, Url;
    union wsRequests, AiRequests
    | order by Time desc 
    

    shows request from both Application Insights and Log Analytics Workspace in one result set.