taskmldonkey, a multi-networks file-sharing client - Tasks: task #4755, BT: support for partial download


You are not allowed to post comments on this tracker with your current authentification level.

task #4755: BT: support for partial download

Submitted by:  Joakim Verona <jave>
Submitted on:  Fri Oct 7 13:11:40 2005  
Votes:  335  
Category: Bittorrent-PluginPriority: 7 - High
Status: DoneAssigned to: ygrek <ygrek>
Open/Closed: ClosedShould Start On: Fri Oct 7 00:00:00 2005
Should be Finished on: Fri Oct 7 00:00:00 2005

(Jump to the original submission Jump to the original submission)

Sat Jan 22 22:57:35 2011, comment #19:


Please, do not post any new comments to this item.

ygrek <ygrek>
Project MemberIn charge of this item.
Sat Jan 22 22:55:57 2011, comment #18:

Patch updated to make html interface useable. Partial files are not commited - imho this is the only sane solution in case user wants to download some more files later. Location in temp dir is shown so that user can easily locate downloaded subfile.

ygrek <ygrek>
Project MemberIn charge of this item.
Thu May 13 19:10:33 2010, comment #17:

prio17 - fix compilation with Makefile (I was using ocamlbuild which automatically discovered dependencies and didn't notice breakage), thx Paranoik.

(file #20532)

ygrek <ygrek>
Project MemberIn charge of this item.
Wed May 12 22:01:38 2010, comment #16:

version 16:
- store/restore priority intervals from settings
- hide debug_set_download_prio command
- add rudimentary html interface to manage subfile priorities
- convert tabs to spaces in code

NB Seems like partial downloads do not get commited

(file #20526)

ygrek <ygrek>
Project MemberIn charge of this item.
Mon Apr 5 21:07:20 2010, comment #15:

This patch badly needs testing and feedback!

ygrek <ygrek>
Project MemberIn charge of this item.
 Spam posted by oyunlar35
 Spam posted by fctom
 Spam posted by dimon1
Sun Dec 16 11:40:30 2007, comment #14:

so.. noone working on this i suppose?

Anton Romanov <theli>
Mon Jun 18 07:17:16 2007, comment #13:

this patch is broken after patch #6005

unease <unease>
Thu Jun 14 08:27:37 2007, comment #12:

hi I tested this patch (waiting for this so long)... but it seems priorities gone after mlnet kill... And also If I have some time I would like to make some cosmetic HTML corrections to this patch... Should I wait for apply ? or can I change now ?

unease <unease>
Sun Aug 27 14:48:41 2006, comment #11:

Minimally updated for CVS.

With WIP10 commited to CVS, I hope I didn't forget anything :/

pango <mlpango>
Project Member
Wed Jun 28 22:35:23 2006, comment #10:

Updated for CVS (minimal update, I hope everything's alright)

pango <mlpango>
Project Member
Sun Jun 11 11:49:42 2006, comment #9:

Updated for current CVS HEAD

pango <mlpango>
Project Member
Wed Jun 7 08:46:29 2006, comment #8:

Updated for current CVS

pango <mlpango>
Project Member
Sat May 27 07:52:21 2006, comment #7:

pango has updated the prio patch for wip4a, which is now in CVS.
This means the prio patch now applies over plain cvs.

This version also adds logic to make the priority bitmap be
recalculated on "merge" commands.

Note that prio '0' blocks will never download, but lower prio blocks
MIGHT download before higher prio blocks, if no lower prio blocks were
available at the time of block selection.

Also note that the UI will definitively change, probably in way to be
compatible with main file priorities.

The current patch has only recevied light testing.

Joakim Verona <jave>
Project Member
Fri May 12 11:36:17 2006, comment #6:

v8 should apply to wip3e'.
It is also more efficient, because the linear scan is avoided.

Joakim Verona <jave>
Project Member
Thu Apr 20 13:57:27 2006, comment #5:

This 6th version of the prio patch supports:
- setting of priority on individual blocks
- setting of priorities on subfiles in a multifile torrent
- better view of subfile download progress

I renamed the commands:
debug_set_download_prio - for blocks
debug_get_download_prio - return block prio and download status
debug_set_subfile_prio - operate on subfile level instead

Please read the help strings for the commands for details.

You must apply pango:s WIP3C patch before! WIP3C contains an important
bugfix in commonswarming, and the prio patch wont work without it.
(this is of course true only until WIP3C is applied to cvs)

the prio patch is furthermore tested with the "multiuser" patch, but
probably works withouth it as well.

there are some currently known problems:
- if you "merge" 2 downloads, the priority system will most probably

- block priorities doesnt survive core restarts

- a file is commited as soon as all non-zero prio blocks are
downloaded. This means that its possible for junk to be commited. You
are expected to know about this and remove junk files yourself. I'm
not sure I'm interested in "fixing" this, since there are no good
solutions in the general case.

Also, the implementation isnt the most efficient, but in practice it
doesnt seem to affect performance much for me at least. (there is a
linear block scan to determine if a block should be downloaded or not)

Furthermore the previous "download first" code, which hardcoded high
priorities for the first and last blocks of a file is removed by this

you can recreate the behaviour by setting higher prios for those
blocks with the commands.

Finally a warning: its not obvious to me that its good for the
networks and/or your average download speed to mess with block
priorities. Is it, for instance "fair" to download a single file of a
multifile torrent and then jump out?

In practice it appears to work well though.

Joakim Verona <jave>
Project Member
Wed Apr 12 19:12:37 2006, comment #4:

better bt subfile view support

Joakim Verona <jave>
Project Member
Mon Apr 10 12:01:37 2006, comment #3:

new patch applies to plain cvs as of today

Joakim Verona <jave>
Project Member
Sun Apr 9 21:19:16 2006, comment #2:

this 1st version of the patch is already usable in a primitive way.

for instance:

dllink lalala.torrent
(gets id 528)

debug_set_download_priorities 528 666666666666666666655555555555555555555555555555555554444444444444444444444444444444433333333333333333333333333333333333222222222222222222222222222222222221111111111111111111111111111111111

(the long string matches the chunk bitmap you see with "vd 528" in
telnet interface. the numbers are priorities. 6 will go before 5
etc. 0 wont download at all)

i tried a couple of files and it seems to work nicely. good for
listening to mp3:s while they are dowloading.

currently you have to figure out which chunks correspond to a certain
file in a bt multipart if thats what you want to do.

Joakim Verona <jave>
Project Member
Thu Apr 6 09:51:59 2006, comment #1:

same as #4851

Joakim Verona <jave>
Project Member
Fri Oct 7 13:11:40 2005, original submission:

heres a little implementation plan:

- get all chunks for a file from its "swarmer" see chunk status

- add "want to download" chunk list to swarmer, add it to chunk
download prioritizing logic, never ask for unintersting chunks.

- since we newer download unwanted chunks, we wil not faultily claim we have them to peers either

- when chunks are downloaded they ought to wind up in their correct file as usual. space will be wasted during download, because ill keep
space for all files anyway, and chunks spanning file boundaries will
go into the unwanted files. this is no big deal i think. and its good
if we change our mind of which files to download while downloading.

- make a command that sets the "want to download" chunk list given a
partial file id, something like:

want_partial_file A B C
where A is themain download id number , B is the sub-file number, and
C is the true/false if we want the file or not.

Joakim Verona <jave>
Project Member


No files currently attached


   patch dependencies.

Items that depend on this one: None found


Carbon-Copy List
  • -unavailable- added by balamutick (Voted in favor of this item)
  • -unavailable- added by ygrek (Posted a comment)
  • -unavailable- added by kindacute (Voted in favor of this item)
  • -unavailable- added by oyunlar35 (Posted a comment)
  • -unavailable- added by lapo (Voted in favor of this item)
  • -unavailable- added by karl (Updated the item)
  • -unavailable- added by fctom (Posted a comment)
  • -unavailable- added by dimon1 (Posted a comment)
  • -unavailable- added by loc (Voted in favor of this item)
  • -unavailable- added by theli (Posted a comment)
  • -unavailable- added by theli
  • -unavailable- added by unease (Posted a comment)
  • -unavailable- added by spiralvoice (Updated the item)

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 335 encouragements so far.

    Only logged-in users can vote.


    Please enter the title of George Orwell's famous dystopian book (it's a date):



    Follow 25 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Mon Jan 31 17:31:16 2011spiralvoiceStatusReady For Test=>Done
    Sat Jan 22 23:00:38 2011ygrekOpen/ClosedClosed=>Open
      SummaryReassigned to another tracker [was: BT: support for partial download]=>BT: support for partial download
      Dependencies-=>Depends on patch #7448
    Sat Jan 22 22:57:35 2011ygrekReassign Itemmldonkey, a multi-networks file-sharing client, task #4755=>mldonkey, a multi-networks file-sharing client, patch #7448
    Sat Jan 22 22:56:32 2011ygrekAttached File-=>Added prio18.patch, #22496
    Sat Jan 22 22:55:57 2011ygrekPriority1 - Later=>7 - High
      StatusNone=>Ready For Test
      Assigned toNone=>ygrek
    Fri Oct 1 17:51:50 2010balamutickCarbon-Copy-=>Added balamutick
    Thu May 13 19:10:33 2010ygrekAttached File-=>Added prio17.patch, #20532
    Wed May 12 22:01:38 2010ygrekAttached File-=>Added prio16.patch, #20526
    Wed Jan 27 09:17:38 2010kindacuteCarbon-Copy-=>Added kindacute
    Thu Aug 13 06:08:19 2009lapoCarbon-Copy-=>Added lapo
    Thu Apr 9 15:26:04 2009spiralvoiceDiscussion LockLocked=>Unlocked
    Wed Jan 14 13:30:06 2009karlOpen/ClosedClosed=>Open
    Wed Jan 14 13:28:08 2009karlOpen/ClosedOpen=>Closed
      Discussion LockUnlocked=>Locked
    Mon Jul 7 09:32:33 2008locCarbon-Copy-=>Added loc
    Sun Dec 16 11:40:30 2007theliCarbon-Copy-=>Added -unavailable-
    Mon Jun 18 16:28:41 2007spiralvoiceAttached File-=>Added prio15.patch, #13094
    Thu Jun 14 09:22:05 2007uneaseCarbon-Copy-=>Added unease
    Mon Jun 4 22:11:19 2007spiralvoiceAttached File-=>Added prio14.patch, #12948
    Tue Feb 20 18:56:26 2007theliCarbon-CopyRemoved -unavailable-=>-

    Back to the top

    Powered by Savane 3.1-cleanup1