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

Side by Side Diff: chrome/browser/sync/engine/syncer.cc

Issue 7024058: [Sync] Clean up sync logging (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix comments Created 9 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #include "chrome/browser/sync/engine/syncer.h" 5 #include "chrome/browser/sync/engine/syncer.h"
6 6
7 #include "base/message_loop.h" 7 #include "base/message_loop.h"
8 #include "base/time.h" 8 #include "base/time.h"
9 #include "chrome/browser/sync/engine/apply_updates_command.h" 9 #include "chrome/browser/sync/engine/apply_updates_command.h"
10 #include "chrome/browser/sync/engine/build_and_process_conflict_sets_command.h" 10 #include "chrome/browser/sync/engine/build_and_process_conflict_sets_command.h"
(...skipping 250 matching lines...) Expand 10 before | Expand all | Expand 10 after
261 clear_data_command.Execute(session); 261 clear_data_command.Execute(session);
262 next_step = SYNCER_END; 262 next_step = SYNCER_END;
263 break; 263 break;
264 } 264 }
265 case SYNCER_END: { 265 case SYNCER_END: {
266 break; 266 break;
267 } 267 }
268 default: 268 default:
269 LOG(ERROR) << "Unknown command: " << current_step; 269 LOG(ERROR) << "Unknown command: " << current_step;
270 } 270 }
271 VLOG(2) << "last step: " << last_step << ", current step: "
272 << current_step << ", next step: "
273 << next_step << ", snapshot: "
274 << session->TakeSnapshot().ToString();
271 if (last_step == current_step) 275 if (last_step == current_step)
272 break; 276 break;
273 current_step = next_step; 277 current_step = next_step;
274 } 278 }
275 279
276 VLOG(1) << "Syncer End"; 280 VLOG(1) << "Syncer End";
281 VLOG(2) << "last step: " << last_step << ", current step: "
282 << current_step << ", next step: "
283 << next_step << ", snapshot: "
284 << session->TakeSnapshot().ToString();
277 SyncerEndCommand syncer_end_command; 285 SyncerEndCommand syncer_end_command;
278 syncer_end_command.Execute(session); 286 syncer_end_command.Execute(session);
279 return; 287 return;
280 } 288 }
281 289
282 void Syncer::ProcessClientCommand(sessions::SyncSession* session) { 290 void Syncer::ProcessClientCommand(sessions::SyncSession* session) {
283 const ClientToServerResponse& response = 291 const ClientToServerResponse& response =
284 session->status_controller()->updates_response(); 292 session->status_controller()->updates_response();
285 if (!response.has_client_command()) 293 if (!response.has_client_command())
286 return; 294 return;
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
321 entry->Put(SERVER_CTIME, 0); 329 entry->Put(SERVER_CTIME, 0);
322 entry->Put(SERVER_VERSION, 0); 330 entry->Put(SERVER_VERSION, 0);
323 entry->Put(SERVER_IS_DIR, false); 331 entry->Put(SERVER_IS_DIR, false);
324 entry->Put(SERVER_IS_DEL, false); 332 entry->Put(SERVER_IS_DEL, false);
325 entry->Put(IS_UNAPPLIED_UPDATE, false); 333 entry->Put(IS_UNAPPLIED_UPDATE, false);
326 entry->Put(SERVER_SPECIFICS, sync_pb::EntitySpecifics::default_instance()); 334 entry->Put(SERVER_SPECIFICS, sync_pb::EntitySpecifics::default_instance());
327 entry->Put(SERVER_POSITION_IN_PARENT, 0); 335 entry->Put(SERVER_POSITION_IN_PARENT, 0);
328 } 336 }
329 337
330 } // namespace browser_sync 338 } // namespace browser_sync
OLDNEW
« no previous file with comments | « chrome/browser/sync/engine/syncapi_unittest.cc ('k') | chrome/browser/sync/engine/syncer_thread.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698