Skip to content
Commit a1a555ba authored by Camillia Smith Barnes's avatar Camillia Smith Barnes Committed by Chromium LUCI CQ
Browse files

Shared Storage: Close worklet by default after execution

We change the default for shared storage worklets so that they close after a `run()` or `selectURL()` operation, unless the caller uses the new option (added in this CL) `keepAlive: true`. This option must be used each time that the caller wants the worklet's lifetime to be extended such that another operation can be run in the same context. Otherwise, any subsequent calls to shared storage worklet operations will fail.

See https://github.com/WICG/shared-storage/pull/67 for more details.

It is likely that, in a follow-up, we will need to make the `mojo::Remote<blink::mojom::PrivateAggregationHost>` in `SharedStorageWorkletServiceImpl` into a mojo::AssociatedRemote<blink::mojom::PrivateAggregationHost> in order to preserve the order of operations between shared storage and private aggregation. This will ensure that private aggregation operations called within a shared storage operation are not dropped when the shared storage operation is finished and the worklet is closing, as they might be if the operations arrived out of order.

Bug: 1218540,1425329
Change-Id: I75dba570acf15017d08efe1602e0db2abd1e109e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4334688


Reviewed-by: default avatarYao Xiao <yaoxia@chromium.org>
Commit-Queue: Cammie Smith Barnes <cammie@chromium.org>
Reviewed-by: default avatardanakj <danakj@chromium.org>
Reviewed-by: default avatarAvi Drissman <avi@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1120049}
parent d80317a5
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment