aMule Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

We're back! (IN POG FORM)

Author Topic: Completeness of files  (Read 2299 times)

morph

  • Full Member
  • ***
  • Karma: 2
  • Offline Offline
  • Posts: 213
    • http://matrixhasu.altervista.org/
Completeness of files
« on: May 26, 2006, 08:21:58 PM »

Hi all,
I don't know where to post this, so I'm posting here  8)

I'd like to talk about completeness of shared files. As of now, files is marked as complete, if there exists a "really" complete file somewhere.

But the following situations are in a middle-of-nowhere:

Code: [Select]
O = completed chunk
x = missing chunk

[00xxx00x0]
[x00000x00]
-----------
[121112112] sum of available chunk

[xxxxxx00x]
[0000000x0]
-----------
[111111211]

(hope it's clear enough).

Here is the intersection of available chunks that lead to a completed source.

I understand that a completed file somewhere is rather different from those situation, but should they be highlighted somehow?

Cheers,
Sandro
Logged

wuischke

  • Developer
  • Hero Member
  • *****
  • Karma: 183
  • Offline Offline
  • Posts: 4292
Re: Completeness of files
« Reply #1 on: May 26, 2006, 08:41:59 PM »

In other words, you want to check whether 100% of a file are available or whether it's a dead file?

Something like this is already implemented in the code:
PartFile.cpp lines 1764 - 1775
Code: [Select]
// Find number of available parts
uint16 availablecounter = 0;
for ( uint16 i = 0; i < partcount; ++i ) {
if ( m_SrcpartFrequency[i] )
++availablecounter;
}

if ( ( availablecounter == partcount ) && ( m_availablePartsCount < partcount ) ) {
lastseencomplete = time(NULL);
}

m_availablePartsCount = availablecounter;
(It's used for the 'last seen complete' - column in the transfer-window.)
Logged

morph

  • Full Member
  • ***
  • Karma: 2
  • Offline Offline
  • Posts: 213
    • http://matrixhasu.altervista.org/
Re: Completeness of files
« Reply #2 on: May 27, 2006, 12:43:31 AM »

my question rose because amulegui doesnt show as complete (column 'last seen complete' set to 'Unknown') a file that match the second pattern show above. I'm using cvs-20060525 snapshot. Dont know what to say....
Logged

Vollstrecker

  • Administrator
  • Hero Member
  • *****
  • Karma: 67
  • Offline Offline
  • Posts: 1551
  • Unofficial Debian Packager
    • http://vollstreckernet.de
Re: Completeness of files
« Reply #3 on: May 27, 2006, 01:25:43 AM »

I can't look now, but iirc I have a file 56% completet, and one other source has something around 52%. The file is complete, but shown as last seen complete somewhere in the middle of the last year. I can't look before tommorow evening, but iirc it's like I said.
Logged
Homefucking is killing prostitution

wuischke

  • Developer
  • Hero Member
  • *****
  • Karma: 183
  • Offline Offline
  • Posts: 4292
Re: Completeness of files
« Reply #4 on: May 27, 2006, 10:00:56 AM »

Quote
Originally posted by morph
my question rose because amulegui doesnt show as complete (column 'last seen complete' set to 'Unknown') a file that match the second pattern show above. I'm using cvs-20060525 snapshot. Dont know what to say....
I can just guess, that this is one of the features which are not implemented in amulegui yet.

I'm too lazy to take a look in the code right now, but a file which has some 100% sources shows yesterday afternoon as the last seen complete date. Therefore it's probably checked periodically, but I don't have a clue in which time span.
Logged