microsoft / ApplicationInsights-JS

Microsoft Application Insights SDK for JavaScript
MIT License
649 stars 240 forks source link

Linking together client ajax request target and API nodes on Application Insights map #894

Closed jdudleyie closed 5 years ago

jdudleyie commented 5 years ago

Hi,

I have started using the new v2 version of applicationinsights-js but I still see on my application map that the target node of my angular app's ajax calls is not linked together with my dotnet core API node to which the requests are being made. Is there something else I need to do?

In the picture, I expected the two nodes highlighted with a red square to be the same node on the map, as they are the same node in reality (my dotnet core API running in Kubernetes AKS on Azure).

image

LeopoldLerch commented 5 years ago

Have you enabled the CorrelationHeaders? And do you evaluete them on server side?

jdudleyie commented 5 years ago

I don't know what those are, I will do a search later on it. If you have any link to documentation on that it would be great, if it's not easy to find.

Thanks.

On Tue, 28 May 2019, 10:56 LeopoldLerch, notifications@github.com wrote:

Have you enabled the CorrelationHeaders? And do you evaluete them on server side?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/microsoft/ApplicationInsights-JS/issues/894?email_source=notifications&email_token=AA2U5YOFZIFIHKPT7J5BTE3PXT6TRA5CNFSM4HPXOTR2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODWLTKZY#issuecomment-496448871, or mute the thread https://github.com/notifications/unsubscribe-auth/AA2U5YNPTQ7IIFX2CTNARKTPXT6TRANCNFSM4HPXOTRQ .

markwolff commented 5 years ago

Can you check to see what the headers are in your outgoing requests to the service? Specifically the request-id header? https://docs.microsoft.com/en-us/azure/azure-monitor/app/correlation#correlation-headers

Also, could you view some telemetry in the Search blade between these 2 services and check if they share an Operation Id?

jdudleyie commented 5 years ago

I will check and let you know - thanks

jdudleyie commented 5 years ago

Hi,

I have attached a csv file which hopefully contains the relevant information. It's a snippet from Azure Log Analytics showing an Ajax request from my angular client, and then the resulting server call to Google API and to my DB. Can you please let me know if this contains the information you were looking for? Thanks.

It's a csv renamed to txt.

query_data.txt

jdudleyie commented 5 years ago

Hi @markwolff - I was just wondering if you had a chance to look at this? Thanks.

markwolff commented 5 years ago

I'm unable to see multiple telemetry items in your query data. Can you click on a sample Dependency or Request telemetry item which you expect to be correlated properly in the Search panel and paste a screenshot? When you click it to view the End-to-end transaction details, do you see both the dependency and request in the Gantt chart?

Click the highlighted stuff to get to end-to-end transaction details image

jdudleyie commented 5 years ago

Thanks for your help, I was able to get this working by enabling the cors correlation option to send the Request-Id from my client.

github-actions[bot] commented 3 years ago

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.