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

Unified Diff: chrome/browser/sync_file_system/drive_backend/sync_engine.h

Issue 306813002: [SyncFS] Make routines using metadata database async (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add a comment Created 6 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/sync_file_system/drive_backend/sync_engine.h
diff --git a/chrome/browser/sync_file_system/drive_backend/sync_engine.h b/chrome/browser/sync_file_system/drive_backend/sync_engine.h
index 45bf4b344f379ca6fd622d7161cf8c0958ba235b..f9dbf4d5a329fc67e52e52bd130029ae47d50478 100644
--- a/chrome/browser/sync_file_system/drive_backend/sync_engine.h
+++ b/chrome/browser/sync_file_system/drive_backend/sync_engine.h
@@ -121,7 +121,11 @@ class SyncEngine : public RemoteFileSyncService,
drive::DriveServiceInterface* GetDriveService();
drive::DriveUploaderInterface* GetDriveUploader();
- MetadataDatabase* GetMetadataDatabase();
+
+ // NOTICE: Basically, metadata database runs on |worker_task_runner_|.
+ // Handling it through GetMetadataDatabaseForTesting() in the main thread
+ // may bring race condition.
tzik 2014/05/29 02:31:09 I believe we should convert SyncEngineTest to Sync
peria 2014/05/29 03:11:46 I filed a bug crbug.com/378621. How about leaving
+ MetadataDatabase* GetMetadataDatabaseForTesting();
SyncTaskManager* GetSyncTaskManagerForTesting();
void OnPendingFileListUpdated(int item_count);
@@ -131,6 +135,7 @@ class SyncEngine : public RemoteFileSyncService,
SyncDirection direction);
void UpdateServiceState(RemoteServiceState state,
const std::string& description);
+ void DidPromoteDemotedChanges(size_t num_trackers);
private:
class WorkerObserver;
@@ -145,7 +150,7 @@ class SyncEngine : public RemoteFileSyncService,
ExtensionServiceInterface* extension_service,
SigninManagerBase* signin_manager);
- void UpdateRegisteredApps();
+ void UpdateRegisteredAppsForTesting();
scoped_ptr<drive::DriveServiceInterface> drive_service_;
scoped_ptr<DriveServiceWrapper> drive_service_wrapper_;

Powered by Google App Engine
This is Rietveld 408576698