For an Azure Function(AF) one can select Application Insights (AI) in Azure Portal. All information put into ILogger in .Net application will be sent to this AI. But in my case AF and AI are running under different accounts. Is there any way to specify a sink for Ilogger using just the Instrumentation key?
I could directly use TelemetryClient from AI libraries, but I am not sure if all information will be sent before AF shuts down, and calling Flush at the end of each function seems wrong.
Edit: Different accounts means, different Active directories.