• Xing Liu's avatar
    Background download: Retry when no response header is persisted. · 44dfb9f4
    Xing Liu authored
    We persist download response headers and url chain when
    OnDownloadCreated is called. This CL does the following:
    
    1. If the persist failed during ACTIVE state, delete the driver and the
    file to let the download service to retry.
    
    2. Change DownloadDriver::Remove to be able to remove file for completed
    download.
    
    3. Add did_receive_response in entry proto, since some protocol or
    a socket error may cause the response headers to be empty. We should
    validate the entry state with this flag instead of response headers.
    
    TBR=carlosk@chromium.org
    
    
    Bug: 883359, 881314
    Change-Id: I560cc478b5d1f12c33b56b94ee97cbb1d2b76c3d
    Reviewed-on: https://chromium-review.googlesource.com/1227290
    Commit-Queue: Xing Liu <xingliu@chromium.org>
    Reviewed-by: default avatarDavid Trainor <dtrainor@chromium.org>
    Reviewed-by: default avatarMin Qin <qinmin@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#592306}
    44dfb9f4
download_driver.h 4.22 KB