New issue
Advanced search Search tips

Issue 807499 link

Starred by 3 users

Issue metadata

Status: Fixed
Owner:
Closed: Feb 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Feature

Blocking:
issue 161072



Sign in to add a comment

Web Locks API: acquire() should throw if mutually exclusive options are specified

Project Member Reported by jsb...@chromium.org, Jan 31 2018

Issue description

proto-spec has:

Otherwise, if both options' steal dictionary member and option's ifAvailable dictionary member are true, then reject promise with an "NotSupportedError" DOMException.
 

Comment 1 by jsb...@chromium.org, Jan 31 2018

Blocking: 161072
Labels: Type-Feature
Project Member

Comment 3 by bugdroid1@chromium.org, Feb 6 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/8515e54abfff429157ab1e0ffe475610c5c1b88a

commit 8515e54abfff429157ab1e0ffe475610c5c1b88a
Author: Joshua Bell <jsbell@chromium.org>
Date: Tue Feb 06 20:20:21 2018

Web Locks API: Implement `steal` option

From the Explainer:

If a web application detects an unrecoverable state - for example, some
coordination point like a Service Worker determines that a tab holding a
lock is no longer responding - it can "steal" a lock by passing this option
to acquire(). When specified, any held locks for the resource will be
released (the lock's released promise will resolve with AbortError), and
the request will be granted.

Explainer: https://github.com/inexorabletash/web-locks

Bug:  804545 , 807499 
Change-Id: Ib837b8b7fa6ca7b0e1e96a8aa0dedc1292b26130
Reviewed-on: https://chromium-review.googlesource.com/890024
Commit-Queue: Joshua Bell <jsbell@chromium.org>
Reviewed-by: Daniel Cheng <dcheng@chromium.org>
Reviewed-by: Victor Costan <pwnall@chromium.org>
Cr-Commit-Position: refs/heads/master@{#534774}
[modify] https://crrev.com/8515e54abfff429157ab1e0ffe475610c5c1b88a/content/browser/locks/lock_manager.cc
[modify] https://crrev.com/8515e54abfff429157ab1e0ffe475610c5c1b88a/content/browser/locks/lock_manager.h
[modify] https://crrev.com/8515e54abfff429157ab1e0ffe475610c5c1b88a/third_party/WebKit/LayoutTests/http/tests/locks/acquire.html
[modify] https://crrev.com/8515e54abfff429157ab1e0ffe475610c5c1b88a/third_party/WebKit/LayoutTests/http/tests/locks/held.html
[add] https://crrev.com/8515e54abfff429157ab1e0ffe475610c5c1b88a/third_party/WebKit/LayoutTests/http/tests/locks/steal.html
[modify] https://crrev.com/8515e54abfff429157ab1e0ffe475610c5c1b88a/third_party/WebKit/Source/modules/locks/Lock.cpp
[modify] https://crrev.com/8515e54abfff429157ab1e0ffe475610c5c1b88a/third_party/WebKit/Source/modules/locks/Lock.h
[modify] https://crrev.com/8515e54abfff429157ab1e0ffe475610c5c1b88a/third_party/WebKit/Source/modules/locks/LockManager.cpp
[modify] https://crrev.com/8515e54abfff429157ab1e0ffe475610c5c1b88a/third_party/WebKit/Source/modules/locks/LockOptions.idl
[modify] https://crrev.com/8515e54abfff429157ab1e0ffe475610c5c1b88a/third_party/WebKit/public/platform/modules/locks/lock_manager.mojom

Status: Fixed (was: Started)
Project Member

Comment 5 by bugdroid1@chromium.org, Feb 7 2018

Sign in to add a comment