[whatwg/fetch] Consider adding load balancing / failover to Fetch? (#775)

For background, the [Reporting API](https://w3c.github.io/reporting/) defines a load balancing / failover mechanism for uploading reports to a collector.  This mechanism is implemented client-side, with the user agent receiving a prioritized and weighted list of URLs (inspired by DNS `SRV` records), and choosing one according to those instructions at upload time.  The [Network Error Logging](https://w3c.github.io/network-error-logging) spec, in particular, needs the load balancing / failover to happen on the client, instead of relying on existing server-side techniques, since its signal is most useful in the presence of partial network connectivity issues that would prevent the report uploads from reaching a single canonical upload URL.  Since the user agent has already received a list of failover URLs before the connectivity issue begins, it has several options that hopefully let it upload the reports "around" the connectivity issues.

@mnot suggested in w3c/reporting#93 that this logic might be more generally useful.  For now, we're keeping the logic defined in Reporting, but if other people / specs would find this logic useful, we could consider adding it to Fetch proper.

DNS `SRV` records are exactly what we need, although communicating this information through DNS might not be secure enough; we'd probably want to limit this to secure origins.  @mnot also proposed communicating the list of load balancer / failover URLs via [Origin Policy](https://wicg.github.io/origin-policy/).

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/fetch/issues/775

Received on Saturday, 7 July 2018 14:05:50 UTC