Re: [compute-pressure] Allow an array of sources (#213)

It seems that using [PressureSource](https://www.w3.org/TR/compute-pressure/#dom-pressuresource) is a good/futureproof design. Currently it supports "cpu" and "thermals", but I guess it might support in the future "memory", "io" ("bus", "network"), "gpu", "psi" etc.

These sources might be independent or not, depending on the situation. 

There is a question whether do we want to add sources with sequential API calls, in order to catch specific errors (which on the other hand might be a fingerprinting opportunity), - or to specify a list of sources with one call as suggested above, and control the order of adding the sources by the spec algorithm (or by a policy hint from the user). IMHO the API shape is mainly influenced by what errors we want to capture, when and how.

-- 
GitHub Notification of comment by zolkis
Please view or discuss this issue at https://github.com/w3c/compute-pressure/issues/213#issuecomment-1570194489 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Wednesday, 31 May 2023 13:02:44 UTC