Does ClearProvidersExceptFunctionProviders work as expected ? #189
-
Since I'm seeing some strange behavior when using Arcus Observability in my Azure Function (custom events are written as an event and as a Warning Trace, I decided to have a look at the foreach (ServiceDescriptor serviceDescriptor in loggingBuilder.Services)
{
if (serviceDescriptor.ServiceType == typeof(ILoggerProvider))
{
if (serviceDescriptor.ImplementationType.FullName != "Microsoft.Azure.WebJobs.Script.Diagnostics.HostFileLoggerProvider"
&& serviceDescriptor.ImplementationType.FullName != "Microsoft.Azure.WebJobs.Script.Diagnostics.FunctionFileLoggerProvider")
{
loggingBuilder.Services.Remove(serviceDescriptor);
break;
}
}
} link I was in doubt whether to open an issue or a discussion for this, but choose for discussion. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
To be honest, I don't know anymore what the reason was why we added this logging extension. It was a problem that @tomkerkhove came across in an Azure Functions environment and solved it with this. |
Beta Was this translation helpful? Give feedback.
-
Discussed offline: we will deprecate this method and eventually remove this Azure Functions-specific package entirely. #346 |
Beta Was this translation helpful? Give feedback.
Discussed offline: we will deprecate this method and eventually remove this Azure Functions-specific package entirely. #346