Intent to Ship: Saved queries in sharedStorage.selectURL

308 views
Skip to first unread message

Cammie Smith Barnes

unread,
Oct 31, 2024, 4:22:02 PMOct 31
to blink-dev, Cammie Smith Barnes, Josh Karlin, Yao Xiao, Rohit Gupta, ren...@google.com, sara...@google.com

Intent to Ship: Saved queries in sharedStorage.selectURL


Contact emails

cam...@chromium.org, yao...@chromium.org, jka...@chromium.org, rohit...@chromium.org, rohit...@chromium.org, ren...@google.com, sara...@google.com


Explainer

https://github.com/WICG/shared-storage/pull/176


Specification

https://github.com/WICG/shared-storage/pull/188

https://github.com/WICG/shared-storage/pull/202


Summary

Until fenced frames are required for selectURL, we have a per-page limit on its usage. This is limiting for callers as they can only use it twice per page load. This savedQuery option allows for selectURL() to be called any number of times across a page, and will always return the same value for the same query name. This is helpful for callers that are looking for consistent behavior based on cross-site information (e.g., cross-site a/b experiment selection). 


Blink component

Blink>Storage>SharedStorage


TAG review

Review


TAG review status

TAG is unsatisfied with the underlying API


Risks



Interoperability and Compatibility

This is a backwards compatible change. 



Gecko: Negative toward the selectURL API


WebKit: Negative toward the selectURL API


Web developers: Developers have been asking for this, as it allows them to use selectURL more frequently on a page without any privacy impact. 


Other signals:


WebView application risks

Does this intent deprecate or change behavior of existing APIs, such that it has potentially high risk for Android WebView-based applications?

None



Debuggability

We intend to surface the per page load Shared Storage budgets in DevTools in a similar manner to the way that Shared Storage's navigation budget for Fenced Frames is surfaced on an origin's Application > Storage > Shared Storage page. This would allow developers, when testing locally, to confirm that budgets were charged as expected for saved queries. We may also consider including the per-page saved queries in devtools as well. We plan to start implementation of these features soon.




Will this feature be supported on all six Blink platforms (Windows, Mac, Linux, ChromeOS, Android, and Android WebView)?

All but WebView


Is this feature fully tested by web-platform-tests?

Yes


Flag name on chrome://flags

None


Finch feature name

SharedStorageSelectURLSavedQueries


Requires code in //chrome?

False


Tracking bug

https://issues.chromium.org/u/1/issues/367440966


Launch bug

https://launch.corp.google.com/launch/4346722


Estimated milestones

Shipping on desktop

132

Shipping on Android

132



Anticipated spec changes

Open questions about a feature may be a source of future web compat or interop issues. Please list open issues (e.g. links to known github issues in the project for the feature specification) whose resolution may introduce web compat/interop risk (e.g., changing to naming or structure of the API in a non-backward-compatible way).

None


Link to entry on the Chrome Platform Status

https://chromestatus.com/feature/5098690386329600?gate=5084801233846272


This intent message was generated by Chrome Platform Status.


Yoav Weiss (@Shopify)

unread,
Nov 6, 2024, 10:26:03 AMNov 6
to blink-dev, Cammie Smith Barnes, Josh Karlin, Yao Xiao, Rohit Gupta, ren...@google.com, sara...@google.com
LGTM1

On Thursday, October 31, 2024 at 9:22:02 PM UTC+1 Cammie Smith Barnes wrote:

A few lines of inline explanation and/or copy/pasting the example from the final explainer would have been better than pointing at a PR diff..

Chris Harrelson

unread,
Nov 6, 2024, 11:21:31 AMNov 6
to Yoav Weiss (@Shopify), blink-dev, Cammie Smith Barnes, Josh Karlin, Yao Xiao, Rohit Gupta, ren...@google.com, sara...@google.com
LGTM2

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.
To view this discussion visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/f2698444-0b26-4e75-8803-f7491a0594e1n%40chromium.org.

Mike Taylor

unread,
Nov 6, 2024, 1:27:56 PMNov 6
to Chris Harrelson, Yoav Weiss (@Shopify), blink-dev, Cammie Smith Barnes, Josh Karlin, Yao Xiao, Rohit Gupta, ren...@google.com, sara...@google.com
Reply all
Reply to author
Forward
0 new messages