[IndexedDB] blocked event should have default operation to close the connection

An application receive blocked event on IndexedDB database instance when
another app open the database with a newer version.

The receiving application must close the connection so that other tab
receive open success event. Otherwise database open request will be
pending. Most developer are unaware of the fact and hard to figure out the
reason.

My suggestion is to make close method as default operation of blocked
event. For that app, that require to save data should listen blocked event
and invoke preventDefault() and finally close the connection.

After connection was closed, any transaction request will throw
InvalidStateError just like closePending flag is set. The final effect is
the same, but this time, developer can figure out the problem.

Best,
Kyaw

Received on Wednesday, 9 October 2013 15:06:44 UTC