Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(87)

Side by Side Diff: net/base/load_states_list.h

Issue 2519473002: Fixes the cache lock issue. (Closed)
Patch Set: Initial patch Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // This is the list of load states and their values. For the enum values, 5 // This is the list of load states and their values. For the enum values,
6 // include the file "net/base/load_states.h". 6 // include the file "net/base/load_states.h".
7 // 7 //
8 // Here we define the values using a macro LOAD_STATE, so it can be 8 // Here we define the values using a macro LOAD_STATE, so it can be
9 // expanded differently in some places (for example, to automatically 9 // expanded differently in some places (for example, to automatically
10 // map a load flag value to its symbolic name). 10 // map a load flag value to its symbolic name).
(...skipping 21 matching lines...) Expand all
32 32
33 // This state indicates that the URLRequest delegate has chosen to block this 33 // This state indicates that the URLRequest delegate has chosen to block this
34 // request before it was sent over the network. When in this state, the 34 // request before it was sent over the network. When in this state, the
35 // delegate should set a load state parameter on the URLRequest describing 35 // delegate should set a load state parameter on the URLRequest describing
36 // the nature of the delay (i.e. "Waiting for <description given by 36 // the nature of the delay (i.e. "Waiting for <description given by
37 // delegate>"). 37 // delegate>").
38 LOAD_STATE(WAITING_FOR_DELEGATE, 4) 38 LOAD_STATE(WAITING_FOR_DELEGATE, 4)
39 39
40 // This state corresponds to a resource load that is blocked waiting for 40 // This state corresponds to a resource load that is blocked waiting for
41 // access to a resource in the cache. If multiple requests are made for the 41 // access to a resource in the cache. If multiple requests are made for the
42 // same resource, the first request will be responsible for writing (or 42 // same resource, the first request/multiple sharing-eligible requests will be
43 // updating) the cache entry and the second request will be deferred until 43 // responsible for writing (or updating) the cache entry and the remaining
44 // the first completes. This may be done to optimize for cache reuse. 44 // requests will be deferred until the writing completes or the writer
jkarlin 2016/12/06 18:08:17 Can you omit 'or the write transactions compelte'?
shivanisha 2016/12/06 21:53:34 Done. Also rephrased the last sentence to be "This
45 // transactions complete. This may be done to optimize for cache reuse.
45 LOAD_STATE(WAITING_FOR_CACHE, 5) 46 LOAD_STATE(WAITING_FOR_CACHE, 5)
46 47
47 // This state corresponds to a resource load that is blocked waiting for 48 // This state corresponds to a resource load that is blocked waiting for
48 // access to a resource in the AppCache. 49 // access to a resource in the AppCache.
49 // Note: This is a layering violation, but being the only one it's not that 50 // Note: This is a layering violation, but being the only one it's not that
50 // bad. TODO(rvargas): Reconsider what to do if we need to add more. 51 // bad. TODO(rvargas): Reconsider what to do if we need to add more.
51 LOAD_STATE(WAITING_FOR_APPCACHE, 6) 52 LOAD_STATE(WAITING_FOR_APPCACHE, 6)
52 53
53 // This state corresponds to a resource being blocked waiting for the 54 // This state corresponds to a resource being blocked waiting for the
54 // PAC script to be downloaded. 55 // PAC script to be downloaded.
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
93 // corresponds to the period after the request is sent and before all of the 94 // corresponds to the period after the request is sent and before all of the
94 // response headers have been received. 95 // response headers have been received.
95 LOAD_STATE(WAITING_FOR_RESPONSE, 15) 96 LOAD_STATE(WAITING_FOR_RESPONSE, 15)
96 97
97 // This state corresponds to a resource load that is blocked waiting for a 98 // This state corresponds to a resource load that is blocked waiting for a
98 // read to complete. In the case of a HTTP transaction, this corresponds to 99 // read to complete. In the case of a HTTP transaction, this corresponds to
99 // the period after the response headers have been received and before all of 100 // the period after the response headers have been received and before all of
100 // the response body has been downloaded. (NOTE: This state only applies for 101 // the response body has been downloaded. (NOTE: This state only applies for
101 // an URLRequest while there is an outstanding Read operation.) 102 // an URLRequest while there is an outstanding Read operation.)
102 LOAD_STATE(READING_RESPONSE, 16) 103 LOAD_STATE(READING_RESPONSE, 16)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698