A has a done flag which is initially unset.

    A request has a source object.

    A has a result and an error, neither of which are accessible until the done flag is set.

    A has a transaction which is initially null. This will be set when a request is placed against a transaction using the steps to .

    If an error occurs while performing the operation, the done flag is set, the is set to the error, and an event with type error is fired at the request.

    A request‘s algorithm returns the request’s transaction.

    Requests are not typically re-used, but there are exceptions. When a is iterated, the success of the iteration is reported on the same request object used to open the cursor. And when an is necessary, the same open request is used for both the event and final result of the open operation itself. In some cases, the request’s will be unset then set again, and the result can change or could be set insead.

    2.8.1. Open Requests

    An open request is a special type of request used when opening a or deleting a database. In addition to success and events, blocked and may be fired at an to indicate progress.

    The transaction of an is null unless an [upgradeneeded](#request-upgradeneeded) event has been fired.

    An open request‘s algorithm returns null.

    Open requests are processed in a connection queue. The queue contains all associated with an origin and a . Requests added to the connection queue processed in order and each request must run to completion before the next request is processed. An open request may be blocked on other , requiring those connections to close before the request can complete and allow further requests to be processed.

    A is not a task queue associated with an , as the requests are processed outside any specific browsing context. The delivery of events to completed still goes through a task queue associated with the of the context where the request was made.