4
votes

I have a resource group with more then 15 function apps on windows azure. At the beggining I create one app insights for each function app. So if I want to know what´s going on I can go to a specific function app insights (or the monitor) and can see what´s going on. It works well but as these functions act as distributed message based services, sometimes it´s hard to know where the problem occurs. So I would like to know the best strategy recommended to deal with this situation.

1) Create a single application insights for all the functions?

2) Create some custom dashboard on azure monitor to track all theses application insights inside one dashboard (I tried to find how to do that but actually cannot find it)

1
Application Map is supposed to stitch together all distributed services into one picture (assuming they talk to each other). Does it work for you? Also, End-to-end Transaction Details also stitches the whole transaction through all components (no matter whether they report to on Application Insights or many).ZakiMa
Application Map, as I understand is to track external dependencies. And the relation is 1-1, as I have one application map for each application insights.gog
Application Map is opened for a particular Application Insights resource and shows all components in that resource. But it also pulls all other components from different resources if correlation (distributed tracing) works correctly. For Application Map it doesn't matter whether applications report data to the same Application Insights resource or different.ZakiMa
Based on 1-1 relation it sounds that correlation doesn't work (assuming your Azure Functions talk to each other). Which language do you use?ZakiMa
I understand your point, and you are right. But my problem is, some problem occurs on the distributed app and I need to quickly find the failure point in the application insights, but I have 15 functions, do I need to look one by one application map to detect the error?gog

1 Answers

4
votes

Best practice is to include all the resources in your process in a single App Insights instance. That should simplify tracking down issues.

If you do decide to stick with multiple instances, then mapping should help you track the system as a whole as ZakiMa mentioned. There is some basic troubleshooting in the documentation. Depending on how your system is configured, it may require a little manual dependency tracking.

Also if you decide to keep them separate, the Azure Monitor syntax for cross resource queries is

union withsource=SourceApp 
app('Contoso-app1').requests,  
app('Contoso-app2').requests, 
app('Contoso-app3').requests, 
app('Contoso-app4').requests, 
app('Contoso-app5').requests 
| parse SourceApp with * "('" applicationName "')" *