Skip to content

WebJobs handler logs handled exceptions that are written to the trace writer #349

@xt0rted

Description

@xt0rted

I have a try/catch and in the catch I'm calling _trace.Error($"Error loading user '{emailAddress}'", ex) so the exception is shown as such in the console while debugging. Because of how the webjobs extension pulls out errors to send this is triggering handled exceptions to be logged as if they were unhandled.

I don't think this is a bug but rather something that just catches you off guard when you run across it.

In v3 of the webjobs sdk logging is a first class feature now of which Application Insights has an out of the box implementation. I haven't had a chance to look through this though to see how exceptions are being dealt with.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions