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

Issue 141893009: Create a new helper function to extract search terms from the URL irrespective of the availablility (Closed)

Created:
6 years, 10 months ago by kmadhusu
Modified:
6 years, 10 months ago
Reviewers:
samarth, Jered
CC:
chromium-reviews, davidben+watch_chromium.org, cbentzel+watch_chromium.org, skanuj+watch_chromium.org, melevin+watch_chromium.org, tburkard+watch_chromium.org, dhollowa+watch_chromium.org, dougw+watch_chromium.org, donnd+watch_chromium.org, dominich, gavinp+prer_chromium.org, dominich+watch_chromium.org, jfweitz+watch_chromium.org, David Black, samarth+watch_chromium.org, kmadhusu+watch_chromium.org
Visibility:
Public.

Description

Creates a new helper function to extract search terms from the URL irrespective of the availability of InstantExtendedEnabledParam. Previously, InstantSearchPrerenderer invoked chrome::GetSearchTermsFromURL() to extract search terms from the search page url. chrome::GetSearchTermsFromURL() returns a valid non-empty string iff the url has an InstantExtendedEnabledParam("&espv"). If the query extraction is turned off, the search request url will not have an InstantExtendedEnabledParam. In those cases, chrome::GetSearchTermsFromURL() returns an empty string to the InstantSearchPrerenderer. To extract search terms for InstantSearchPrerenderer, we should not depend on the query extraction flag or the Instant support state of the page. Follow up of crrev.com/151813002. BUG=none TEST=none Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=251234

Patch Set 1 #

Total comments: 10

Patch Set 2 : Rebase #

Patch Set 3 : Addressed comments #

Total comments: 13

Patch Set 4 : Rebase #

Patch Set 5 : Addressed comments. #

Total comments: 4

Patch Set 6 : Addressed comments #

Patch Set 7 : Rebase #

Total comments: 12

Patch Set 8 : Addressed comments #

Patch Set 9 : Rebase #

Patch Set 10 : Rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+145 lines, -45 lines) Patch
M chrome/browser/search/instant_unittest_base.h View 1 2 3 4 5 6 7 8 9 2 chunks +7 lines, -1 line 0 comments Download
M chrome/browser/search/instant_unittest_base.cc View 1 2 3 4 5 6 7 8 9 3 chunks +22 lines, -18 lines 0 comments Download
M chrome/browser/search/search.h View 1 2 3 4 5 6 7 8 1 chunk +9 lines, -5 lines 0 comments Download
M chrome/browser/search/search.cc View 1 2 3 4 5 6 7 8 5 chunks +17 lines, -13 lines 0 comments Download
M chrome/browser/search/search_unittest.cc View 1 2 3 4 5 6 7 8 1 chunk +50 lines, -0 lines 0 comments Download
M chrome/browser/ui/browser_instant_controller.cc View 1 2 3 4 5 6 7 2 chunks +6 lines, -3 lines 0 comments Download
M chrome/browser/ui/search/instant_search_prerenderer.cc View 1 2 1 chunk +2 lines, -1 line 0 comments Download
M chrome/browser/ui/search/instant_search_prerenderer_unittest.cc View 1 2 3 chunks +32 lines, -4 lines 0 comments Download

Messages

