darcs

Patch 1138 resolve issue2379: only use packs to copy pristine whe...

Title resolve issue2379: only use packs to copy pristine whe...
Superseder Nosy List gh
Related Issues
Status accepted Assigned To
Milestone

Created on 2014-04-18.20:53:37 by gh, last changed 2014-05-04.20:03:11 by gh.

Files
File name Status Uploaded Type Edit Remove
patch-preview.txt gh, 2014-04-18.20:53:36 text/x-darcs-patch
patch-preview.txt gh, 2014-04-19.22:29:26 text/x-darcs-patch
resolve-issue2379_-only-use-packs-to-copy-pristine-when-up_to_date.dpatch gh, 2014-04-18.20:53:36 application/x-darcs-patch
resolve-issue2379_-only-use-packs-to-copy-pristine-when-up_to_date.dpatch gh, 2014-04-19.22:29:26 application/x-darcs-patch
unnamed gh, 2014-04-18.20:53:36
unnamed gh, 2014-04-19.22:29:26
See mailing list archives for discussion on individual patches.
Messages
msg17357 (view) Author: gh Date: 2014-04-18.20:53:36
This patch rearranges functions of Darcs.Repository as follows:

if remote is old-fashioned
 then fetch it in a specific way
 else
  if remote has up-to-date packs
   then fetch basic repo with pack (*)
   else fetch basic repo normally
  if not lazy cloning
   then
     if remote has packs
      then fetch complete repo with pack
      ele  fetch complete repo normally
   
Tests pass and some real-world examples I've tried also. I'm waiting
until tomorrow before screening it in case someone realizes this is
wrong.

I guess we could change (*) in the future so that cloning the basic remote
repo with packs be done without any patch application, but by fetching
both pack and pristine files in parallel.

1 patch for repository http://darcs.net:

Fri Apr 18 17:46:21 ART 2014  Guillaume Hoffmann <guillaumh@gmail.com>
  * resolve issue2379: only use packs to copy pristine when up-to-date
  
  When creating packs, save pristine hash to _darcs/packs/pristine
  If basic pack is outdated, do not fetch it, but fetch patches pack
  anyway.
  In Darcs.Repository, separate functions between the ones that fetch
  basic repository and complete repository (packed or not), and
  separate function that clones old-fashioned repositories.
Attachments
msg17367 (view) Author: gh Date: 2014-04-19.22:29:26
I'm screening this (slightly) updated version.

http shell tests pass.

1 patch for repository http://darcs.net:

Sat Apr 19 17:06:43 ART 2014  Guillaume Hoffmann <guillaumh@gmail.com>
  * resolve issue2379: only use packs to copy pristine when up-to-date
  
  When creating packs, save pristine hash to _darcs/packs/pristine
  If basic pack is outdated, do not fetch it, but fetch patches pack
  anyway.
  In Darcs.Repository, separate functions between the ones that fetch
  basic repository and complete repository (packed or not), and
  separate function that clones old-fashioned repositories.
Attachments
msg17422 (view) Author: gh Date: 2014-05-04.20:03:11
Self-accept.
History
Date User Action Args
2014-04-18 20:53:37ghcreate
2014-04-19 22:29:26ghsetfiles: + patch-preview.txt, resolve-issue2379_-only-use-packs-to-copy-pristine-when-up_to_date.dpatch, unnamed
messages: + msg17367
2014-04-25 18:08:08ghsetstatus: needs-screening -> needs-review
2014-05-04 20:03:11ghsetstatus: needs-review -> accepted
messages: + msg17422