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

Issue 608714 link

Starred by 1 user

Issue metadata

Status: WontFix
Owner:
Closed: Apr 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 2
Type: Bug



Sign in to add a comment

Remove visited/visible suggestions from incoming snippets

Project Member Reported by nepper@chromium.org, May 3 2016

Issue description

When we retrieve a new chunk of snippets, we should remove:
- snippets that are already existing on the client (in the current set of snippets on the client)
- snippets that have already been visited (according to local  browsing history and the visited state of snippets in the current set of snippets on the client)
 

Comment 1 by treib@chromium.org, May 3 2016

The first is already implemented.
Awesome :)
(Note that we don't have an explicit visited state, we just rely on the history DB. We do have code in SnippetsService already though that looks up a URL in the history DB).
So, are the following both implemented already?

- snippets that are already existing on the client (in the current set of snippets on the client)
- snippets that have already been visited (according to local  browsing history and the visited state of snippets in the current set of snippets on the client)

Comment 5 by nepper@chromium.org, Jun 13 2016

Cc: jkrcal@chromium.org
Jan, another candidate to look into.

Comment 6 by jkrcal@chromium.org, Jun 14 2016

Bernhard, I can't see the function that you mention in ntp_snippets_service. 
Is it gone in the meantime?

Comment 8 by jkrcal@chromium.org, Jun 14 2016

Thanks!

I'd move it to SnippetsService then (and call the SnippetsService from the bridge).

Comment 9 by jkrcal@chromium.org, Jun 14 2016

Hmm, HistoryService provides only asynchronous querying API.
This seems like an indication that it is not always super fast.

From the requirements here it seems to me that the only way to implement it is:
 - when new snippets are loaded (such as on service initialization), send the queries to HistoryService,
 - wait for all the queries to finish,
 - delete all visited snippets (based on responses from queries),
 - do further work (such as delete snippets at the end of the list if we have too many of them),
 - only now inform all observers (such as the UI) that new snippets have been loaded.

On random refetch in the background this seems okay.
Is this accaptable during initialization of the service?
Well, HistoryService needs to check with a database, which might incur disk access, which is why it happens in the background. OTOH, loading snippets from _their_ database might also need to access the disk, so I don't think an additional thread jump + blocking read would be that bad. 
Cc: -jkrcal@chromium.org
Labels: zine-mr-iter-21
Owner: jkrcal@chromium.org
Status: Started (was: Available)
Most probably cannot make it before the BP.
Labels: zine-16-06-27
Labels: -zine-mr-mile-v1.1 zine-articles-v1
Labels: -M-53 M-54
Status: Assigned (was: Started)
I was dragged away by other tasks. Now I wait for the new ContentSuggestionService / new ArticleSuggestionProvider to stabilize so that I can do the work there.
Did not touch it this week. I would like to first move forward the more important stuff (bookmarks, scaling zine).

Comment 18 by fi...@chromium.org, Jul 29 2016

Labels: zine-triaged
Labels: zine-pm
I have not started on this, yet. 
This would consume a lot of my time until BP.

I do not feel very motivated because I see quite some more important tasks until BP and because the conceptual way is to filter these on the server anyway.

What do you think?
Labels: -zine-pm
it's a P2, that's ok. My understanding is that we already remove Snippets that are already present on the device, so no duplicates. Correct?

Removing Snippets that have been visited previously is a P2.

Comment 21 by treib@chromium.org, Aug 10 2016

Labels: -M-54
Yes, we do filter duplicates on the client.
Since the whole "removing already-visited suggestions" IMO requires more discussion, removing milestone.
As there were no discussions around this in last months, does anyone oppose to marking this as WontFix?
Status: WontFix (was: Assigned)

Sign in to add a comment