On Friday 05 October 2001 00:10, you wrote:
> ----- Original Message -----
> From: "thelema" <thelema at mh246001.truman.edu>
> To: <devl at freenetproject.org>
> Sent: Thursday, October 04, 2001 10:50 PM
> Subject: Re: [freenet-devl] FCPtools now with AutoSplit support
>
> > (hopefully) exactly as you would expect:
> > SplitFile.Size=&lt;hex file size>
> > SplitFile.BlockCount=&lt;hex no. of data blocks>
> > [SplitFile.BlockSize=&lt;hex size of each data block in bytes>]
> > [SplitFile.CheckBlockCount=&lt;hex. no of check blocks>]
> > SplitFile.Block.&lt;n>=&lt;URI>
> > [SplitFile.Graph.&lt;x>=a,b,c...]
>
> SplitFile.BlockSize is useless. 
No, it is not useless.  If the insert client declares the blocksize, then the 
request client knows that the splitfile has fixed size blocks.  If it is not
explictly declared the request client can't assume anything, because the
splitfile might have been inserted with variable sized blocks.

The idea of forcing any arbitrary constraints on block sizes appears to
be hugely unpopular.

>The standard case, which BlockSize is given
> for, can be quite easily figured out without specifying it in the fieldset.
> The standard case is that every file is of the same size, a power of two,
> except the last one which is smaller.
>
> To figure out the Blocksize from just SplitFile.Size and
> SplitFile.BlockCount, use the following function (which i'm fairly sure is
> correct:
>
> blocksize = 2 ** ceiling(log(size / numblocks)/log(2))
This doesn't allow you to figure out what the block size *is* only what
it *should be*.  Crappy insert clients will do all kinds of horrible things.
We should make it easy for them to do the right thing.

>
> On the other hand, i can see quite a bit of good coming out of:
> [SplitFile.Block.<n>.Size=<hex size of the block>]
In principle this appears a good idea.  In practice, it will most often not 
be used and seems too vociferous.

>
> > For SplitFiles with a fixed block size, we recommend including this
> > information as it'll make resuming transfers <emphasis>much</emphasis>
> > easier.  The last block in the splitfile doesn't have to be the same
> > size as the rest of the blocks, i.e. you don't need to pad the last
> > block to use this option.
>
> We could even then get rid of some of this text. :) We'd have to include
> the above algorithm though or a corrected version of it
>
Making things look good is not important.  Making things good is.

> > Thelema
> > --
> > E-mail: thelema314 at bigfoot.com        If you love something, set it free.
> > GPG 1536g/B9C5D1F7 fpr:075A A3F7 F70B 1397 345D  A67E 70AA 820B A806 F95D
>
> -Mathew
>
>
> _______________________________________________
> Devl mailing list
> Devl at freenetproject.org
> http://lists.freenetproject.org/mailman/listinfo/devl

-- 
Freesites
(0.3) freenet:MSK at SSK@enI8YFo3gj8UVh-Au0HpKMftf6QQAgE/homepage//
(0.4) freenet:SSK at npfV5XQijFkF6sXZvuO0o~kG4wEPAgM/homepage//

_______________________________________________
Devl mailing list
Devl at freenetproject.org
http://lists.freenetproject.org/mailman/listinfo/devl

Reply via email to