WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
54785
When an IDBTransaction is aborted, all requests that have not yet fired should fire an ABORT_ERR
https://bugs.webkit.org/show_bug.cgi?id=54785
Summary
When an IDBTransaction is aborted, all requests that have not yet fired shoul...
Jeremy Orlow
Reported
2011-02-18 17:42:46 PST
When an IDBTransaction is aborted, all requests that have not yet fired should fire an ABORT_ERR
Attachments
Patch
(27.10 KB, patch)
2011-02-18 17:52 PST
,
Jeremy Orlow
no flags
Details
Formatted Diff
Diff
Patch
(28.92 KB, patch)
2011-02-22 16:04 PST
,
Jeremy Orlow
no flags
Details
Formatted Diff
Diff
Patch
(26.88 KB, patch)
2011-02-28 14:22 PST
,
Jeremy Orlow
steveblock
: review+
Details
Formatted Diff
Diff
Show Obsolete
(2)
View All
Add attachment
proposed patch, testcase, etc.
Jeremy Orlow
Comment 1
2011-02-18 17:52:17 PST
Created
attachment 83040
[details]
Patch
Jeremy Orlow
Comment 2
2011-02-18 17:52:52 PST
please review
Hans Wennborg
Comment 3
2011-02-21 01:34:14 PST
Comment on
attachment 83040
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=83040&action=review
> LayoutTests/storage/indexeddb/transaction-abort.html:55 > + request.onerror = firstAdd;
Maybe set onsuccess = unexpectedSuccessFeedback?
> LayoutTests/storage/indexeddb/transaction-abort.html:66 > +{
Assert that it's an ABORT_ERR?
David Grogan
Comment 4
2011-02-22 14:08:29 PST
Bugzilla won't let me submit this comment on the patch ("You are not authorized to edit
attachment 83040
[details]
."), but:
> Source/WebCore/storage/IDBRequest.cpp:226 > + m_transaction->registerRequest(this);
What does this do? It seems to be here so that if the SetVersion transaction aborts, the error handler on the request for a setversion transaction will be called. But for the transaction to abort, wouldn't the setversion success handler have to already be called? What am I missing?
Jeremy Orlow
Comment 5
2011-02-22 14:37:55 PST
(In reply to
comment #3
)
> (From update of
attachment 83040
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=83040&action=review
> > > LayoutTests/storage/indexeddb/transaction-abort.html:55 > > + request.onerror = firstAdd; > > Maybe set onsuccess = unexpectedSuccessFeedback?
Good idea
> > LayoutTests/storage/indexeddb/transaction-abort.html:66 > > +{ > > Assert that it's an ABORT_ERR?
Good idea (In reply to
comment #4
)
> Bugzilla won't let me submit this comment on the patch ("You are not authorized to edit
attachment 83040
[details]
."), but: > > > Source/WebCore/storage/IDBRequest.cpp:226 > > + m_transaction->registerRequest(this); > > What does this do? > It seems to be here so that if the SetVersion transaction aborts, the error handler on the request for a setversion transaction will be called. But for the transaction to abort, wouldn't the setversion success handler have to already be called? What am I missing?
Originally I asserted that if you unregistered something it had been registered before. And we don't fire onError when aborting something that already fired an onSuccess. So I believe it's OK as is, but probably a bit cleaner without. Will change.
Jeremy Orlow
Comment 6
2011-02-22 16:04:10 PST
Created
attachment 83406
[details]
Patch
James Robinson
Comment 7
2011-02-25 16:10:39 PST
Comment on
attachment 83406
[details]
Patch You have some spurious test_expectations.txt changes and conflicts that prevent EWS from running. Mind re-upping one without these?
Jeremy Orlow
Comment 8
2011-02-25 16:16:14 PST
I think the test_expectation change is a real issue...I couldn't run without it. I can't upload a new one at the moment, but I will Monday. The bots won't add much information though since this code only runs for Chromium.
Jeremy Orlow
Comment 9
2011-02-28 14:22:57 PST
Created
attachment 84120
[details]
Patch
Jeremy Orlow
Comment 10
2011-02-28 14:26:52 PST
Nate's OOO and this is for m11, so if someone else could look, it'd be great.
Steve Block
Comment 11
2011-03-01 01:57:51 PST
Comment on
attachment 84120
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=84120&action=review
> Source/WebCore/storage/IDBRequest.h:62 > + EarlyDeath = 3
Why do you use a different style for this member of the enum?
Jeremy Orlow
Comment 12
2011-03-01 08:56:33 PST
(In reply to
comment #11
)
> (From update of
attachment 84120
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=84120&action=review
> > > Source/WebCore/storage/IDBRequest.h:62 > > + EarlyDeath = 3 > > Why do you use a different style for this member of the enum?
Because its proper webkit style. The others match the IDL, but this isn't in IDL. I can make it match if you think that's better though. Thanks!
Steve Block
Comment 13
2011-03-01 09:01:00 PST
Comment on
attachment 84120
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=84120&action=review
>>> Source/WebCore/storage/IDBRequest.h:62 >>> + EarlyDeath = 3 >> >> Why do you use a different style for this member of the enum? > > Because its proper webkit style. The others match the IDL, but this isn't in IDL. I can make it match if you think that's better though. > > Thanks!
OK, makes sense. So while the request is in the EarlyDeath internal-only state, what state is reported to script? Or is this not relevant/possible?
Jeremy Orlow
Comment 14
2011-03-01 09:07:30 PST
(In reply to
comment #13
)
> (From update of
attachment 84120
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=84120&action=review
> > >>> Source/WebCore/storage/IDBRequest.h:62 > >>> + EarlyDeath = 3 > >> > >> Why do you use a different style for this member of the enum? > > > > Because its proper webkit style. The others match the IDL, but this isn't in IDL. I can make it match if you think that's better though. > > > > Thanks! > > OK, makes sense. So while the request is in the EarlyDeath internal-only state, what state is reported to script? Or is this not relevant/possible?
Not possible. That's why readyState() has this assert: ASSERT(m_readyState == LOADING || m_readyState == DONE);
Steve Block
Comment 15
2011-03-01 09:10:52 PST
Comment on
attachment 84120
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=84120&action=review
>>>>> Source/WebCore/storage/IDBRequest.h:62 >>>>> + EarlyDeath = 3 >>>> >>>> Why do you use a different style for this member of the enum? >>> >>> Because its proper webkit style. The others match the IDL, but this isn't in IDL. I can make it match if you think that's better though. >>> >>> Thanks! >> >> OK, makes sense. So while the request is in the EarlyDeath internal-only state, what state is reported to script? Or is this not relevant/possible? > > Not possible. That's why readyState() has this assert: ASSERT(m_readyState == LOADING || m_readyState == DONE);
I see, makes sense. Maybe add a comment in the enum that the EarlyDeath value is internal only.
Jeremy Orlow
Comment 16
2011-03-01 12:42:33 PST
Committed
r80028
: <
http://trac.webkit.org/changeset/80028
>
WebKit Review Bot
Comment 17
2011-03-01 13:23:20 PST
http://trac.webkit.org/changeset/80028
might have broken Qt Linux Release The following tests are not passing: editing/deleting/4916235-1.html editing/deleting/5390681.html editing/deleting/5546763.html editing/deleting/delete-3775172-fix.html editing/deleting/delete-at-paragraph-boundaries-007.html editing/deleting/delete-before-block-image-1.html
Jeremy Orlow
Comment 18
2011-03-01 13:32:55 PST
Caused regressions...need to fix up.
http://build.webkit.org/results/Windows%207%20Release%20(Tests)/r80028%20(9911)/results.html
http://build.webkit.org/results/Windows%207%20Release%20(Tests)/r80028%20(9911)/editing/deleting/6026335-crash-log.txt
FAULTING_SOURCE_CODE: 100: ASSERT_UNUSED(wasAdded, wasAdded); // It should not have already been in the list. 101: 102: while (!m_queuedEvents.isEmpty()) { 103: ListHashSet<RefPtr<Event> >::iterator iter = m_queuedEvents.begin();
> 104: RefPtr<Event> event = *iter;
105: m_queuedEvents.remove(iter); 106: if (!event) 107: break; 108: dispatchEvent(event.get()); 109: }
Jeremy Orlow
Comment 19
2011-03-01 15:55:51 PST
Committed
r80055
: <
http://trac.webkit.org/changeset/80055
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug