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

Issue 10835031: gdata: Trigger delta feed when search results contained unknown entries. (Closed)

Created:
8 years, 4 months ago by kinaba
Modified:
8 years, 4 months ago
Reviewers:
satorux1, tbarzic
CC:
chromium-reviews, achuith+watch_chromium.org, oshima+watch_chromium.org, stevenjb+watch_chromium.org, nkostylev+watch_chromium.org, davemoore+watch_chromium.org
Visibility:
Public.

Description

gdata: Trigger delta feed when search results contained unknown entries. If GData search done on the server contained entries that are not in the local snapshot of the file system, it typically indicates there exists a newly added entry on the server (but not notified to the local client). This CL requests a delta feed in such a case. Arrival of the delta feed is notified to the file manager, and the search result is re-queried. BUG=138786 TEST=manual (see the bug for repro steps). Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=149391

Patch Set 1 #

Total comments: 6

Patch Set 2 : Removed shared bool flag. Added a test. #

Patch Set 3 : Rebase. #

Total comments: 9

Patch Set 4 : Style fix + comment. #

Patch Set 5 : Rebase. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+48 lines, -7 lines) Patch
M chrome/browser/chromeos/gdata/gdata_file_system.cc View 1 2 3 4 2 chunks +10 lines, -2 lines 0 comments Download
M chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc View 1 2 3 4 1 chunk +35 lines, -2 lines 0 comments Download
A + chrome/test/data/chromeos/gdata/search_result_with_new_entry_feed.json View 1 2 chunks +3 lines, -3 lines 0 comments Download

Messages

Total messages: 8 (0 generated)
kinaba
## This patch needs http://codereview.chromium.org/10836005 for properly working. ## Satoru, Toni, could you give comments? ...
8 years, 4 months ago (2012-07-30 09:33:08 UTC) #1
satorux1
Can you write a test? http://codereview.chromium.org/10835031/diff/1/chrome/browser/chromeos/gdata/gdata_file_system.cc File chrome/browser/chromeos/gdata/gdata_file_system.cc (right): http://codereview.chromium.org/10835031/diff/1/chrome/browser/chromeos/gdata/gdata_file_system.cc#newcode451 chrome/browser/chromeos/gdata/gdata_file_system.cc:451: // |run_callback| is true. ...
8 years, 4 months ago (2012-07-30 10:17:17 UTC) #2
tbarzic
http://codereview.chromium.org/10835031/diff/1/chrome/browser/chromeos/gdata/gdata_file_system.cc File chrome/browser/chromeos/gdata/gdata_file_system.cc (right): http://codereview.chromium.org/10835031/diff/1/chrome/browser/chromeos/gdata/gdata_file_system.cc#newcode479 chrome/browser/chromeos/gdata/gdata_file_system.cc:479: delete entry_skipped; On 2012/07/30 10:17:18, satorux1 wrote: > does ...
8 years, 4 months ago (2012-07-30 23:32:33 UTC) #3
kinaba
http://codereview.chromium.org/10835031/diff/1/chrome/browser/chromeos/gdata/gdata_file_system.cc File chrome/browser/chromeos/gdata/gdata_file_system.cc (right): http://codereview.chromium.org/10835031/diff/1/chrome/browser/chromeos/gdata/gdata_file_system.cc#newcode451 chrome/browser/chromeos/gdata/gdata_file_system.cc:451: // |run_callback| is true. On 2012/07/30 10:17:18, satorux1 wrote: ...
8 years, 4 months ago (2012-07-31 08:46:04 UTC) #4
tbarzic
lgtm http://codereview.chromium.org/10835031/diff/1/chrome/browser/chromeos/gdata/gdata_file_system.cc File chrome/browser/chromeos/gdata/gdata_file_system.cc (right): http://codereview.chromium.org/10835031/diff/1/chrome/browser/chromeos/gdata/gdata_file_system.cc#newcode479 chrome/browser/chromeos/gdata/gdata_file_system.cc:479: delete entry_skipped; On 2012/07/31 08:46:04, kinaba wrote: > ...
8 years, 4 months ago (2012-07-31 17:43:25 UTC) #5
satorux1
http://codereview.chromium.org/10835031/diff/7002/chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc File chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc (right): http://codereview.chromium.org/10835031/diff/7002/chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc#newcode2424 chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc:2424: &message_loop_, expected_results, 2u); while you are at it, could ...
8 years, 4 months ago (2012-07-31 20:48:52 UTC) #6
satorux1
http://codereview.chromium.org/10835031/diff/7002/chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc File chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc (right): http://codereview.chromium.org/10835031/diff/7002/chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc#newcode2442 chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc:2442: // Only entries in the current file system snapshot ...
8 years, 4 months ago (2012-07-31 20:50:23 UTC) #7
kinaba
8 years, 4 months ago (2012-08-01 05:34:09 UTC) #8
http://codereview.chromium.org/10835031/diff/7002/chrome/browser/chromeos/gda...
File chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc (right):

http://codereview.chromium.org/10835031/diff/7002/chrome/browser/chromeos/gda...
chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc:2424:
&message_loop_, expected_results, 2u);
On 2012/07/31 20:48:52, satorux1 wrote:
> while you are at it, could you also fix this? see below

Done.

http://codereview.chromium.org/10835031/diff/7002/chrome/browser/chromeos/gda...
chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc:2442: // Only
entries in the current file system snapshot should be returned.
On 2012/07/31 20:50:23, satorux1 wrote:
> On 2012/07/31 20:48:52, satorux1 wrote:
> > I'm confused. I thought we wanted to include the newly added file in the
> search
> > result?
> 
> Looking at the patch description, we don't need to include the new added file
> here, as the arrival of the delta feed lets the file manager to do search
again?
> If so, LGTM. Please add some comment here, as it's a bit tricky.

Done.

http://codereview.chromium.org/10835031/diff/7002/chrome/browser/chromeos/gda...
chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc:2443: const
SearchResultPair expected_results[] = {
On 2012/07/31 20:48:52, satorux1 wrote:
> nit: kExpectedResults

Done.

http://codereview.chromium.org/10835031/diff/7002/chrome/browser/chromeos/gda...
chrome/browser/chromeos/gdata/gdata_file_system_unittest.cc:2454:
&message_loop_, expected_results, 1u);
On 2012/07/31 20:48:52, satorux1 wrote:
> 1u -> ARRAYSIZE_UNSAFE(kExpectedResults)

Done.

Powered by Google App Engine
This is Rietveld 408576698