🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nntp
3 messages
3 total messages Started by Julien ÉLIE Thu, 22 Oct 2009 20:26
First article after a GROUP selection
#82037
Author: Julien ÉLIE
Date: Thu, 22 Oct 2009 20:26
44 lines
2693 bytes
Hi,

GROUP fr.test
211 7226 3146 11068 fr.test
STAT
423 Bad article number
NEXT
223 3156 <fgpu2o$f9c$1@netfinity.fr> Article retrieved; request text separately
LAST
422 No previous article to retrieve


According to RFC 3977:

   The successful selection response will return the article numbers of
   the first and last articles in the group at the moment of selection
   (these numbers are referred to as the "reported low water mark" and
   the "reported high water mark") and an estimate of the number of
   articles in the group currently available.

   [...]

   When a valid group is selected by means of this command, the
   currently selected newsgroup MUST be set to that group, and the
   current article number MUST be set to the first article in the group
   (this applies even if the group is already the currently selected
   newsgroup).  If an empty newsgroup is selected, the current article
   number is made invalid.  If an invalid group is specified, the
   currently selected newsgroup and current article number MUST NOT be
   changed.



When we speak about "reported low water mark" and "first article in
the group", is it the same notion?
That is to say, is the above sample with 3146 as the low water mark,
right?  Is the article number to be set to 3146 after GROUP or LISTGROUP?
(And not 3156, the real first article?)

-- 
Julien ÉLIE

« Tempora si fuerint nubila, solus eris. » (Ovide) 
Re: First article after a GROUP selection
#82038
Author: Curt Welch
Date: Thu, 22 Oct 2009 21:10
67 lines
4676 bytes
=?iso-8859-15?Q?Julien_=C9LIE?= <iulius@nom-de-mon-site.com.invalid> wrote:
> Hi,
>
> GROUP fr.test
> 211 7226 3146 11068 fr.test
> STAT
> 423 Bad article number
> NEXT
> 223 3156 <fgpu2o$f9c$1@netfinity.fr> Article retrieved; request text
> separately LAST
> 422 No previous article to retrieve
>
> According to RFC 3977:
>
>    The successful selection response will return the article numbers of
>    the first and last articles in the group at the moment of selection
>    (these numbers are referred to as the "reported low water mark" and
>    the "reported high water mark") and an estimate of the number of
>    articles in the group currently available.
>
>    [...]
>
>    When a valid group is selected by means of this command, the
>    currently selected newsgroup MUST be set to that group, and the
>    current article number MUST be set to the first article in the group
>    (this applies even if the group is already the currently selected
>    newsgroup).  If an empty newsgroup is selected, the current article
>    number is made invalid.  If an invalid group is specified, the
>    currently selected newsgroup and current article number MUST NOT be
>    changed.
>
> When we speak about "reported low water mark" and "first article in
> the group", is it the same notion?
> That is to say, is the above sample with 3146 as the low water mark,
> right?  Is the article number to be set to 3146 after GROUP or LISTGROUP?
> (And not 3156, the real first article?)

I would say that if 3156 was the first valid article, that is what the low
water mark should be and what GROUP should have returned.  I thought that's
how it was expected to work.

The reality is that the low and high water mark are, for practical reasons,
only approximations because they can be, and sometimes actually are,
changing faster than you issue two NNTP commands.  So in the above example
you gave, we don't know for sure the server returned the wrong number.

In your above example, did the software report the wrong value, or was 3146
a valid number at the time of the GROUP command, but had expired, or had
been canceled, before you issued the STAT command?  We can't tell from you
example above alone.  If you issue the group command again after the the
above sequence, and it is still reporting 3146 as the low water mark, then
we know that it's not doing as good of a job as it could be.  However,
there is no strict requirement (in my view of practical issues) that the
low water mark actually be the first valid article in the group.

In today's distributed servers, it's actually quite a lot of work to get
the low water mark synchronized in near real time to the articles being
expired on the spool servers.  Some systems just don't attempt to do it in
real time and instead, update the low water marks as a periodic batch job
(that might run even less than once a day).  It takes a lot of IO to
accurately track the low water mark with the expiration of the articles in
a distributed systems and many have simply stopped trying in order to
reduce that load.

-- 
Curt Welch                                            http://CurtWelch.Com/
curt@kcwc.com                                        http://NewsReader.Com/
Re: First article after a GROUP selection
#82040
Author: Julien ÉLIE
Date: Fri, 23 Oct 2009 21:32
49 lines
3426 bytes
Hi Curt,

>> When we speak about "reported low water mark" and "first article in
>> the group", is it the same notion?
>
> In your above example, did the software report the wrong value, or was 3146
> a valid number at the time of the GROUP command, but had expired, or had
> been canceled, before you issued the STAT command?

3146 was not a valid number at the time of the GROUP command.


> If you issue the group command again after the the
> above sequence, and it is still reporting 3146 as the low water mark, then
> we know that it's not doing as good of a job as it could be.

Consecutive GROUP commands on the same group also led to 3146.


> In today's distributed servers, it's actually quite a lot of work to get
> the low water mark synchronized in near real time to the articles being
> expired on the spool servers.  Some systems just don't attempt to do it in
> real time and instead, update the low water marks as a periodic batch job
> (that might run even less than once a day).  It takes a lot of IO to
> accurately track the low water mark with the expiration of the articles in
> a distributed systems and many have simply stopped trying in order to
> reduce that load.

I believe it is what is happening.
Articles for that newsgroup are stored in CNFS buffers.  These are cyclic
buffers which have self-expiring properties.
As you tell, the low water mark is updated once a day on the overview
by expireover.  It means that 3146 was valid just after that overview
expiration.  But during the day, articles 3146, 3147, etc. were
eventually overwritten.  There is no synchronization between the
back-end cyclic buffer and the front-end overview.


I hope it is OK for GROUP to report an invalid low water mark.
News clients can receive 423 (bad article number) if they send
ARTICLE just after GROUP, though the newsgroup is not empty.

-- 
Julien ÉLIE

« Combien de techniciens de Microsoft sont nécessaires pour
  changer une ampoule électrique brûlée ?
  Aucun, ils vont déclarer l'obscurité comme étant un nouveau standard. »
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads