New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 695241 link

Starred by 4 users

Issue metadata

Status: WontFix
Owner:
Closed: Feb 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 2
Type: Feature



Sign in to add a comment

Enable Sessions Sync to record the source tab id of a given tab

Project Member Reported by pnoland@chromium.org, Feb 22 2017

Issue description

Currently, the source tab of a navigation that creates a new tab or window isn't known or knowable to Sessions Sync. The data is available, but it's not recorded anywhere that Sessions Sync can get to it.

To enable this, we need to calculate and store the source id for a given tab somewhere(most likely a TabHelper) and make it available to SessionsSyncManager. 

We should also remove the old NotificationServiceSessionRouter, since it relies on the Notifications API and will make it harder to track the source id.
 
Project Member

Comment 1 by bugdroid1@chromium.org, Mar 1 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/aa1ab1dc32ed1b5508c7b835085a503ea8d96280

commit aa1ab1dc32ed1b5508c7b835085a503ea8d96280
Author: sergeyu <sergeyu@chromium.org>
Date: Wed Mar 01 00:34:35 2017

Revert of [sync] Add Sessions integration tests (patchset #4 id:140001 of https://codereview.chromium.org/2713913002/ )

Reason for revert:
SingleClientSessionsSyncTest.CookieJarMismatch fails on mac:
https://build.chromium.org/p/chromium.mac/builders/Mac10.9%20Tests/builds/37124

Original issue's description:
> [sync] Add Sessions integration tests
>
> Add integration tests for a number of new scenarios:
> * Multi window, multi tab
> * Navigation hierarchy changes
> * Tab movement
>
> Add a new checker for waiting to see a SessionsHierarchy on
> the FakeServer. Refactor some existing tests to use this instead of
> waiting for sync cycle completion then manually verifying a match.
>
> Add several new helper methods to SessionsHelper, and refactor some
> existing ones.
>
> Add the ability to open a new Browser from an existing Profile
> to SyncTest.
>
> R=zea@chromium.org, skym@chromium.org
>
> BUG= 695241 
>
> Review-Url: https://codereview.chromium.org/2713913002
> Cr-Commit-Position: refs/heads/master@{#453687}
> Committed: https://chromium.googlesource.com/chromium/src/+/dd0356002ee91f25daa99dd147c57913517e9aab

TBR=zea@chromium.org,skym@chromium.org,pnoland@chromium.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG= 695241 

Review-Url: https://codereview.chromium.org/2722953002
Cr-Commit-Position: refs/heads/master@{#453773}

[delete] https://crrev.com/39f9eb3f5301f73d385c6d65601c60dba4fae63e/chrome/browser/sync/test/integration/session_hierarchy_match_checker.cc
[delete] https://crrev.com/39f9eb3f5301f73d385c6d65601c60dba4fae63e/chrome/browser/sync/test/integration/session_hierarchy_match_checker.h
[modify] https://crrev.com/aa1ab1dc32ed1b5508c7b835085a503ea8d96280/chrome/browser/sync/test/integration/sessions_helper.cc
[modify] https://crrev.com/aa1ab1dc32ed1b5508c7b835085a503ea8d96280/chrome/browser/sync/test/integration/sessions_helper.h
[modify] https://crrev.com/aa1ab1dc32ed1b5508c7b835085a503ea8d96280/chrome/browser/sync/test/integration/single_client_sessions_sync_test.cc
[modify] https://crrev.com/aa1ab1dc32ed1b5508c7b835085a503ea8d96280/chrome/browser/sync/test/integration/sync_test.cc
[modify] https://crrev.com/aa1ab1dc32ed1b5508c7b835085a503ea8d96280/chrome/browser/sync/test/integration/sync_test.h
[modify] https://crrev.com/aa1ab1dc32ed1b5508c7b835085a503ea8d96280/chrome/browser/sync/test/integration/two_client_sessions_sync_test.cc
[modify] https://crrev.com/aa1ab1dc32ed1b5508c7b835085a503ea8d96280/chrome/test/BUILD.gn
[modify] https://crrev.com/aa1ab1dc32ed1b5508c7b835085a503ea8d96280/components/sync/test/fake_server/sessions_hierarchy.cc
[modify] https://crrev.com/aa1ab1dc32ed1b5508c7b835085a503ea8d96280/components/sync/test/fake_server/sessions_hierarchy.h

Project Member

Comment 2 by bugdroid1@chromium.org, Mar 3 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/1a3b9e6a70c04989ec277114f50417164fc9f32f

commit 1a3b9e6a70c04989ec277114f50417164fc9f32f
Author: pnoland <pnoland@chromium.org>
Date: Fri Mar 03 02:51:56 2017

reland of [sync] Add Sessions integration tests

Add integration tests for a number of new scenarios:
* Multi window, multi tab
* Navigation hierarchy changes
* Tab movement

Add a new checker for waiting to see a SessionsHierarchy on
the FakeServer. Refactor some existing tests to use this instead of
waiting for sync cycle completion then manually verifying a match.

Add several new helper methods to SessionsHelper, and refactor some
existing ones.

Add the ability to open a new Browser from an existing Profile
to SyncTest.

R=zea@chromium.org, skym@chromium.org

BUG= 695241 

Review-Url: https://codereview.chromium.org/2725813003
Cr-Commit-Position: refs/heads/master@{#454481}

[add] https://crrev.com/1a3b9e6a70c04989ec277114f50417164fc9f32f/chrome/browser/sync/test/integration/session_hierarchy_match_checker.cc
[add] https://crrev.com/1a3b9e6a70c04989ec277114f50417164fc9f32f/chrome/browser/sync/test/integration/session_hierarchy_match_checker.h
[modify] https://crrev.com/1a3b9e6a70c04989ec277114f50417164fc9f32f/chrome/browser/sync/test/integration/sessions_helper.cc
[modify] https://crrev.com/1a3b9e6a70c04989ec277114f50417164fc9f32f/chrome/browser/sync/test/integration/sessions_helper.h
[modify] https://crrev.com/1a3b9e6a70c04989ec277114f50417164fc9f32f/chrome/browser/sync/test/integration/single_client_sessions_sync_test.cc
[modify] https://crrev.com/1a3b9e6a70c04989ec277114f50417164fc9f32f/chrome/browser/sync/test/integration/sync_test.cc
[modify] https://crrev.com/1a3b9e6a70c04989ec277114f50417164fc9f32f/chrome/browser/sync/test/integration/sync_test.h
[modify] https://crrev.com/1a3b9e6a70c04989ec277114f50417164fc9f32f/chrome/browser/sync/test/integration/two_client_sessions_sync_test.cc
[modify] https://crrev.com/1a3b9e6a70c04989ec277114f50417164fc9f32f/chrome/test/BUILD.gn
[modify] https://crrev.com/1a3b9e6a70c04989ec277114f50417164fc9f32f/components/sync/test/fake_server/sessions_hierarchy.cc
[modify] https://crrev.com/1a3b9e6a70c04989ec277114f50417164fc9f32f/components/sync/test/fake_server/sessions_hierarchy.h

Project Member

Comment 3 by bugdroid1@chromium.org, Mar 23 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/1901afa5e03bad9ce8a72691f746a685038241b0

commit 1901afa5e03bad9ce8a72691f746a685038241b0
Author: pnoland <pnoland@chromium.org>
Date: Thu Mar 23 21:24:00 2017

[sync] WebContentsObserver based sessions notifications

Aggregate individual WebContentsObservers to notify sync of sessions changes

This CL introduces the SyncSessionsWebContentsRouter and the
SyncSessionsRouterTabHelper, which replace the old
NotificationServiceSessionsRouter.  The SyncSessionsWebContentsRouter
aggregates events from the individual TabHelpers, which are scoped to
individual tabs, and pushes them to SessionsSyncManager.
SyncSessionsWebContentsRouters are given a source tab id property which
is set when a tab is created directly from another tab, e.g. by ctrl
clicking.
Some changes are made to SessionsHelper so that it can continue to
correctly wait for tabs to load without using Notifications.

R=zea@chromium.org
BUG= 695241 

Review-Url: https://codereview.chromium.org/2753753005
Cr-Commit-Position: refs/heads/master@{#459225}

[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/BUILD.gn
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/sync/chrome_sync_client.cc
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/sync/glue/synced_tab_delegate_android.cc
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/sync/glue/synced_tab_delegate_android.h
[add] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/sync/sessions/browser_list_router_helper.cc
[add] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/sync/sessions/browser_list_router_helper.h
[delete] https://crrev.com/5fbf7e618bca38528d65a5f673b030fb0b2cd684/chrome/browser/sync/sessions/notification_service_sessions_router.cc
[delete] https://crrev.com/5fbf7e618bca38528d65a5f673b030fb0b2cd684/chrome/browser/sync/sessions/notification_service_sessions_router.h
[add] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/sync/sessions/sync_sessions_router_tab_helper.cc
[add] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/sync/sessions/sync_sessions_router_tab_helper.h
[add] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/sync/sessions/sync_sessions_web_contents_router.cc
[add] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/sync/sessions/sync_sessions_web_contents_router.h
[add] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/sync/sessions/sync_sessions_web_contents_router_factory.cc
[add] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/sync/sessions/sync_sessions_web_contents_router_factory.h
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/sync/test/integration/sessions_helper.cc
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/sync/test/integration/sessions_helper.h
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/sync/test/integration/single_client_sessions_sync_test.cc
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/sync/test/integration/two_client_sessions_sync_test.cc
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/ui/cocoa/app_menu/app_menu_controller_unittest.mm
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/ui/sync/tab_contents_synced_tab_delegate.cc
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/ui/sync/tab_contents_synced_tab_delegate.h
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/ui/tab_helpers.cc
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/chrome/browser/ui/toolbar/recent_tabs_sub_menu_model_unittest.cc
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/components/browser_sync/profile_sync_service.cc
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/components/sync_sessions/fake_sync_sessions_client.cc
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/components/sync_sessions/fake_sync_sessions_client.h
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/components/sync_sessions/sessions_sync_manager.cc
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/components/sync_sessions/sessions_sync_manager.h
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/components/sync_sessions/sessions_sync_manager_unittest.cc
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/components/sync_sessions/sync_sessions_client.h
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/components/sync_sessions/synced_session_tracker.cc
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/components/sync_sessions/synced_session_tracker_unittest.cc
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/components/sync_sessions/synced_tab_delegate.h
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/components/sync_sessions/tab_node_pool.cc
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/components/sync_sessions/tab_node_pool.h
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/ios/chrome/browser/sync/ios_chrome_sync_client.mm
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/ios/chrome/browser/sync/ios_chrome_synced_tab_delegate.h
[modify] https://crrev.com/1901afa5e03bad9ce8a72691f746a685038241b0/ios/chrome/browser/sync/ios_chrome_synced_tab_delegate.mm

Status: Started (was: Assigned)

Comment 5 by zea@chromium.org, Apr 21 2017

Is this finished at this point?
It's not done for iOS, where the WebContentsObserver interface doesn't exist. Now that I finally have access to the iOS repo, I can add a limited equivalent. Limited because on iOS the opener relationship between tabs is only known when there's an explicit window.opener relationship. Given the re-prioritization of tasks-related work and the limited scope of the data, what priority does that have?
Cc: -zea@chromium.org
Owner: zea@chromium.org
Status: Available (was: Started)
Memex-related

Comment 8 by zea@chromium.org, Feb 6 2018

Status: WontFix (was: Available)

Sign in to add a comment