Skip to content

Conversation

@Zee2413
Copy link
Contributor

@Zee2413 Zee2413 commented Jan 23, 2026

Summary

Exclude client-side network errors from getSchemas.fault metrics in GetPublicSchemaTask and GetSamSchemaTask. These errors are caused by user environment issues (corporate proxies, firewalls, DNS) and are outside our control.

Problem

Analysis of the last 24 hours of telemetry data shows:

Task Total Requests Failures Failure Rate
GetSamSchemaTask 10,569 949 9.0%
GetPublicSchemaTask 10,451 767 7.3%

~54% of these failures are client-side errors we cannot fix:

  • SSL/TLS Certificate Issues (~35%) - Corporate proxies/firewalls intercepting HTTPS
  • Network Connectivity (~11%) - Timeouts, connection resets, socket hang ups
  • DNS Resolution Failures (~8%) - Cannot resolve hosts, proxy misconfiguration
  • Proxy Authentication (~0.4%) - 407 errors

Solution

Added isClientNetworkError() utility that detects client-side network errors by matching known error patterns:

  • SSL/TLS: self signed certificate, unable to get local issuer certificate, etc.
  • Network: ECONNRESET, ETIMEDOUT, ENOTFOUND, socket hang up, etc.
  • Proxy: status code 407, TOO_MANY_REDIRECTS, Parse Error: Expected HTTP

When these errors occur, the schema tasks now return gracefully instead of throwing, so they don't count as faults in our metrics.

Testing

  • Added unit tests for isClientNetworkError() in Errors.test.ts
  • Added tests for client network error handling in GetSchemaTask.test.ts

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@Zee2413 Zee2413 requested a review from a team as a code owner January 23, 2026 23:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant