Comment by JCTheDenthog
1 day ago
Exceptions are significantly slower than normal control flow in C# (about 10,000 times slower). It's also pretty non-idiomatic in both C# and most other languages I've worked in to use exceptions instead of a switch statement or similar to handle an HTTP error code. Also there can be multiple possible non-error responses from an endpoint you need to differentiate between, and exceptions would make zero sense in that case.
> Also there can be multiple possible non-error responses from an endpoint you need to differentiate between
Yeah, I'm mildly sold on this use-case to be fair. But I think I'll keep the unexpected errors as exceptions.