New issue
Advanced search Search tips

Issue 745842 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Aug 2017
Components:
EstimatedDays: ----
NextAction: ----
OS: All
Pri: 1
Type: Bug


Participants' hotlists:
Downloads-Framework-Service


Sign in to add a comment

[Download Service] Notify clients before file will be deleted so they can optionally extend the window

Project Member Reported by dtrainor@chromium.org, Jul 18 2017

Issue description

Allow clients to optionally extend the window by saying that they still have a download job active.  This could look like the following Client API:

bool CanServiceRemoveDownloadedFile(const std::string& guid);
 
Owner: shaktisahu@chromium.org
Status: Assigned (was: Available)
Project Member

Comment 2 by bugdroid1@chromium.org, Aug 24 2017

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

commit b567f21841281780406a1658bfe097981b81104b
Author: Shakti Sahu <shaktisahu@chromium.org>
Date: Thu Aug 24 16:22:33 2017

Download Service : Extend file deletion window.

Added ability for clients to extend the file deletion window. A client
method CanServiceRemoveDownloadedFile() would be called before removing
the file. If client says no, we would extend the file lifetime by
another |file_keep_alive_time| unless the file has gotten too many
lifetimes which is tracked by another config
|max_file_keep_alive_time(default=7 days)|, in which case we would
forcefully delete the file regardless of the client's wish. A field
|keep_alive_until| was added to the Entry DB to keep this value.

Bug:  745842 
Change-Id: Ia208dd5dcb285fafc05d6beae5b3ae1fa5f5890e
Reviewed-on: https://chromium-review.googlesource.com/612741
Reviewed-by: Ilya Sherman <isherman@chromium.org>
Reviewed-by: Jian Li <jianli@chromium.org>
Reviewed-by: David Trainor <dtrainor@chromium.org>
Reviewed-by: Xing Liu <xingliu@chromium.org>
Commit-Queue: Shakti Sahu <shaktisahu@chromium.org>
Cr-Commit-Position: refs/heads/master@{#497076}
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/chrome/browser/offline_pages/prefetch/offline_prefetch_download_client.cc
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/chrome/browser/offline_pages/prefetch/offline_prefetch_download_client.h
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/config.cc
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/config.h
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/controller_impl.cc
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/controller_impl_unittest.cc
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/entry.cc
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/entry.h
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/file_monitor.h
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/file_monitor_impl.cc
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/file_monitor_impl.h
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/file_monitor_unittest.cc
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/proto/entry.proto
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/proto_conversions.cc
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/proto_conversions_unittest.cc
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/stats.cc
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/stats.h
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/test/empty_client.cc
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/test/empty_client.h
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/test/entry_utils.cc
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/test/entry_utils.h
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/internal/test/mock_client.h
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/components/download/public/client.h
[modify] https://crrev.com/b567f21841281780406a1658bfe097981b81104b/tools/metrics/histograms/histograms.xml

Status: Fixed (was: Assigned)

Sign in to add a comment