Re: nntpcache-0.87UL

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> 1. xover hangs
> > static int GetXover(int min, int max)
> > fprintf(CurrentCfg->fh, "xover %d-%d\r\n", min, max);
> > fflush(CurrentCfg->fh);
> There must be a fflush(CurrentCfg) after sending the xover to the
> news server.

This was a bad one, that only lasted a few minutes ;) the whole xover
system has been redesigned and optimised.

> 2. Database pruning corrupts the history
> > static char *hisPruneDbz(int newsize)
> > if (!(w=fopen(DBZ_HISTORY, "r+")))
> The output file (w) must be opened with 'r+' not with 'w'. Open in
> append mode does a seek(end) before each write.
> 
> 
> 3. Positioning on the next record failed
> > static char *hisPruneDbz(int newsize)
> >	if (isdigit(*buf))
> >		if (isdigit(*buf))
> The check should be on the next number. And after this, reading records
> seems ok.
> 

I'm in the process of totally re-writing the history stuff to use my
own circular static sized hash db (xovers are already done elsewhere now),
so all this will shortly become a non-issue. I never trusted it, and as
you have shown with good reason.

> 3. Forced expire won't run
> > X(bool expire(bool force))
> > if (!force && (ffree<BLOCKS_MIN_FREE || ffree<FILES_MIN_FREE))
> > if (force || ffree<BLOCKS_MIN_FREE || ffree<FILES_MIN_FREE)
> IMHO, the force parameter is checked wrong.

I did have a reason for doing this. I can't recall why now /* why not? /*.
I've changed it till I can remember.

> 4. Articles in article range won't expire
> > static int expire_arts()
> > if (artnum < low)
> > {
> > unlink(p);
> > Stats->expire_articles++;
> > }
> > /* continue; */
> I think the 'continue' is wrong. It goes direct to next article,
> and does't check the file times even if the article is in low-high
> range.

This was deliberate. expires are massively faster if you don't have to
stat all those articles that are unlikely to be expired. its presumed
that if .tide is uptodate and the article is active on the remote then
we don't want to expire it. I'll make this switchable for cases where
a hard limit beyond this is also desired.

> 5. Expire on CACHE_DIR
> Is it correct to do expire directly on CACHE_DIR. Maybe expire deletes
> the history database?

not an issue in practice because its updated so often. my solution is to
now check for a digit in the first position of the filename.

> 6. config file seems odd
> > #define HIS_HIGH_WATER 50*1024*1024
> > #define HIS_LOW_WATER 70*1024*1024
> Low water mark is greater than high water mark. Is this what you want?
> The fseek ( .. -newsize .. ) may fail.

definately wrong.

> 7. Uninitialised static vars
> sockets.h
> > static int Spos[255];
> > static char *Sbuf[255];
> Crashes on SunOS with gcc -O. All static vars should be explicit
> initialised.

I thought K&R defined all statics as automatically being null on first run?
I clear them all now just in case.

> You see many fixes. I think I deserve a small reward. A free site licence
> for our site (_not_ for the comany). Otherwise i must pay the licence from
> my own. My company is not able (or willing) to pay with cheque, or Credit
> Card. The company only pays bills (with a large overhead). You are making
> a commercial product with the help of other people, doing this in their
> free time.

Done in our free time too. The fees are an attempt to try an offset dev
costs (which they don't at all yet) Anyway your more than welcome to
have a free licence for yourself. If you can describe what your site
does and how many people work there, then we will probably agree to that
too.

> I additional have some questions.
> 
> Are you planning to implement an access logging feature? Like INN.
> Which user from which machine is reading what. Or calculating the
> traffic per connection. This would help some admins.

There is already fairly extensive logging/stats. Can you be more specific?

> When is the next release date? Did you fix other bugs?

Beta#2 is out now. lots of bug fixes. I haven't touched the history pruning
stuff because its going soon.

> Are you planning a mailinglist for NNTPCACHE?

	To: nntpcache-users-request@suburbia.net
	Subject: subscribe

is what you want.

Cheers,

-- 
"Of all tyrannies a tyranny sincerely  exercised for the good of its victims  
 may be the most  oppressive.  It may be better to live under  robber barons  
 than  under  omnipotent  moral busybodies,  The robber baron's  cruelty may  
 sometimes sleep,  his cupidity may at some point be satiated; but those who  
 torment us for own good  will torment us  without end,  for they do so with 
 the approval of their own conscience."    -   C.S. Lewis, _God in the Dock_ 
+---------------------+--------------------+----------------------------------+
|Julian Assange RSO   | PO Box 2031 BARKER | Secret Analytic Guy Union        |
|proff@suburbia.net   | VIC 3122 AUSTRALIA | finger for PGP key hash ID =     |
|proff@gnu.ai.mit.edu | FAX +61-3-98199066 | 0619737CCC143F6DEA73E27378933690 |
+---------------------+--------------------+----------------------------------+


[Index of Archives]     [Yosemite]     [Yosemite Campsites]     [Bugtraq]     [Linux]     [Trn]

Powered by Linux