Total messages: 24 (0 generated)
kmadhusu
Please review. Thanks.
6 years, 10 months ago (2014-02-05 03:10:14 UTC) #1
samarth
Jered understands this code better.
6 years, 10 months ago (2014-02-05 21:18:54 UTC) #2
kmadhusu
jered@: PTAL. Thanks.
6 years, 10 months ago (2014-02-05 22:05:55 UTC) #3
Jered
Sorry for the slow response... https://codereview.chromium.org/141893009/diff/1/chrome/browser/search/instant_unittest_base.cc File chrome/browser/search/instant_unittest_base.cc (right): https://codereview.chromium.org/141893009/diff/1/chrome/browser/search/instant_unittest_base.cc#newcode53 chrome/browser/search/instant_unittest_base.cc:53: enable_query_extraction_ = false; Note ...
6 years, 10 months ago (2014-02-07 03:02:26 UTC) #4
kmadhusu
jered@: Addressed comments. PTAL. Thanks. https://codereview.chromium.org/141893009/diff/1/chrome/browser/search/instant_unittest_base.cc File chrome/browser/search/instant_unittest_base.cc (right): https://codereview.chromium.org/141893009/diff/1/chrome/browser/search/instant_unittest_base.cc#newcode53 chrome/browser/search/instant_unittest_base.cc:53: enable_query_extraction_ = false; On ...
6 years, 10 months ago (2014-02-11 01:40:02 UTC) #5
Jered
Thanks, this is much cleaner. Couple of minor comments. https://codereview.chromium.org/141893009/diff/650001/chrome/browser/search/search.cc File chrome/browser/search/search.cc (right): https://codereview.chromium.org/141893009/diff/650001/chrome/browser/search/search.cc#newcode206 chrome/browser/search/search.cc:206: ...
6 years, 10 months ago (2014-02-11 19:10:09 UTC) #6
kmadhusu
Addressed comments. PTAL. Thanks. https://codereview.chromium.org/141893009/diff/650001/chrome/browser/search/search.cc File chrome/browser/search/search.cc (right): https://codereview.chromium.org/141893009/diff/650001/chrome/browser/search/search.cc#newcode206 chrome/browser/search/search.cc:206: // Returns true if |url| ...
6 years, 10 months ago (2014-02-11 23:24:31 UTC) #7
Jered
https://codereview.chromium.org/141893009/diff/850001/chrome/browser/search/search.cc File chrome/browser/search/search.cc (right): https://codereview.chromium.org/141893009/diff/850001/chrome/browser/search/search.cc#newcode209 chrome/browser/search/search.cc:209: bool IsSuitableURLForInstantImpl(const GURL& url, nit: Either drop the Impl ...
6 years, 10 months ago (2014-02-11 23:33:28 UTC) #8
kmadhusu
https://codereview.chromium.org/141893009/diff/850001/chrome/browser/search/search.cc File chrome/browser/search/search.cc (right): https://codereview.chromium.org/141893009/diff/850001/chrome/browser/search/search.cc#newcode209 chrome/browser/search/search.cc:209: bool IsSuitableURLForInstantImpl(const GURL& url, On 2014/02/11 23:33:28, Jered wrote: ...
6 years, 10 months ago (2014-02-12 00:24:56 UTC) #9
Jered
On 2014/02/12 00:24:56, kmadhusu wrote: > https://codereview.chromium.org/141893009/diff/850001/chrome/browser/search/search.cc > File chrome/browser/search/search.cc (right): > > https://codereview.chromium.org/141893009/diff/850001/chrome/browser/search/search.cc#newcode209 > ...
6 years, 10 months ago (2014-02-12 00:54:21 UTC) #10
kmadhusu
Samarth: Do I need to wait for your LGTM stamp? Thanks.
6 years, 10 months ago (2014-02-12 17:30:15 UTC) #11
samarth
lgtm https://codereview.chromium.org/141893009/diff/960001/chrome/browser/search/instant_unittest_base.cc File chrome/browser/search/instant_unittest_base.cc (right): https://codereview.chromium.org/141893009/diff/960001/chrome/browser/search/instant_unittest_base.cc#newcode48 chrome/browser/search/instant_unittest_base.cc:48: "InstantExtended", "Group1 use_cacheable_ntp:0")); Hmm, I think this is ...
6 years, 10 months ago (2014-02-12 18:02:38 UTC) #12
kmadhusu
samarth@: Addressed comments. Thanks. https://codereview.chromium.org/141893009/diff/960001/chrome/browser/search/instant_unittest_base.cc File chrome/browser/search/instant_unittest_base.cc (right): https://codereview.chromium.org/141893009/diff/960001/chrome/browser/search/instant_unittest_base.cc#newcode48 chrome/browser/search/instant_unittest_base.cc:48: "InstantExtended", "Group1 use_cacheable_ntp:0")); On 2014/02/12 ...
6 years, 10 months ago (2014-02-12 19:58:07 UTC) #13
kmadhusu
The CQ bit was checked by kmadhusu@chromium.org
6 years, 10 months ago (2014-02-13 17:17:36 UTC) #14
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/kmadhusu@chromium.org/141893009/1250001
6 years, 10 months ago (2014-02-13 17:18:50 UTC) #15
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 10 months ago (2014-02-13 18:47:55 UTC) #16
commit-bot: I haz the power
Retried try job too often on win_rel for step(s) printing_unittests http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=win_rel&number=263536
6 years, 10 months ago (2014-02-13 18:47:56 UTC) #17
kmadhusu
The CQ bit was checked by kmadhusu@chromium.org
6 years, 10 months ago (2014-02-13 23:06:34 UTC) #18
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/kmadhusu@chromium.org/141893009/1250001
6 years, 10 months ago (2014-02-13 23:07:15 UTC) #19
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 10 months ago (2014-02-13 23:07:19 UTC) #20
commit-bot: I haz the power
Failed to apply patch for chrome/browser/search/instant_unittest_base.cc: While running patch -p1 --forward --force --no-backup-if-mismatch; patching file ...
6 years, 10 months ago (2014-02-13 23:07:23 UTC) #21
kmadhusu
The CQ bit was checked by kmadhusu@chromium.org
6 years, 10 months ago (2014-02-13 23:12:45 UTC) #22
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/kmadhusu@chromium.org/141893009/1590001
6 years, 10 months ago (2014-02-13 23:14:58 UTC) #23
commit-bot: I haz the power
6 years, 10 months ago (2014-02-14 02:40:26 UTC) #24
Message was sent while issue was closed.
Change committed as 251234

Powered by Google App Engine
This is Rietveld 408576698