Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Merge to M101][Topics] Implement BrowsingTopicsServiceImpl
- Implement the BrowsingTopicsServiceImpl responsible for scheduling the topics calculation, observing and handling history/cookies deletion, and calculating the topics for the JS API and for the UX. - Integrate with the renderer side API. - Update the BrowsingTopicsSiteDataManager/Storage::OnBrowsingTopicsApiUsed API() to let it get the timestamp from the main thread and pass it to the backend thread. This way, it's consistent with the query operation, so that there's no races (i.e. a Query(/*end_time=*/Now()) is guaranteed to return previously stored entries). - Update model_version type from "int" to "int64_t": the model version is expected to exceed the limit of int (i.e. it's using the timestamp). (cherry picked from commit cc37939) Binary-Size: Size increase is unavoidable due to new feature. Bug: 1310012 Change-Id: I45bc0ff3e7b8e9df28c940d14a95f076d9a69944 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3526273 Reviewed-by: Josh Karlin <jkarlin@chromium.org> Reviewed-by: Daniel Cheng <dcheng@chromium.org> Reviewed-by: Avi Drissman <avi@chromium.org> Commit-Queue: Yao Xiao <yaoxia@chromium.org> Cr-Original-Commit-Position: refs/heads/main@{#985500} Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3552463 Reviewed-by: Yao Xiao <yaoxia@chromium.org> Cr-Commit-Position: refs/branch-heads/4951@{#220} Cr-Branched-From: 27de622-refs/heads/main@{#982481}
- Loading branch information
1 parent
b00be27
commit f230ea6
Showing
52 changed files
with
3,591 additions
and
182 deletions.
There are no files selected for viewing
567 changes: 554 additions & 13 deletions
567
chrome/browser/browsing_topics/browsing_topics_service_browsertest.cc
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 2 additions & 0 deletions
2
chrome/test/data/browsing_topics/one_iframe_page_sandboxed.html.mock-http-headers
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
HTTP/1.1 200 OK | ||
Content-Security-Policy: sandbox allow-scripts; |
6 changes: 6 additions & 0 deletions
6
chrome/test/data/browsing_topics/one_sandboxed_iframe_page.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<body> | ||
<iframe src="empty_page.html" sandbox="allow-scripts" id="frame"></iframe> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.