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

Side by Side Diff: content/browser/service_worker/service_worker_disk_cache_migrator.h

Issue 1152543002: ServiceWorker: Migrate the script cache backend from BlockFile to Simple (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 6 months 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 #ifndef CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISK_CACHE_MIGRATOR_H_ 5 #ifndef CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISK_CACHE_MIGRATOR_H_
6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISK_CACHE_MIGRATOR_H_ 6 #define CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISK_CACHE_MIGRATOR_H_
7 7
8 #include "content/browser/service_worker/service_worker_disk_cache.h" 8 #include "content/browser/service_worker/service_worker_disk_cache.h"
9 9
10 #include "base/id_map.h" 10 #include "base/id_map.h"
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 scoped_ptr<ServiceWorkerDiskCache> src_; 70 scoped_ptr<ServiceWorkerDiskCache> src_;
71 scoped_ptr<ServiceWorkerDiskCache> dest_; 71 scoped_ptr<ServiceWorkerDiskCache> dest_;
72 const int max_disk_cache_size_; 72 const int max_disk_cache_size_;
73 scoped_refptr<base::SingleThreadTaskRunner> disk_cache_thread_; 73 scoped_refptr<base::SingleThreadTaskRunner> disk_cache_thread_;
74 74
75 InflightTaskMap::KeyType next_task_id_ = 0; 75 InflightTaskMap::KeyType next_task_id_ = 0;
76 InflightTaskMap inflight_tasks_; 76 InflightTaskMap inflight_tasks_;
77 scoped_ptr<Task> pending_task_; 77 scoped_ptr<Task> pending_task_;
78 size_t max_number_of_inflight_tasks_ = 10; 78 size_t max_number_of_inflight_tasks_ = 10;
79 79
80 base::TimeTicks start_time_;
81 size_t number_of_migrated_resources_ = 0;
82
80 StatusCallback callback_; 83 StatusCallback callback_;
81 84
82 base::WeakPtrFactory<ServiceWorkerDiskCacheMigrator> weak_factory_; 85 base::WeakPtrFactory<ServiceWorkerDiskCacheMigrator> weak_factory_;
83 86
84 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerDiskCacheMigrator); 87 DISALLOW_COPY_AND_ASSIGN(ServiceWorkerDiskCacheMigrator);
85 }; 88 };
86 89
87 } // namespace content 90 } // namespace content
88 91
89 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISK_CACHE_MIGRATOR_H_ 92 #endif // CONTENT_BROWSER_SERVICE_WORKER_SERVICE_WORKER_DISK_CACHE_MIGRATOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698