| Index: content/browser/appcache/appcache_storage_impl.h
|
| diff --git a/content/browser/appcache/appcache_storage_impl.h b/content/browser/appcache/appcache_storage_impl.h
|
| index ca6d76b314bf0c4c945ea29bb02c10a930b0c943..6a28305a46ece143707b083216e0c287c7fff426 100644
|
| --- a/content/browser/appcache/appcache_storage_impl.h
|
| +++ b/content/browser/appcache/appcache_storage_impl.h
|
| @@ -15,6 +15,7 @@
|
| #include "base/files/file_path.h"
|
| #include "base/memory/ref_counted.h"
|
| #include "base/memory/weak_ptr.h"
|
| +#include "base/timer/timer.h"
|
| #include "content/browser/appcache/appcache_database.h"
|
| #include "content/browser/appcache/appcache_disk_cache.h"
|
| #include "content/browser/appcache/appcache_storage.h"
|
| @@ -87,7 +88,8 @@ class AppCacheStorageImpl : public AppCacheStorage {
|
| class GetDeletableResponseIdsTask;
|
| class InsertDeletableResponseIdsTask;
|
| class DeleteDeletableResponseIdsTask;
|
| - class UpdateGroupLastAccessTimeTask;
|
| + class LazyUpdateLastAccessTimeTask;
|
| + class CommitLastAccessTimesTask;
|
|
|
| typedef std::deque<DatabaseTask*> DatabaseTaskQueue;
|
| typedef std::map<int64, CacheLoadTask*> PendingCacheLoads;
|
| @@ -111,12 +113,13 @@ class AppCacheStorageImpl : public AppCacheStorage {
|
| void StartDeletingResponses(const std::vector<int64>& response_ids);
|
| void ScheduleDeleteOneResponse();
|
| void DeleteOneResponse();
|
| -
|
| void OnDeletedOneResponse(int rv);
|
| void OnDiskCacheInitialized(int rv);
|
| void DeleteAndStartOver();
|
| void DeleteAndStartOverPart2();
|
| void CallScheduleReinitialize();
|
| + void LazilyCommitLastAccessTimes();
|
| + void OnCommitLastAccessTimes();
|
|
|
| // Sometimes we can respond without having to query the database.
|
| bool FindResponseForMainRequestInGroup(
|
| @@ -168,6 +171,7 @@ class AppCacheStorageImpl : public AppCacheStorage {
|
| bool is_disabled_;
|
|
|
| scoped_ptr<AppCacheDiskCache> disk_cache_;
|
| + base::OneShotTimer<AppCacheStorageImpl> lazy_commit_timer_;
|
|
|
| // Used to short-circuit certain operations without having to schedule
|
| // any tasks on the background database thread.
|
|
|