Thread View: news.software.nntp
55 messages
55 total messages
Page 1 of 2
Started by J. Moreno
Thu, 24 Feb 2000 00:00
Page 1 of 2 • 55 total messages
Re: Batched ARTICLE commands
Author: J. Moreno
Date: Thu, 24 Feb 2000 00:00
Date: Thu, 24 Feb 2000 00:00
36 lines
1840 bytes
1840 bytes
[[ This message was both posted and mailed: see the "To," "Cc," and "Newsgroups" headers for details. ]] In article <220220000104304154%planb@newsreaders.com>, J. Moreno <planb@newsreaders.com> wrote: > Which servers support batched ARTICLE commands? I know INN supports > it, but how about the others? Are there any servers that are know NOT > to support this? INN handles batched commands (article, xhdr) RumorMill handles batched commands Changi handles batched commands Netscape-Collabra/3.52 handles batched commands Microsoft� Internet Services handles batched commands Tortoise 2.1beta handles batched commands DNEWS Version 2.6f handles batched commands The only server that I was able to test and which didn't support batched commands was "WBNews" which is the NNTP server associated with O'Reilly WebBoard 4.10.23. Anybody else? -- J. B. Moreno Pessimist: Half empty Optimist: Half full Engineer: Wrong size glass
Re: Batched ARTICLE commands
Author: Joerg Dietrich
Date: Thu, 24 Feb 2000 00:00
Date: Thu, 24 Feb 2000 00:00
20 lines
1253 bytes
1253 bytes
J. Moreno <planb@newsreaders.com> wrote: >> Which servers support batched ARTICLE commands? I know INN supports >> it, but how about the others? Are there any servers that are know NOT >> to support this? [long list] > Anybody else? leafnode supports limited by the buffer size of stdin. Regards, Jo:rg -- Fortune cookie of the day: Credit ... is the only enduring testimonial to man's confidence in man. -- James Blish
Re: Batched ARTICLE commands
Author: J. Moreno
Date: Thu, 24 Feb 2000 00:00
Date: Thu, 24 Feb 2000 00:00
24 lines
1344 bytes
1344 bytes
In article <ac6498.v0v.ln@RHME112.RES.UTK.EDU>, Joerg Dietrich <joerg@dietrich.net> wrote: > J. Moreno <planb@newsreaders.com> wrote: > >> Which servers support batched ARTICLE commands? I know INN > >> supports it, but how about the others? Are there any servers > >> that are know NOT to support this? > > [long list] Not so long, only 7 servers. > > Anybody else? > > leafnode supports limited by the buffer size of stdin. Thanks, do you know what the standard buffer size is? Anybody know what Diablo or Typhoon does? -- John Moreno
Re: Batched ARTICLE commands
Author: Curt Welch
Date: Fri, 25 Feb 2000 00:00
Date: Fri, 25 Feb 2000 00:00
20 lines
1478 bytes
1478 bytes
"J. Moreno" <planb@newsreaders.com> wrote: > [[ This message was both posted and mailed: see > the "To," "Cc," and "Newsgroups" headers for details. ]] > > In article <220220000104304154%planb@newsreaders.com>, J. Moreno > <planb@newsreaders.com> wrote: > > > Which servers support batched ARTICLE commands? I know INN supports > > it, but how about the others? Are there any servers that are know NOT > > to support this? > > INN handles batched commands (article, xhdr) What are/is batched commands? -- Curt Welch http://CurtWelch.Com/ curt@kcwc.com Webmaster for http://NewsReader.Com/
Re: Batched ARTICLE commands
Author: J. Moreno
Date: Fri, 25 Feb 2000 00:00
Date: Fri, 25 Feb 2000 00:00
31 lines
2475 bytes
2475 bytes
In article <87zosog8kl.fsf@erlenstar.demon.co.uk>, Andrew Gierth <andrew@erlenstar.demon.co.uk> wrote: > Unlike with SMTP, there is a good case for clarifying in a future > NNTP standard that pipelining _is_ OK, with exceptions such as the > POST and MODE commands (and perhaps AUTHINFO). Pipelining article commands results in a significant speed boost over doing things in sequence. This isn't of much concern to an online newsreader, but an offline newsreader will certainly want to take advantage of it, so documenting it explicitly would, IMO, be a good thing. > But to say that the current RFC requires that it work is nonsense - > the RFC is simply silent on the issue. Curt's definitely right that it doesn't mention anything about being able to drop characters or requiring the client to wait for a response before proceeding, so I wouldn't exactly call it nonsense. The only thing that inclines me to think that he's being a little to strict is that I'd jumped to the conclusion that they were being done in sequence and for some reason ignoring it everytime I saw it being treated differently (which says more about me jumping to conclusions than it does about how things should be). -- J. B. Moreno Pessimist: Half empty Optimist: Half full Engineer: Wrong size glass
Re: Batched ARTICLE commands
Author: Richard Michael Todd
Date: Fri, 25 Feb 2000 00:00
Date: Fri, 25 Feb 2000 00:00
23 lines
2196 bytes
2196 bytes
curt@kcwc.com (Curt Welch) writes: > Yes, mine does that as well. > > Any server which doesn't is broken. Though it would probably work with > most newsreaders because it's not very natural for a newsreder to try > and send multiple commands without waiting for the response to the first. > > Streaming newsfeeds (which use CHECK/TAKETHIS) however require that to > work. If you find a server which doesn't queue commands correctly then > it's most likely a server which can't do streaming (incomming) feeds. You're assuming that the same server software that handles incoming streaming newsfeeds is the same one that handles newsreading commands like ARTICLE etc. That's not the case in the INN implementation, and probably several others. It's entirely possible to have a news server that takes streaming CHECK/TAKETHIS but doesn't allow streaming ARTICLES. Now, I think INN's nnrpd probably will allow streaming ARTICLES (a quick test I tried seems to work), but that's more an artifact of the most obvious way to implement a one-process-per-reader nnrpd than because it was designed to.
Re: Batched ARTICLE commands
Author: Curt Welch
Date: Fri, 25 Feb 2000 00:00
Date: Fri, 25 Feb 2000 00:00
39 lines
2337 bytes
2337 bytes
"J. Moreno" <planb@newsreaders.com> wrote: > In article <20000225004139.313$nK@newsreader.com>, Curt Welch > <curt@kcwc.com> wrote: > > > "J. Moreno" <planb@newsreaders.com> wrote: > > > > > > In article <220220000104304154%planb@newsreaders.com>, J. Moreno > > > <planb@newsreaders.com> wrote: > > > > > > > Which servers support batched ARTICLE commands? I know INN > > > > supports it, but how about the others? Are there any servers that > > > > are know NOT to support this? > > > > > > INN handles batched commands (article, xhdr) > > > > What are/is batched commands? > > Giving more than one command at a time and the server queueing them. [examples sniped] > It looks like most (all?) of the major servers support this, at least > for article, head, body and xhdr (which is all I've tested). Yes, mine does that as well. Any server which doesn't is broken. Though it would probably work with most newsreaders because it's not very natural for a newsreder to try and send multiple commands without waiting for the response to the first. Streaming newsfeeds (which use CHECK/TAKETHIS) however require that to work. If you find a server which doesn't queue commands correctly then it's most likely a server which can't do streaming (incomming) feeds. -- Curt Welch http://CurtWelch.Com/ curt@kcwc.com Webmaster for http://NewsReader.Com/
Re: Batched ARTICLE commands
Author: Curt Welch
Date: Fri, 25 Feb 2000 00:00
Date: Fri, 25 Feb 2000 00:00
57 lines
3704 bytes
3704 bytes
Richard Michael Todd <rmtodd@independence.ecn.ou.edu> wrote: > curt@kcwc.com (Curt Welch) writes: > > > Yes, mine does that as well. > > > > Any server which doesn't is broken. Though it would probably work with > > most newsreaders because it's not very natural for a newsreder to try > > and send multiple commands without waiting for the response to the > > first. > > > > Streaming newsfeeds (which use CHECK/TAKETHIS) however require that to > > work. If you find a server which doesn't queue commands correctly then > > it's most likely a server which can't do streaming (incomming) feeds. > > You're assuming that the same server software that handles > incoming streaming newsfeeds is the same one that handles newsreading > commands like ARTICLE etc. True. Or at least the same "style" code. > That's not the case in the INN > implementation, and probably several others. It's entirely possible to > have a news server that takes streaming CHECK/TAKETHIS but doesn't allow > streaming ARTICLES. Not "allowing" batched commands (as are talked about in this thread) means the server is broken. The RFCs are all very clear on the format of incomming commands in the TCP stream. If any NNTP server receives the characters: "ARTICLE 1\r\nARTICLE 2\r\n" from the TCP stream, and decides to toss out the second command, then it is very broken. Nowhere in the spec does it say it's OK to throw away data from the TCP stream. > Now, I think INN's nnrpd probably will allow > streaming ARTICLES (a quick test I tried seems to work), but that's more > an artifact of the most obvious way to implement a one-process-per-reader > nnrpd than because it was designed to. It's very easy to get the code wrong there. Someone that didn't know what they were doing could easily do that and never realize their mistake. There is no reason that I can think of that someone would intentionally flush commands in an NNTP stream. To flush commands correctly would be very hard. I'm sure the servers that don't allow streaming comands are just poorly written pieces of crap that not only dis-allow streaming commands, but are also likely to toss out half of a command and then try to process the remaining half. And that's just broken code. By saying "they allow streaming commands", it makes it sound like the programmer had to add extra code to support the feature (one that perhaps you think isn't even required). But the truth is, if he doesn't add that code, he's written a broken server that doesn't follow the NNTP protocol. -- Curt Welch http://CurtWelch.Com/ curt@kcwc.com Webmaster for http://NewsReader.Com/
Re: Batched ARTICLE commands
Author: Curt Welch
Date: Fri, 25 Feb 2000 00:00
Date: Fri, 25 Feb 2000 00:00
89 lines
5432 bytes
5432 bytes
Andrew Gierth <andrew@erlenstar.demon.co.uk> wrote: > >>>>> "Curt" == Curt Welch <curt@kcwc.com> writes: > > Curt> Not "allowing" batched commands (as are talked about in this > Curt> thread) means the server is broken. The RFCs are all very > Curt> clear on the format of incomming commands in the TCP stream. If > Curt> any NNTP server receives the characters: "ARTICLE 1\r\nARTICLE > Curt> 2\r\n" from the TCP stream, and decides to toss out the second > Curt> command, then it is very broken. Nowhere in the spec does it > Curt> say it's OK to throw away data from the TCP stream. > > You are over-interpreting the RFC. I don't think so. I'd accept the argument that the RFC doesn't match current practice regarding this issue, but I won't accept the argument that I'm reading something into the spec which isn't there. The truth is that the NNTP RFCs (at least all I've read), don't address the issue at all. But it's very clear that if the client sends a valid command, and the server decides to ignore it (or decides to ignore just some of the bytes) -- then the server is not following the RFC. There's just no other way to read the RFC. > A case for comparison: the SMTP RFC documents a protocol with a > somewhat similar form of commands & responses; but it turns out to be > necessary for client implementations _not_ to pipeline commands by > default (with ESMTP, the server can advertise that pipelining is OK). If the NNTP RFC called out cases where it was not OK for clients to pipeline commands (and the only real reason for that I see -- is to allow for servers to drop characters at that point), then a server which dropped charcters at that point would be following the RFC. But none of the RFCs I've seen allow for that. So, I think it's fair to see servers which dropped characters anywhere in the stream are broken as per the current RFCs. > This has been discussed (somewhat briefly) on the NNTP list, and the > conclusion was that pipelining was OK with widely-deployed server > implementations, with the exception of the MODE READER command (which > in the rare cases when it is actually needed and is not a no-op, > cannot be pipelined). I would be inclined to avoid trying it for > AUTHINFO commands too. Yeah, I wasn't even thinking about the cases where the server is going to try and hand-off the connection to another process. In that case, it's hard to "get it right". But in my mind, INN has always been broken in that respect. I think it would be wise to add that to the RFC -- i.e. that pipelining of commands (by _clients_) should not be allowed after the mode reader command. It strikes me as a bit odd to do it for AUTHINFO, but I guess you are thinking that some servers might fork off different processes depending on whether the authenticated user had feed vs read permisssion? > Curt> There is no reason that I can think of that someone would > Curt> intentionally flush commands in an NNTP stream. To flush > Curt> commands correctly would be very hard. I'm sure the servers > Curt> that don't allow streaming comands are just poorly written > Curt> pieces of crap that not only dis-allow streaming commands, > > This is not necessarily the case. > > The usual cause for streaming failing to work (as often found in > mail, and as in the case of MODE READER) is when the connection > is being handed off to a sub-process after commands have been > read. Yeah, I understand that. I just wasn't thinking about it when I wrote my other message. > Curt> By saying "they allow streaming commands", it makes it sound > Curt> like the programmer had to add extra code to support the > Curt> feature (one that perhaps you think isn't even required). But > Curt> the truth is, if he doesn't add that code, he's written a > Curt> broken server that doesn't follow the NNTP protocol. > > The way that sendmail, for example, doesn't follow the SMTP protocol? I don't understand the issue with SMTP so I can't really comment on that. But if sendmail flushes data from the stream at some point, and the RFC doesn't say it's ok, then sure, sendmail doesn't follow the SMTP protocol. -- Curt Welch http://CurtWelch.Com/ curt@kcwc.com Webmaster for http://NewsReader.Com/
Re: Batched ARTICLE commands
Author: J. Moreno
Date: Fri, 25 Feb 2000 00:00
Date: Fri, 25 Feb 2000 00:00
75 lines
2544 bytes
2544 bytes
In article <20000225004139.313$nK@newsreader.com>, Curt Welch <curt@kcwc.com> wrote: > "J. Moreno" <planb@newsreaders.com> wrote: > > > > In article <220220000104304154%planb@newsreaders.com>, J. Moreno > > <planb@newsreaders.com> wrote: > > > > > Which servers support batched ARTICLE commands? I know INN supports > > > it, but how about the others? Are there any servers that are know NOT > > > to support this? > > > > INN handles batched commands (article, xhdr) > > What are/is batched commands? Giving more than one command at a time and the server queueing them. (lines starting with : are from the client) So, instead of a transaction like: :article 1 220 1 <blah@fq.dn> article From: me@aol.com Newsgroups: fe.fi Subject: example Date: 25 Feb 2000 16:25:57 GMT Message-ID: <blah2@fq.dn> hello .. :article 2 220 2 <blah2@fq.dn> article From: me@aol.com Newsgroups: fe.fi Subject: example Date: 25 Feb 2000 16:26:17 GMT Message-ID: <blah2@fq.dn> goodbye .. you have a transaction that looks like :article 1 :article 2 220 1 <blah@fq.dn> article From: me@aol.com Newsgroups: fe.fi Subject: example Date: 25 Feb 2000 16:25:57 GMT Message-ID: <blah2@fq.dn> hello .. 220 2 <blah2@fq.dn> article From: me@aol.com Newsgroups: fe.fi Subject: example Date: 25 Feb 2000 16:26:17 GMT Message-ID: <blah2@fq.dn> goodbye .. It looks like most (all?) of the major servers support this, at least for article, head, body and xhdr (which is all I've tested). -- J. B. Moreno Pessimist: Half empty Optimist: Half full Engineer: Wrong size glass
Re: Batched ARTICLE commands
Author: Andrew Gierth
Date: Fri, 25 Feb 2000 00:00
Date: Fri, 25 Feb 2000 00:00
49 lines
3306 bytes
3306 bytes
>>>>> "Curt" == Curt Welch <curt@kcwc.com> writes: Curt> Not "allowing" batched commands (as are talked about in this Curt> thread) means the server is broken. The RFCs are all very Curt> clear on the format of incomming commands in the TCP stream. If Curt> any NNTP server receives the characters: "ARTICLE 1\r\nARTICLE Curt> 2\r\n" from the TCP stream, and decides to toss out the second Curt> command, then it is very broken. Nowhere in the spec does it Curt> say it's OK to throw away data from the TCP stream. You are over-interpreting the RFC. A case for comparison: the SMTP RFC documents a protocol with a somewhat similar form of commands & responses; but it turns out to be necessary for client implementations _not_ to pipeline commands by default (with ESMTP, the server can advertise that pipelining is OK). This has been discussed (somewhat briefly) on the NNTP list, and the conclusion was that pipelining was OK with widely-deployed server implementations, with the exception of the MODE READER command (which in the rare cases when it is actually needed and is not a no-op, cannot be pipelined). I would be inclined to avoid trying it for AUTHINFO commands too. Curt> There is no reason that I can think of that someone would Curt> intentionally flush commands in an NNTP stream. To flush Curt> commands correctly would be very hard. I'm sure the servers Curt> that don't allow streaming comands are just poorly written Curt> pieces of crap that not only dis-allow streaming commands, This is not necessarily the case. The usual cause for streaming failing to work (as often found in mail, and as in the case of MODE READER) is when the connection is being handed off to a sub-process after commands have been read. Curt> By saying "they allow streaming commands", it makes it sound Curt> like the programmer had to add extra code to support the Curt> feature (one that perhaps you think isn't even required). But Curt> the truth is, if he doesn't add that code, he's written a Curt> broken server that doesn't follow the NNTP protocol. The way that sendmail, for example, doesn't follow the SMTP protocol? -- Andrew.
Re: Batched ARTICLE commands
Author: Andrew Gierth
Date: Fri, 25 Feb 2000 00:00
Date: Fri, 25 Feb 2000 00:00
57 lines
3735 bytes
3735 bytes
>>>>> "Curt" == Curt Welch <curt@kcwc.com> writes: >> A case for comparison: the SMTP RFC documents a protocol with a >> somewhat similar form of commands & responses; but it turns out to >> be necessary for client implementations _not_ to pipeline commands >> by default (with ESMTP, the server can advertise that pipelining >> is OK). Curt> If the NNTP RFC called out cases where it was not OK for Curt> clients to pipeline commands (and the only real reason for that Curt> I see -- is to allow for servers to drop characters at that Curt> point), then a server which dropped charcters at that point Curt> would be following the RFC. But none of the RFCs I've seen Curt> allow for that. So, I think it's fair to see servers which Curt> dropped characters anywhere in the stream are broken as per the Curt> current RFCs. The SMTP RFCs don't allow for it either, it just happens to make sense for some SMTP server implementations to assume that pipelining won't happen (since, after all, the RFC doesn't say it _is_ allowed). Unlike with SMTP, there is a good case for clarifying in a future NNTP standard that pipelining _is_ OK, with exceptions such as the POST and MODE commands (and perhaps AUTHINFO). But to say that the current RFC requires that it work is nonsense - the RFC is simply silent on the issue. Curt> I think it would be wise to add that to the RFC -- i.e. that Curt> pipelining of commands (by _clients_) should not be allowed Curt> after the mode reader command. Curt> It strikes me as a bit odd to do it for AUTHINFO, but I guess Curt> you are thinking that some servers might fork off different Curt> processes depending on whether the authenticated user had feed Curt> vs read permisssion? That, plus the fact that authinfo exchanges can be non-trivial if SASL is involved; the server may respond to AUTHINFO with a challenge. POST is another command that can't be pipelined, of course. >> The way that sendmail, for example, doesn't follow the SMTP protocol? Curt> I don't understand the issue with SMTP so I can't really Curt> comment on that. But if sendmail flushes data from the stream Curt> at some point, and the RFC doesn't say it's ok, then sure, Curt> sendmail doesn't follow the SMTP protocol. Sendmail forks after seeing 'MAIL FROM:'. As it doesn't advertise the PIPELINING extension (at least on any of the versions I have handy), I presume it loses commands pipelined after the end of a message body, even if nowhere else. -- Andrew.
Re: Batched ARTICLE commands
Author: J. Moreno
Date: Fri, 25 Feb 2000 00:00
Date: Fri, 25 Feb 2000 00:00
26 lines
2219 bytes
2219 bytes
In article <20000225162640.211$2M@newsreader.com>, Curt Welch
<curt@kcwc.com> wrote:
> There is no reason that I can think of that someone would intentionally
> flush commands in an NNTP stream. To flush commands correctly would be
> very hard. I'm sure the servers that don't allow streaming comands are
> just poorly written pieces of crap that not only dis-allow streaming
> commands, but are also likely to toss out half of a command and then try
> to process the remaining half. And that's just broken code.
Well, I have to admit -- the only server that I have been able to
personally verify doesn't allow streaming commands ("WBNews" which is
the NNTP server associated with O'Reilly WebBoard 4.10.23), is severely
broken (it doesn't always return the header correctly, except via the
xover command, and it assigns article numbers across newsgroups,
creating gaps).
I know someone who had tested this with an earlier version of INN a
couple of years ago and it didn't work, but he didn't know what version
it was and I've verified that it works with 1.4.
--
J. B. Moreno
Pessimist: Half empty Optimist: Half full Engineer: Wrong size glass
Re: Batched ARTICLE commands
Author: Curt Welch
Date: Sat, 26 Feb 2000 00:00
Date: Sat, 26 Feb 2000 00:00
58 lines
3537 bytes
3537 bytes
Jeremy <bofh@netscum.dk> wrote: > Curt Welch <curt@kcwc.com> wrote: > > > And example of how this might cause probelms... > > > > A client author decides to do a "MODE READER" followed by a "DATE" > > command on start up. He sends both before reading the results. > > I think that's a broken client. MODE READER is a command which can fail, > and therefore, if a client proceeds onward without seeing whether it has > failed, it's broken. You shouldn't assume that a command has succeeded > when it is not guaranteed to do so. MODE READER is a non standard command which can fail simply because the server doesn't implement it. Clients should never assume anything about the return codes from it. The reason clients must wait for the return code is not to see what the server said, but simply because INN has a bug where it might eat any pipelined characters there. > > But POST and IHAVE can't be because of logical protocol reasons --- > > i.e. the client has to wait for the response before it can know what > > will be acceptable next in the data stream. The RFC clearly implies > > that already. Nothing else really needs to be said there. What it > > doesn't imply (or even hint at) is that that pipelining might be a > > problem at the MODE READER command. > > It's the same situation. The client has to wait for the response to the > MODE READER command before it can know what will be acceptable next in > the data stream. No not at all. It must wait at MODE READER if it wants to work correctly with buggy inn servers. It must wait for the return to POST and IHAVE only because it's impractical not to. By my reading of the RFC, it's pefectly valid to send the following byte stream to any NNTP server: IHAVE <crap@my.isp> CR LF . CR LF POST CR LF . CR LF and no matter how the server responds to the IHAVE or POST, it should be in a well defined state after that stream -- i.e. waiting for a new command. So there is no real requirement that the client not pipeline data after any COMMAND. A buggy server however -- one that drops characters in the stream at different points, may not be in the correct state at this point. For example, it may have received the IHAVE, and then tossed all the other other characters. So it, at this point, would be waiting for you to send it an article. But that is clearly a violation of the RFC in my eyes (even if others don't read it that way :)). -- Curt Welch http://CurtWelch.Com/ curt@kcwc.com Webmaster for http://NewsReader.Com/
Re: Batched ARTICLE commands
Author: Andrew Gierth
Date: Sat, 26 Feb 2000 00:00
Date: Sat, 26 Feb 2000 00:00
38 lines
2789 bytes
2789 bytes
>>>>> "Curt" == Curt Welch <curt@kcwc.com> writes: Curt> Return codes are something I find problems with for many Curt> commands. There are various error conditions where it is Curt> unclear what should be returned by reading the RFC. For Curt> example, for ARTICLE/HEAD/BODY what return code do you return Curt> when they ask for an article which has been canceled? The Curt> options are: Curt> 423 no such article number in this group Curt> or 430 no such article found The implication of the examples in the draft is that "ARTICLE <id>" should fail with 430, and "ARTICLE nnn" should fail with 423. Curt> And on your PAT example, I added this return code in my Curt> implementation: Curt> 501 remove : from header argument Curt> which happens if the colon is added to the end of the header Curt> argument. I think this is probably close to the same issue you Curt> are trying to address... Nearly but not quite. The point I was trying to clear up is that many existing implementations of XPAT only support headers that are part of the server's overview db (whether or not they are part of the normal XOVER response). Some while ago (a year or two) in this newsgroup there was some discussion of this, and INN changed from returning an empty successful response to returning "501 header not in index". I believe some servers also return this for XHDR on non-overview headers as well. -- Andrew.
Re: Batched ARTICLE commands
Author: Andrew Gierth
Date: Sat, 26 Feb 2000 00:00
Date: Sat, 26 Feb 2000 00:00
74 lines
4680 bytes
4680 bytes
>>>>> "Curt" == Curt Welch <curt@kcwc.com> writes: Curt> We both have a good understanding of the reality of all this, Curt> but I'd like to go further into my views on this semantic Curt> issue. I think it shbould be important to those people updating Curt> the RFC (which you seem to be a part of). I joind the mailing list to try and get some specific ambiguities resolved, but as Russ said there seems to be little real work done on that list, only at IETF meetings (which I have not yet managed to attend). Worse, the decisions taken at meetings are not being defended on the list. Even worse, issues that have been raised on the list, and have apparently been included on the agenda for meetings, have not been resolved in any sort of meaningful fashion (the question of what error to return for PAT on an unsupported header is as obscure now as when I first raised the issue). I'm tempted to do what Jonathan Grobe did - post a copy of the latest draft here in sections and try and start a serious discussion. >> But to say that the current RFC requires that it work is nonsense >> - the RFC is simply silent on the issue. [of pipelining commands] Curt> I think you are wrong there. You are right that it doesn't Curt> discuss the issue, but I think by not discussing it, it manages Curt> to clearly require that pipeling be supported. One could say the same of SMTP, whose RFC also does not discuss it, but which in practice does not support pipelining. Curt> Nowhere in the RFC does it talk about the timing of this Curt> interaction. Nowhere does it give any hint or implication that Curt> it would be OK for the server to just ignore characters in the Curt> incomming "reliable data stream". And nowhere does it give any hint or implication that the client is permitted to send further commands before receiving the server's response. Even the reference implementation fails to pipeline in all cases - you can't reliably pipeline any command with the trailing '.' line of a posted article, since nntpd spawns inews to accept the post. Curt> So, either we need to change the RFC to document this INN bug Curt> as acceptable behavior (which from what you say seems to be Curt> what they did with SMTP because of a similar bug in sendmail) The SMTP thing is documented in RFC2197. In that case it was simply a question of recognizing the fact that RFC821 did not specify the matter one way or the other, that existing implementations did not handle pipelining adequately, and that if it was to be used it was therefore necessary to define it as a service extension and clarify the required semantics. Curt> But POST and IHAVE can't be because of logical protocol reasons Curt> --- i.e. the client has to wait for the response before it can Curt> know what will be acceptable next in the data stream. The RFC Curt> clearly implies that already. Nothing else really needs to be Curt> said there. What about the question of pipelining a command after the article data for POST? That fails on the reference implementation, despite the fact that there are no logical protocol reasons why it should. Curt> But, the RFC, as written, implies that it is valid for a client Curt> to pipeline commands. And as I've said, this is merely your interpretation, not something which is actually present in the RFC. -- Andrew.
Re: Batched ARTICLE commands
Author: Bill Cole
Date: Sat, 26 Feb 2000 00:00
Date: Sat, 26 Feb 2000 00:00
63 lines
3823 bytes
3823 bytes
In article <20000225234216.661$0Y@newsreader.com>, curt@kcwc.com (Curt Welch) wrote: > Andrew Gierth <andrew@erlenstar.demon.co.uk> wrote: [...] > > POST is another command that can't be pipelined, of course. > > and likewise IHAVE. > > But POST and IHAVE can't be because of logical protocol reasons --- i.e. > the client has to wait for the response before it can know what will > be acceptable next in the data stream. The RFC clearly implies that > already. Nothing else really needs to be said there. What it doesn't > imply (or even hint at) is that that pipelining might be a problem at the > MODE READER command. MODE commands (in addition to POST, IHAVE, and AUTHINFO) cause a state change when successful. It's a poor client that assumes the success of a command which causes a state change and proceed to act as if that state change has succeeded. I know that some servers treat MODE READER as a no-op, but it is not required that all servers do so and it is bad form for a client to assume that if it MUST send the command, that it is a no-op. > Do you see the point I'm making here? Yes, and I agree that a server which chucks data on the stream at such state-change points is acting badly. It's just that any client which might have a problem with that behavior is broken in a worse way. > > The problem is that by the very nature of the protocol, many people think > of it as a command->response->command->response type of a thing. They > assume that clients won't send two commands before waiting for a response. > And in most cases, they are correct, this is how most clients use it. > > But, the RFC, as written, implies that it is valid for a client to pipeline > commands. And this creates the problem that a server author may falsely > assume clients won't pipeline commands (or because of the nature of the > protocol, just never think about the posibility). And a client author, > on the other hand, may decide to take advantage of the pipeline features > of the protocol to improve performance. And, because it really is valid, > this client will work fine with some servers, but break on others that > didn't actually follow the RFC. > > So the RFC has a problem. Granted, it's a small problem, and only one of > many small problems, but it's a problem none the less. Easily solved: define a state diagram and require that clients MUST NOT attempt to pipeline across state changes. Doing so is stupid to begin with, but the existence of a state diagram for SMTP is IMHO what results in only the stupidest of client software attempting to do so. -- Bill Cole, Geek at large I'm casually looking for a new job See: http://sc1.scconsult.com/~bill/resume.html for a resume and more 5094th at Freenix!!!
Re: Batched ARTICLE commands
Author: Andrew Gierth
Date: Sat, 26 Feb 2000 00:00
Date: Sat, 26 Feb 2000 00:00
19 lines
2025 bytes
2025 bytes
>>>>> "Curt" == Curt Welch <curt@kcwc.com> writes: >> What about the question of pipelining a command after the article data >> for POST? That fails on the reference implementation, despite the fact >> that there are no logical protocol reasons why it should. Curt> That's a valid posiblility. But like I just wrote in another Curt> article, I don't think the RFC should address that unless we Curt> know for sure that there is a server which actually has that Curt> problem. Like I said, the reference implementation (at least in 1.5.11t5, haven't looked at anything newer) has that problem. This is still the usual NNTP code used in conjunction with C news. -- Andrew.
Re: Batched ARTICLE commands
Author: Curt Welch
Date: Sat, 26 Feb 2000 00:00
Date: Sat, 26 Feb 2000 00:00
153 lines
9219 bytes
9219 bytes
bill@scconsult.com (Bill Cole) wrote: > In article <20000225234216.661$0Y@newsreader.com>, curt@kcwc.com (Curt > Welch) wrote: > MODE commands (in addition to POST, IHAVE, and AUTHINFO) cause a state > change when successful. It's a poor client that assumes the success of a > command which causes a state change and proceed to act as if that state > change has succeeded. You are confusing the way INN works with the official definition of NNTP in the RFCs. INN is NOT the official definition of the NNTP protocol (though it's a a very practical defacto standard for someone trying to write an NNTP client). INN defines a version of the protocol which has two states (innd vs nnrpd) or feed commands vs reader commmands. And it uses the MODE READER command to switch from feed state, to reader state. And at the same time, it drops characters from the stream in that transistion. None of this behavior has every been documented as far as I know except in the inn source code. All this behavior is _VERY_ implementation dependent and very much in violation of all the NNTP RFCs. And it would be _VERY_ stupid to write the RFC just to fit INNs broken implementation of NNTP. MODE READER is not something any protocol designer would have put into NNTP and it's certainly not something that's required or useful. It's only there to help deal with a problem that INN has. MODE READER does cause a state change in inn. But it DOES NOT cause a protocol state change in the official definition of the protocol. MODE READER has been added to the latest RFC, but it's listed as a command which a client MAY send at any time. There is nothing in the RFC about the server changing states at that time. Older servers don't even implement the command (as I recall, it wasn't even in INN at first -- it was added later). So, all clients that I know about, send it at the start of the session (just in case they are talking to one of those broken INN servers and just in case inn wasn't already in the correct nnrp mode), and then completely ignores the return code. Because no RFC has every been written that correctly defines how MODE READER works, then NO client should ever assume anything about the return codes. An error response (4xx or 5xx) from a MODE READER doesn't tell the client shit about whether reader commands are going to work or not. So any good client will correctly ignore the return code, and proceed to try and read news. If the reader commands don't work, it will then deal with that probelm. So, please, don't accuse a client of being poor because it ignores the return codes a command which you have no way of telling what happens no matter what code it returns. And one which, in all of it's known forms, will never level the stream in a different protocol state like IHAVE or POST or AUTHINFO. It's important for clients to wait for the return call from MODE READER not because it changes state, but because inn has a known bug where it may end up droping characters sent after the MODE command but before the response. This is very different from the optional protocol state changes (from command mode to data input mode) that occure with IHAVE and POST. The first is a real-world inn bug issue, the second are valid official NNTP protocol issues. Please don't put these together as if they were the same type of issue. > I know that some servers treat MODE READER as a no-op, but it is not > required that all servers do so and it is bad form for a client to assume > that if it MUST send the command, that it is a no-op. And it's much worse for the client to assume anthing about the return codes it receives from a MODE READER command. > > Do you see the point I'm making here? > > Yes, and I agree that a server which chucks data on the stream at such > state-change points is acting badly. It's just that any client which > might have a problem with that behavior is broken in a worse way. Well, no. The first is a clear violation of the RFC. The second isn't. So you are saying a client which follows the RFC is broken in a worse way than a server which does't follow the RFC? I'm sorry, you may think that since INN came first, that clients should use it as the "definition" of what a client "should" do, but I just don't see it that way. From a very real and practical sense, any one writting a NNTP client that might need to talk to an INN server some day, should deal with this issue correctly. That's why I think the RFC needs to say something about this. But this dropping character issue is simply in INN bug. And it is a simple thing to fix. There's no technical reason servers need to behave that way. And like I said, as far as I know, INN is the only server with the bug. So talking about it as if it was a valid NNTP conecpt -- like IHAVE and POST -- is just bogus. > > The problem is that by the very nature of the protocol, many people > > think of it as a command->response->command->response type of a thing. > > They assume that clients won't send two commands before waiting for a > > response. And in most cases, they are correct, this is how most clients > > use it. > > > > But, the RFC, as written, implies that it is valid for a client to > > pipeline commands. And this creates the problem that a server author > > may falsely assume clients won't pipeline commands (or because of the > > nature of the protocol, just never think about the posibility). And a > > client author, on the other hand, may decide to take advantage of the > > pipeline features of the protocol to improve performance. And, because > > it really is valid, this client will work fine with some servers, but > > break on others that didn't actually follow the RFC. > > > > So the RFC has a problem. Granted, it's a small problem, and only one > > of many small problems, but it's a problem none the less. > > Easily solved: define a state diagram and require that clients MUST NOT > attempt to pipeline across state changes. Doing so is stupid to begin > with, but the existence of a state diagram for SMTP is IMHO what results > in only the stupidest of client software attempting to do so. I think it would be very wrong to officially include INNs idea of "states" into the RFC. No one I know of besides INN does it that way. There are lots of servers which only implement subsets of the full NNTP command set, but most don't change states, and when they do, it's more likely to happen at AUTHINFO time than as the result of a MODE command. I think it would be incredibly stupid to put inns broken behaior into the RFC and then force all the other server authors to waste their time duplicating that behavor in their previously non-broken servers. The solution is simple however. Include MODE READER like they have already done, but explain that some servers require this command to be sent before reader commands will work -- so every client SHOULD send this before trying to use any of the reader commands. And, warn that some clients have been known to loose characters when switching modes, so pipelining SHOULD NOT be done when this command is used. Note I say SHOULD NOT, because servers MUST accept pipelining everywhere in my opinion - servers that can't, like inn, are broken, and should be fixed (or shout just remain broken and not care about it). And warn clients about the dangers of pipelining on other potentially dangerous places like AUTHINFO, or maybe even durring a POST (if like sendmail seems to do - it may fork or a separate process to read the data and loose characters before and after the data.) But, I'd suggest this warning only be added to the RFC if we can actually find a real-world server that has this problem. -- Curt Welch http://CurtWelch.Com/ curt@kcwc.com Webmaster for http://NewsReader.Com/
Re: Batched ARTICLE commands
Author: Curt Welch
Date: Sat, 26 Feb 2000 00:00
Date: Sat, 26 Feb 2000 00:00
172 lines
9337 bytes
9337 bytes
Andrew Gierth <andrew@erlenstar.demon.co.uk> wrote:
We both have a good understanding of the reality of all this, but I'd
like to go further into my views on this semantic issue. I think it shbould
be important to those people updating the RFC (which you seem to be a part
of).
> But to say that the current RFC
> requires that it work is nonsense - the RFC is simply silent on the
> issue. [of pipelining commands]
I think you are wrong there. You are right that it doesn't discuss
the issue, but I think by not discussing it, it manages to clearly
require that pipeling be supported. I'll demonstrate.
To start with, the RFC defines the protocol to work on top of a reliable
data stream protocol and gives TCP/IP as the example. This clearly defines
the protocol to be working with a stream of characters that have NO
boundries between commands, and no guarantee that groups of characters sent
by the client (i.e. a command) will arrive in those same groups(packets) at
the server.
It goes on to define a COMMAND (in so many words) as a byte stream ending
in CR LF. So the server must parse this incomming byte stream and convert
the stream into a stream of COMMANDS, but looking for the CR LF terminator
characters.
The rest of the RFC defines the responses that the server MUST give
for all COMMANDS -- including how to respond to invalid commands.
So, by all this, if the client sends the byte stream:
M O D E <SP> R E A D E R <CR> <LF> C R A P <CR> <LF>
then the server is REQUIRIED by the RFC to parse that as two commands, and
resond in the correct fashion to _both_ of them.
If the server decides to ignore the "CRAP" -- i.e. drop it on the
floor and pretend it did not receive it, then it has clearly in my mind
has violated the RFC.
Nowhere in the RFC does it talk about the timing of this interaction.
Nowhere does it give any hint or implication that it would be OK for
the server to just ignore characters in the incomming "reliable data
stream".
So, the RFC defines the protocol on top of a data stream which has NO
association between what the client and server are sending to each other,
it says nothing about the timing, and it defines a language with symantics
which have no requirements for the client and server to stay in-sync (with
the exception of the IHAVE and POST commands).
So, I claim that the server is required by the current RFC to reconginze
this:
M O D E <SP> R E A D E R <CR> <LF> C R A P <CR> <LF>
as two commands. Please show me where it says it's ok for the server
to drop the CRAP? If you can't, then I claim that this is straight
forward proof that the RFC requires the server to support pipelining
of commands by the client. This follows because there's no way that
a server can follow the RFC (as written), and not support pipelining.
The only thing that even hints at a requirement for the client to wait
for a response before sending the next command is the vague discription
of NEWS EXCHANGE state:
"The client host and server host SHOULD then exchange commands
and responses (respectively) until the connection is closed or
aborted."
Some people I suspect might argue that an "exchange" here is defined
as the client sending a command, and then _waiting_ for a response, before
starting the next exchange. But I think it's just as fair to read
that as the client sends command(s), and the server responds to them.
So, in my mind, we have an RFC that defines (though a bit indirectly)
that pipelining must be supported by the server. But yet, we have
servers which are clearly broken (inn for example) which will read-ahead
data from the stream, and then toss it out when it starts a new
process (nnrpd) to continue the parsing of the data.
There is NOTHING in the RFC to imply this might happen. And there is
plenty in the RFC that implies this WON'T happen. So I see this is
a weakness in the RFC that should be addressed.
And example of how this might cause probelms...
A client author decides to do a "MODE READER" followed by a "DATE" command
on start up. He sends both before reading the results.
On many servers (like mine, and Typhoon) which don't have the inn broken
behavior, this will work fine. The client in my mind has clearly followed
the RFC. He sent a perfictly formated data stream to the client as
specified and the server responds as required.
But then, when someone tries to use this client on a broken server (inn),
it hangs on starup waiting for the response to the second command which
never comes.
This is very clearly a inn application bug. The TCP stack didn't drop the
characters, it gave them to innd as requested. Innd just failed to pass
those characters on to nnrpd as required by the RFC.
You do understand that the characters aren't just "lost" on the handoff
don't you? i.e., it's not OK to expect a Unix application to loose
characters from a TCP stream just becaue it forks a new process to read the
stream? This is simply an implementation bug where INND reads the stream,
and then, in complete violation of the RFC, throws the characters away.
So, I argue that the RFC, by saying nothing, supports the concept of
pipelined commands. And because at least one very popular implementation
of the protocol (inn) fails to follow the RFC, we have a breakdown in
the intended function of the RFC -- i.e. to create a standard which people
can follow when developing applications which will allow them to
interoperate without trouble.
So, either we need to change the RFC to document this INN bug as acceptable
behavior (which from what you say seems to be what they did with SMTP
because of a similar bug in sendmail), or consider it incorrect, and just
understand that this is just one of the many "bugs" NNTP authors have to
deal with when writing real-world applications.
> Curt> I think it would be wise to add that to the RFC -- i.e. that
> Curt> pipelining of commands (by _clients_) should not be allowed
> Curt> after the mode reader command.
>
> Curt> It strikes me as a bit odd to do it for AUTHINFO, but I guess
> Curt> you are thinking that some servers might fork off different
> Curt> processes depending on whether the authenticated user had feed
> Curt> vs read permisssion?
>
> That, plus the fact that authinfo exchanges can be non-trivial if
> SASL is involved; the server may respond to AUTHINFO with a challenge.
Ah, ok. Didn't know about that SASL stuff...
> POST is another command that can't be pipelined, of course.
and likewise IHAVE.
But POST and IHAVE can't be because of logical protocol reasons --- i.e.
the client has to wait for the response before it can know what will
be acceptable next in the data stream. The RFC clearly implies that
already. Nothing else really needs to be said there. What it doesn't
imply (or even hint at) is that that pipelining might be a problem at the
MODE READER command.
Do you see the point I'm making here?
The problem is that by the very nature of the protocol, many people think
of it as a command->response->command->response type of a thing. They
assume that clients won't send two commands before waiting for a response.
And in most cases, they are correct, this is how most clients use it.
But, the RFC, as written, implies that it is valid for a client to pipeline
commands. And this creates the problem that a server author may falsely
assume clients won't pipeline commands (or because of the nature of the
protocol, just never think about the posibility). And a client author,
on the other hand, may decide to take advantage of the pipeline features
of the protocol to improve performance. And, because it really is valid,
this client will work fine with some servers, but break on others that
didn't actually follow the RFC.
So the RFC has a problem. Granted, it's a small problem, and only one of
many small problems, but it's a problem none the less.
--
Curt Welch http://CurtWelch.Com/
curt@kcwc.com Webmaster for http://NewsReader.Com/
Re: Batched ARTICLE commands
Author: Russ Allbery
Date: Sat, 26 Feb 2000 00:00
Date: Sat, 26 Feb 2000 00:00
40 lines
3000 bytes
3000 bytes
Curt Welch <curt@kcwc.com> writes: > INN defines a version of the protocol which has two states (innd vs > nnrpd) or feed commands vs reader commmands. INN defines a version of the protocol which has three states. Any implementation of the NNTP protocol is going to have at least two states. Don't forget about IHAVE and POST, which depending on the reply from the server either leave the server in "command" state or put the server in "expecting a post" state. You can't pipeline them either. > And it uses the MODE READER command to switch from feed state, to reader > state. And at the same time, it drops characters from the stream in > that transistion. None of this behavior has every been documented as > far as I know except in the inn source code. This is a problem with quite a bit of INN. I agree with you. I also agree with you that were I designing a news system from scratch, the obvious and best way of implementing it would be to put transit on a different port than readers, fully separate the transit protocol from the reader protocol (they're really two different protocols that currently happen to share a very small number of commands due to implementation accident but really don't need to even do that), and do away with the entire MODE READER thing. For that matter, MODE STREAM should be negotiated using some kind of capabilities system rather than as a mode change. INN does what it does due to historical evolution of the news protocol; there was only one port, the transit protocol was sort of an odd extension of the reader protocol, and different servers did odd bits of munging them together. Like most things that evolved rather than were designed, it's not nearly as clean as it should be. -- Russ Allbery (rra@stanford.edu) <URL:http://www.eyrie.org/~eagle/>
Re: Batched ARTICLE commands
Author: Bill Cole
Date: Sat, 26 Feb 2000 00:00
Date: Sat, 26 Feb 2000 00:00
58 lines
3728 bytes
3728 bytes
In article <250220002137494912%planb@newsreaders.com>, "J. Moreno" <planb@newsreaders.com> wrote: > In article <87zosog8kl.fsf@erlenstar.demon.co.uk>, Andrew Gierth > <andrew@erlenstar.demon.co.uk> wrote: > > > Unlike with SMTP, there is a good case for clarifying in a future > > NNTP standard that pipelining _is_ OK, with exceptions such as the > > POST and MODE commands (and perhaps AUTHINFO). > > Pipelining article commands results in a significant speed boost over > doing things in sequence. This isn't of much concern to an online > newsreader, but an offline newsreader will certainly want to take > advantage of it, so documenting it explicitly would, IMO, be a good > thing. Yes, and the selection of which commands should be pipelinable is simple: if the command has a potential for leaving the session in a new state, it cannot be pipelined. NNTP has fewer discrete states (for readers) than SMTP, so fewer commands are likely to be dangerous. On the other hand, commands which are intended to result in a state change but which may fail (MODE, AUTHINFO, POST) are also pretty much useless to pipeline because it is not safe for a client to assume that the next command is going to be legal until there is a response. > > But to say that the current RFC requires that it work is nonsense - > > the RFC is simply silent on the issue. > > Curt's definitely right that it doesn't mention anything about being > able to drop characters or requiring the client to wait for a response > before proceeding, so I wouldn't exactly call it nonsense. > > The only thing that inclines me to think that he's being a little to > strict is that I'd jumped to the conclusion that they were being done > in sequence and for some reason ignoring it everytime I saw it being > treated differently (which says more about me jumping to conclusions > than it does about how things should be). Curt is also right about the coding side: making a server that doesn't pipeline means making a server that is more complex than it needs to be from a coding perspective. The natural way to handle a protocol like NNTP is to read every byte coming in and parse out commands, NOT to rely on specific timing which is difficult (impossible on some OS's) to get exactly right. I would be very surprised to find any server failing to handle appropriately batched commands which is not otherwise broken in some way. FWIW, I have verified another server that happily handles batched/pipelined commands: RumorMill. -- Bill Cole, Geek at large I'm casually looking for a new job See: http://sc1.scconsult.com/~bill/resume.html for a resume and more 5094th at Freenix!!!
Re: Batched ARTICLE commands
Author: J. Moreno
Date: Sat, 26 Feb 2000 00:00
Date: Sat, 26 Feb 2000 00:00
37 lines
2402 bytes
2402 bytes
In article <20000226162848.241$4u@newsreader.com>, Curt Welch <curt@kcwc.com> wrote: > Jeremy <bofh@netscum.dk> wrote: > > Curt Welch <curt@kcwc.com> wrote: > > > > > And example of how this might cause probelms... > > > > > > A client author decides to do a "MODE READER" followed by a > > > "DATE" command on start up. He sends both before reading the > > > results. > > > > I think that's a broken client. MODE READER is a command which can > > fail, and therefore, if a client proceeds onward without seeing > > whether it has failed, it's broken. You shouldn't assume that a > > command has succeeded when it is not guaranteed to do so. > > MODE READER is a non standard command which can fail simply because > the server doesn't implement it. Clients should never assume > anything about the return codes from it. > > The reason clients must wait for the return code is not to see what > the server said, but simply because INN has a bug where it might eat > any pipelined characters there. Reading what Andrew posted about MODE READER, I notice that it doesn't say anything about what NNTP commands may or may not be accepted after issuing the MODE READER command, except for saying that it may refuse to accept POST commands. So, as it is, I think I have to agree with you... -- J. B. Moreno Pessimist: Half empty Optimist: Half full Engineer: Wrong size glass
Re: Batched ARTICLE commands
Author: Jeremy
Date: Sat, 26 Feb 2000 00:00
Date: Sat, 26 Feb 2000 00:00
27 lines
1790 bytes
1790 bytes
Curt Welch <curt@kcwc.com> wrote: > And example of how this might cause probelms... > > A client author decides to do a "MODE READER" followed by a "DATE" command > on start up. He sends both before reading the results. I think that's a broken client. MODE READER is a command which can fail, and therefore, if a client proceeds onward without seeing whether it has failed, it's broken. You shouldn't assume that a command has succeeded when it is not guaranteed to do so. > But POST and IHAVE can't be because of logical protocol reasons --- i.e. > the client has to wait for the response before it can know what will > be acceptable next in the data stream. The RFC clearly implies that > already. Nothing else really needs to be said there. What it doesn't > imply (or even hint at) is that that pipelining might be a problem at the > MODE READER command. It's the same situation. The client has to wait for the response to the MODE READER command before it can know what will be acceptable next in the data stream. -- Jeremy ( jeremy@exit109.com | bofh@netscum.dk )
Re: Batched ARTICLE commands
Author: Shalmaneser
Date: Sat, 26 Feb 2000 00:00
Date: Sat, 26 Feb 2000 00:00
15 lines
1672 bytes
1672 bytes
J. Moreno wrote: > I know someone who had tested this with an earlier version of INN a > couple of years ago and it didn't work, but he didn't know what version > it was and I've verified that it works with 1.4. Hmm. Is it possible that swerver was using a *really* old INN with nntp 1.5.1x instead of nnrpd? I've seen odd blocking problems with that daemon and late model Gnus, and haven't been able to duplicate it with other reader/swerver combinations. (I haven't looked into this batching stuff there yet, having figured a stdio-based swerver shouldn't have had such problems, but now I'll have to do some playing.)
Re: Batched ARTICLE commands
Author: J. Moreno
Date: Sat, 26 Feb 2000 00:00
Date: Sat, 26 Feb 2000 00:00
56 lines
3605 bytes
3605 bytes
In article <20000226203444.497$we@newsreader.com>, Curt Welch <curt@kcwc.com> wrote: > Brad Knowles <brad@shub-internet.org> wrote: > > The standard as written is actually completely silent on this > > issue, you are adding your own interpretation to create this > > otherwise non-existant issue. > > Well, I think it's not silent at all about the issue becuse of the > fact it brings in TCP/IP, but no one else seems to thing that's > important. I've not completely made up my mind, but I think you have a good point about it being important. I bet the only reason I'm still having problem with it is because of the residual "command->response-comand->response" mode in my brain. I can't think of a single legitimate argument for your being wrong. -snip- > > I happen to agree with you that clients and servers both should > > support pipelining everywhere that it is possible, but there are > > some places where making this simplistic assumption simply won't > > work (for practical reasons), > > The _ONLY_ (strong words eh?) practical reason is the fact that inn > is so wide spread. It's not a practical issue in the techincal sense > at all. INNs split process model is just the wrong way to build an > NNTP server on a Unix box. No one else that I know of has made that > mistake since. I think it's important to document that both client and servers are actually pipelining commands /at the moment/ (even if you are right about the tcp/ip protocol saying that should be acceptable, the nature of the commands make the c->r->c->r sequence seem "natural" and servers should be aware that this will be demanded of them while clients should be made aware it is possible [as I said it is significantly faster]). > > and so long as the RFC is pointedly silent on this > > issue, it doesn't make any sense railing against the wind. > > Or as I see it: > > Since everyone else is to blind to see that the RFC isn't silent on > this issue, I might as well not waste my breath :).... At the very least it's a point that needs to be raised, so I don't think you've been wasting your breath. -- J. B. Moreno Pessimist: Half empty Optimist: Half full Engineer: Wrong size glass
Re: Batched ARTICLE commands
Author: Curt Welch
Date: Sat, 26 Feb 2000 00:00
Date: Sat, 26 Feb 2000 00:00
93 lines
5596 bytes
5596 bytes
Andrew Gierth <andrew@erlenstar.demon.co.uk> wrote: > >>>>> "Curt" == Curt Welch <curt@kcwc.com> writes: > > Curt> We both have a good understanding of the reality of all this, > Curt> but I'd like to go further into my views on this semantic > Curt> issue. I think it shbould be important to those people updating > Curt> the RFC (which you seem to be a part of). > > I joind the mailing list to try and get some specific ambiguities > resolved, but as Russ said there seems to be little real work done on > that list, only at IETF meetings (which I have not yet managed to > attend). Worse, the decisions taken at meetings are not being defended > on the list. Even worse, issues that have been raised on the list, and > have apparently been included on the agenda for meetings, have not been > resolved in any sort of meaningful fashion (the question of what error > to return for PAT on an unsupported header is as obscure now as when I > first raised the issue). Return codes are something I find problems with for many commands. There are various error conditions where it is unclear what should be returned by reading the RFC. For example, for ARTICLE/HEAD/BODY what return code do you return when they ask for an article which has been canceled? The options are: 423 no such article number in this group or 430 no such article found It looked to me from the RFC like 430 would be the better choice. And that 423 would be used if the article number specified was out of range. But INN returns 423 for canceled articles and I found at least one newsreader which couldn't deal with the 430 return (the newsreader was broken here -- but this demonstrates the problems that arrise by not being more specific about return codes). And on your PAT example, I added this return code in my implementation: 501 remove : from header argument which happens if the colon is added to the end of the header argument. I think this is probably close to the same issue you are trying to address... Almost all the commands my have error returns that aren't currently documented in the RFC -- stuff which cuases the command to fail some type of semantic test like an invalid group name or message-id, or number. The RFC doesn't address how the server and/or client should deal with that. Clients would have a hard time telling the difference between a semantic problem (such as an invalid header argument) and a command not implemented - both which tend to return codes in the 5xx range. > I'm tempted to do what Jonathan Grobe did - post a copy of the latest > draft here in sections and try and start a serious discussion. I'd be all for that if someone (you?) were willing to take the lead in getting all that serious discussion into a draft. If no one was doing that, then we would just be wasting our time with the discussion. I'd be happy to help out with the creation of an "unoffical" draft NNTP. If the offical channels aren't getting the job done and someone is willing to make an unoffical approach work, I'd be happy with that. I also think the NNTP issues are much easier to resolve than say the USEFOR issues. So I don't think we are talking about all that much work. It looks like most of them have been correctly addressed in the current draft. > What about the question of pipelining a command after the article data > for POST? That fails on the reference implementation, despite the fact > that there are no logical protocol reasons why it should. That's a valid posiblility. But like I just wrote in another article, I don't think the RFC should address that unless we know for sure that there is a server which actually has that problem. I don't think it should be added to the RFC just because it could be a problem. That just oppens the door to allow people to write what I think of as a buggy server. > Curt> But, the RFC, as written, implies that it is valid for a client > Curt> to pipeline commands. > > And as I've said, this is merely your interpretation, not something > which is actually present in the RFC. Ok, so we don't read it the same way. That just demonstrates the need to improve the RFC. -- Curt Welch http://CurtWelch.Com/ curt@kcwc.com Webmaster for http://NewsReader.Com/
Re: Batched ARTICLE commands
Author: Sven Paulus
Date: Sun, 27 Feb 2000 00:00
Date: Sun, 27 Feb 2000 00:00
10 lines
1410 bytes
1410 bytes
Bill Cole <bill@scconsult.com> wrote: |> MODE commands (in addition to POST, IHAVE, and AUTHINFO) cause a state |> change when successful. It's a poor client that assumes the success of a |> command which causes a state change and proceed to act as if that state |> change has succeeded. Don't forget GROUP. No client should expect a GROUP command to succeed, a group could be rmgrouped.
Re: Batched ARTICLE commands
Author: Brad Knowles
Date: Sun, 27 Feb 2000 00:00
Date: Sun, 27 Feb 2000 00:00
36 lines
2761 bytes
2761 bytes
In article <87zosog8kl.fsf@erlenstar.demon.co.uk>, Andrew Gierth
<andrew@erlenstar.demon.co.uk> wrote:
> Sendmail forks after seeing 'MAIL FROM:'.
Correction. Sendmail forks after receiving the connection, then
forks a grand-child process after receiving "MAIL From:".
> As it doesn't advertise the
> PIPELINING extension (at least on any of the versions I have handy), I
> presume it loses commands pipelined after the end of a message body,
> even if nowhere else.
It doesn't advertise PIPELINING, therefore anyone that attempts to
implement PIPELINING with it will lose. Doing PIPELINING by default is
certainly not part of the standard. You don't do it unless the server
advertises that it is capable of handling it.
Each grand-child process handles one message and one message only,
after writing it to queue, it then typically disconnects from the
foreground (passing the connection off to its parent) and goes to
deliver message in the background, and the parent then handles
connection caching and can fork off another grand-child process, etc....
I don't see anything wrong with this process, and I also don't see
how this has any relevance whatsoever to this newsgroup.
--
Brad Knowles <brad@shub-internet.org> <http://www.shub-internet.org/brad/>
Are you a USENET news server administrator outside of North America or
Western Europe? Would you like a newsfeed from a site in the Freenix
Top 65? If so, please contact me via private e-mail for details.
Re: Batched ARTICLE commands
Author: Andrew Gierth
Date: Sun, 27 Feb 2000 00:00
Date: Sun, 27 Feb 2000 00:00
88 lines
5558 bytes
5558 bytes
>>>>> "Curt" == Curt Welch <curt@kcwc.com> writes: Curt> Why would I want to criple my server like this just so it could Curt> be compatible with inn? Why would the writers of the RFC want Curt> to force all the other servers to be broken just like inn is? No one is suggesting that. No one is suggesting that MODE READER actually needs to be anything more than a no-op if the server doesn't require it. (But there are clients that fail if the server treats it as an unrecognised command, so it does need to be recognised by the server.) >> The standard as written is actually completely silent on this >> issue, you are adding your own interpretation to create this >> otherwise non-existant issue. Curt> Well, I think it's not silent at all about the issue becuse of Curt> the fact it brings in TCP/IP, but no one else seems to thing Curt> that's important. Because it's not important. I've already pointed out that in another similar field (SMTP) this problem has already been identified and been resolved differently. (In their case, there was presumably no point in arguing it because implementations were widely deployed that did not support pipelining; making it an extension was the only practical option.) The fact is, that you can go around calling things "broken" as much as you like, but it changes nothing. The _fact_ is that the currently deployed servers do, as far as I know, all support pipelining with the exception of the MODE READER, POST and IHAVE commands. Any new server author needs to know that clients expect it to work, so it should be documented in the RFC; but nothing will be gained by trying to pretend that the known interoperability problems don't exist; client authors need to know that some servers will not allow commands to be pipelined across those commands. >> I happen to agree with you that clients and servers both should >> support pipelining everywhere that it is possible, but there are >> some places where making this simplistic assumption simply won't >> work (for practical reasons), Curt> The _ONLY_ (strong words eh?) practical reason is the fact that Curt> inn is so wide spread. It's not a practical issue in the Curt> techincal sense at all. This is nonsense. Firstly, it's not just INN, it's also the reference implementation (which spawns subprocesses for POST and IHAVE). Secondly, it's a perfectly reasonable part of server design to hand off to other processes under appropriate conditions. Whether this is done in a way that breaks pipelining or not is an implementation issue; this makes it worth specifying for those cases where it is really needed, but without unnecessarily tying the implementor's hands. Curt> INNs split process model is just the wrong way to build an NNTP Curt> server on a Unix box. INN's approach is exactly the right one given its design constraints. The only improvement would have been for innd to get incoming connections passed to it from another process (avoiding the need to fork the large innd process); but I doubt that requiring file-descriptor-passing would have helped its portability anything at the time. Curt> No one else that I know of has made that mistake since. How many people do you know who have written widely-deployed Unix news servers? Apart from INN and the reference nntpd, there is DNews (which did not originate on Unix), Cyclone (which requires threads, does everything in a single multi-threaded process and doesn't support readers at all), Typhoon/Breeze (which does support readers but is still constrained by the one-big-multithreaded-process model). What else is there? Some proprietary servers written by specific sites? Curt> USEFOR burned me out real fast. This is the NNTP RFC, not Curt> USEFOR thank god. Yeah; USEFOR is so slow because things get discussed to death on the list, the NNTP group is just as slow because things never get discussed on the list at all. USEFOR has had more traffic in one month (July 98, for example) than is in the entire archive of ietf-nntp since mid-96. -- Andrew.
Re: Batched ARTICLE commands
Author: Russ Allbery
Date: Sun, 27 Feb 2000 00:00
Date: Sun, 27 Feb 2000 00:00
23 lines
2372 bytes
2372 bytes
Curt Welch <curt@kcwc.com> writes: > Well, I think that's my point. There are a lot of different news server > archetecture options to pick from that will solve the inn problem and no > one I know of has made the mistake again. Even some people, such as > yourself, have decided to fix the probelm with inn by running innd on a > separate port. This is, incidentally, a fully supported INN configuration, just not the default, and therefore the characterization of this as a problem with INN isn't *entirely* accurate. :) So far as I know, INN has supported running innd and nnrpd on separate ports way back to the 1.4 days and earlier by running nnrpd out of inetd, and more recently by running it in daemon mode. I'm sure that if the NNTP standard had standardized two separate ports for readers and server connections, INN would have changed its default configuration some time back. -- Russ Allbery (rra@stanford.edu) <http://www.eyrie.org/~eagle/>
Re: Batched ARTICLE commands
Author: Curt Welch
Date: Sun, 27 Feb 2000 00:00
Date: Sun, 27 Feb 2000 00:00
51 lines
3222 bytes
3222 bytes
Brad Knowles <brad@shub-internet.org> wrote: > In article <20000226162848.241$4u@newsreader.com>, curt@kcwc.com (Curt > Welch) wrote: > > > MODE READER is a non standard command which can fail simply because the > > server doesn't implement it. Clients should never assume anything > > about the return codes from it. > You're talking about pipelining, right? Okay, let's think about the > model of pipelining that is used in CPUs. I'm lost. In what you quoted, I was not talking about pipelining. I was talking about the return codes from a MODE READER command and what the mean or don't mean. But I have been talking about pipelining a lot, so lets ignore what you quoted... > Now, given this, why should you (or anyone else) expect that the > situation should be any different for pipelining when implemented in > other contexts, especially those contexts where the official standard is > pointedly silent on the issue of pipelining? My argument (though others don't see it that way), is the the standard isn't silent about the issue. It calls into play the entire TCP/IP standard which very clearly defines (in a few hundred pages of text :)) that pipelining MUST be supported. There is no way to correctly implement a TCP/IP stack and not support pipelining. There are no "stalled stack" condiditons. Since "the context" isn't just some random "other context", but a very clearly defined context, one which clearly supports pipelining, I fail to see how others don't see it. > If you think the standard is broken because it doesn't explicitly > allow (or require) pipelining from clients, then I suggest you get > involved in the process to help write the upcoming version of the new > standard. By writting this message I am involved (even if indirectly) in the processes. > Myself, I got involved in that process at one time, and have since > disentangled myself from it. I just don't need that kind of crap in my > life. Yeah, been there, done that too. It can burn you out real quick. -- Curt Welch http://CurtWelch.Com/ curt@kcwc.com Webmaster for http://NewsReader.Com/
Re: Batched ARTICLE commands
Author: Andrew Gierth
Date: Sun, 27 Feb 2000 00:00
Date: Sun, 27 Feb 2000 00:00
24 lines
1931 bytes
1931 bytes
>>>>> "Brad" == Brad Knowles <brad@shub-internet.org> writes: >> Sendmail forks after seeing 'MAIL FROM:'. Brad> Correction. Sendmail forks after receiving the connection, Brad> then forks a grand-child process after receiving "MAIL From:". the first fork was not relevent to the point I was making, so I didn't mention it. [...] Brad> I don't see anything wrong with this process, and I also Brad> don't see how this has any relevance whatsoever to this Brad> newsgroup. It is a good example of how failure of a standard to specify the handling of pipelined commands can lead to implementations that fail to handle them. -- Andrew.
Re: Batched ARTICLE commands
Author: Brad Knowles
Date: Sun, 27 Feb 2000 00:00
Date: Sun, 27 Feb 2000 00:00
71 lines
4760 bytes
4760 bytes
In article <20000226153651.615$gx@newsreader.com>, curt@kcwc.com (Curt
Welch) wrote:
> MODE READER does cause a state change in inn. But it DOES NOT cause a
> protocol state change in the official definition of the protocol.
>
> MODE READER has been added to the latest RFC, but it's listed
> as a command which a client MAY send at any time. There is nothing in
> the RFC about the server changing states at that time.
If it's specific to INN (where it causes a state change), and is
entirely optional on the part of the client, then since INN is the
reason that it exists at all (since it needs that state change), then
the definition automatically follows -- MODE READER causes a state
change when issued, because this is how the command operates in the
program for which this was added to the protocol.
Otherwise MODE READER has no reason to exist.
> It's important for clients to wait for the return call from MODE READER
> not because it changes state, but because inn has a known bug where
> it may end up droping characters sent after the MODE command but before
> the response. This is very different from the optional protocol state
> changes (from command mode to data input mode) that occure with IHAVE
> and POST. The first is a real-world inn bug issue, the second are valid
> official NNTP protocol issues.
It wouldn't be in the standard at all if INN didn't need it, and
since INN functions this way, the standard needs to reflect this fact.
In this case, INN defines the "standard" from which this is taken.
There's no sense adding support for M-16 assault weapons if you're
going to turn around and disallow people from using 5.56Nato ammunition.
> Well, no. The first is a clear violation of the RFC. The second isn't.
> So you are saying a client which follows the RFC is broken in a worse
> way than a server which does't follow the RFC?
Either you write the RFC to describe how the ideal world works and
you expect everyone to live up to it, or you write the RFC to describe
how the real world works and what people need to do in order to cope
with it
> Note I say SHOULD NOT, because servers MUST accept pipelining everywhere
> in my opinion - servers that can't, like inn, are broken, and should be
> fixed (or shout just remain broken and not care about it).
In your opinion. Very key words. The standard as written is
actually completely silent on this issue, you are adding your own
interpretation to create this otherwise non-existant issue.
I happen to agree with you that clients and servers both should
support pipelining everywhere that it is possible, but there are some
places where making this simplistic assumption simply won't work (for
practical reasons), and so long as the RFC is pointedly silent on this
issue, it doesn't make any sense railing against the wind.
If you really feel this strongly about it, I suggest you get to work
on starting to define how a proper wall is built and then to actually
start building it -- get involved in USEFOR and the drafting of the
upcoming standard.
--
Brad Knowles <brad@shub-internet.org> <http://www.shub-internet.org/brad/>
Are you a USENET news server administrator outside of North America or
Western Europe? Would you like a newsfeed from a site in the Freenix
Top 65? If so, please contact me via private e-mail for details.
Re: Batched ARTICLE commands
Author: Curt Welch
Date: Sun, 27 Feb 2000 00:00
Date: Sun, 27 Feb 2000 00:00
145 lines
7904 bytes
7904 bytes
Brad Knowles <brad@shub-internet.org> wrote: > In article <20000226153651.615$gx@newsreader.com>, curt@kcwc.com (Curt > Welch) wrote: > > > MODE READER does cause a state change in inn. But it DOES NOT cause a > > protocol state change in the official definition of the protocol. > > > > MODE READER has been added to the latest RFC, but it's listed > > as a command which a client MAY send at any time. There is nothing in > > the RFC about the server changing states at that time. > > If it's specific to INN (where it causes a state change), and is > entirely optional on the part of the client, then since INN is the > reason that it exists at all (since it needs that state change), then > the definition automatically follows -- MODE READER causes a state > change when issued, because this is how the command operates in the > program for which this was added to the protocol. > > Otherwise MODE READER has no reason to exist. I'm not where you are going here. But I think you are trying to prove that the MODE READER does cause a state change? When talking to innd, it causes a state change (if allowed I think). When talking to nnrpd, it's a no-op, as it is in probably every other server written which implements the command. In the RFC, it DOES NOT cuase a state change. The RFC is NOT the real world. It's very important to understand that when we (I) talk about the world of the RFC, I'm not talking about the real world. These are two very different places. You can not "prove" that MODE READER causes a state change in the RFC by brining inn's behavior into the debate. As I said before, INN is not the RFC. It's not "the" standard. Though it is "a" standard. > > It's important for clients to wait for the return call from MODE READER > > not because it changes state, but because inn has a known bug where > > it may end up droping characters sent after the MODE command but before > > the response. This is very different from the optional protocol state > > changes (from command mode to data input mode) that occure with IHAVE > > and POST. The first is a real-world inn bug issue, the second are > > valid official NNTP protocol issues. > > It wouldn't be in the standard at all if INN didn't need it, and > since INN functions this way, the standard needs to reflect this fact. NO NO NO. It doesn't. The RFC only needs to specify enough so that people writing code which is complient to the RFC, will function correctly with inn. And to reach that goal, you do not have to drag all of INNs problems into the spec. > In this case, INN defines the "standard" from which this is taken. True, but INNs standard doesn't have to become "the" standard just to make this all work. What I'm saying, is that this whole state change business of innd vs nnrpd that INN does does not belong in the standard - and does not need to be there to "fix" this problem. My server for example changes states based on the current authorization of the client. It might have reading or feeding permission or both. On my server MODE READER is a no-op. If the client is authorized to do both, he can swtich back and forth between reading and feeding as much as he wanted durring the session. If the "INN" standard become THE RFC, then when the client sent a MODE READER, it would swtich to "reader commands only" mode (like INN does). And like inn, once you are in that mode, there is no way to return to "MODE FEED" (something I'm just now making up). Why would I want to criple my server like this just so it could be compatible with inn? Why would the writers of the RFC want to force all the other servers to be broken just like inn is? > There's no sense adding support for M-16 assault weapons if you're > going to turn around and disallow people from using 5.56Nato ammunition. > > > Well, no. The first is a clear violation of the RFC. The second > > isn't. So you are saying a client which follows the RFC is broken in a > > worse way than a server which does't follow the RFC? > > Either you write the RFC to describe how the ideal world works and > you expect everyone to live up to it, or you write the RFC to describe > how the real world works and what people need to do in order to cope > with it Yeah, this is what bothers me a bit about the NNTP standard. It tends to be a bit too much of a fairy tale world. It needs to be brought down a bit closer to the real world. > > Note I say SHOULD NOT, because servers MUST accept pipelining > > everywhere in my opinion - servers that can't, like inn, are broken, > > and should be fixed (or shout just remain broken and not care about > > it). > > In your opinion. Very key words. Hey, I use lots of CAPS and _UNDERLINES_. Dosn't that make it strong? :) > The standard as written is > actually completely silent on this issue, you are adding your own > interpretation to create this otherwise non-existant issue. Well, I think it's not silent at all about the issue becuse of the fact it brings in TCP/IP, but no one else seems to thing that's important. For those of you who don't see the TCP/IP foundation as clear evidence that it requires pipelining, then sure, all I say is meaningless on that issue. > I happen to agree with you that clients and servers both should > support pipelining everywhere that it is possible, but there are some > places where making this simplistic assumption simply won't work (for > practical reasons), The _ONLY_ (strong words eh?) practical reason is the fact that inn is so wide spread. It's not a practical issue in the techincal sense at all. INNs split process model is just the wrong way to build an NNTP server on a Unix box. No one else that I know of has made that mistake since. > and so long as the RFC is pointedly silent on this > issue, it doesn't make any sense railing against the wind. Or as I see it: Since everyone else is to blind to see that the RFC isn't silent on this issue, I might as well not waste my breath :).... > If you really feel this strongly about it, I suggest you get to work > on starting to define how a proper wall is built and then to actually > start building it -- get involved in USEFOR and the drafting of the > upcoming standard. USEFOR burned me out real fast. This is the NNTP RFC, not USEFOR thank god. -- Curt Welch http://CurtWelch.Com/ curt@kcwc.com Webmaster for http://NewsReader.Com/
Re: Batched ARTICLE commands
Author: Brad Knowles
Date: Sun, 27 Feb 2000 00:00
Date: Sun, 27 Feb 2000 00:00
41 lines
2702 bytes
2702 bytes
In article <20000226162848.241$4u@newsreader.com>, curt@kcwc.com (Curt
Welch) wrote:
> MODE READER is a non standard command which can fail simply because the
> server doesn't implement it. Clients should never assume anything
> about the return codes from it.
You're talking about pipelining, right? Okay, let's think about the
model of pipelining that is used in CPUs.
Don't tell me that in most CPUs that implement pipelining that you
don't occasionally run across some instructions (or situations) where
the whole pipeline is stalled and has to be restarted -- if nothing
else, poor branch prediction can do this to you, even if the commands
should theoretically continue to be capable of being pipelined.
Now, given this, why should you (or anyone else) expect that the
situation should be any different for pipelining when implemented in
other contexts, especially those contexts where the official standard is
pointedly silent on the issue of pipelining?
If you think the standard is broken because it doesn't explicitly
allow (or require) pipelining from clients, then I suggest you get
involved in the process to help write the upcoming version of the new
standard.
Myself, I got involved in that process at one time, and have since
disentangled myself from it. I just don't need that kind of crap in my
life.
--
Brad Knowles <brad@shub-internet.org> <http://www.shub-internet.org/brad/>
Are you a USENET news server administrator outside of North America or
Western Europe? Would you like a newsfeed from a site in the Freenix
Top 65? If so, please contact me via private e-mail for details.
Re: Batched ARTICLE commands
Author: Brian Kraft
Date: Mon, 28 Feb 2000 00:00
Date: Mon, 28 Feb 2000 00:00
15 lines
1691 bytes
1691 bytes
curt@kcwc.com (Curt Welch) wrote: > I'm sure most newsreadsers however treat 423 and 430 as equivilant > ways of saying "The articles not available", and that's why DNEWS can > get away with returning something differnt than diablo. With one difference that I know of; if Agent gets a 423 for article [nnn], it will fall back to trying to retrieve the article by Message-ID. It won't try to do that if it gets a 430 (the fallback feature can be disabled if responses are too slow). -- b h k
Re: Batched ARTICLE commands
Author: Brian Kraft
Date: Mon, 28 Feb 2000 00:00
Date: Mon, 28 Feb 2000 00:00
30 lines
2373 bytes
2373 bytes
Andrew Gierth wrote: >The implication of the examples in the draft is that "ARTICLE <id>" >should fail with 430, and "ARTICLE nnn" should fail with 423. "423 no such article number in this group" doesn't seem to fit a storage server situation where [nnn] still exists on a reader server that is unable to retrieve the body from some other machine. Also, would someone tell me what they think of this response: 430 Expired on upstream machine (423 No Such Article In Group ) That's verbatim from the client's log. It's returned by a DNews server which is setup for header only sucking of binaries groups. The response is to ARTICLE or BODY [nnn] for any article number, canceled or out of range, that doesn't exist in the reader server's list of articles. What the upstream server said is put in parentheses to help resolve problems. For the same article, HEAD [nnn] returns: 423 no such article number in this group Is this setup so different from a Diablo's storage server, so that the 423 response is correct for Diablo, while 430 is correct for DNews? I just asked about this in the support newsgroup netwin.dnews, where I was told that this 430 error code for ARTICLE [nnn] is the correct one. -- Brian Kraft bhkraft@gj.net
Re: Batched ARTICLE commands
Author: Curt Welch
Date: Mon, 28 Feb 2000 00:00
Date: Mon, 28 Feb 2000 00:00
22 lines
2360 bytes
2360 bytes
bhkraft@gj.net (Brian Kraft) wrote: > curt@kcwc.com (Curt Welch) wrote: > > > I'm sure most newsreadsers however treat 423 and 430 as equivilant > > ways of saying "The articles not available", and that's why DNEWS can > > get away with returning something differnt than diablo. > > With one difference that I know of; if Agent gets a 423 for article > [nnn], it will fall back to trying to retrieve the article by Message-ID. > It won't try to do that if it gets a 430 (the fallback feature can be > disabled if responses are too slow). Yeah, so that's even more proof of what newsreaders expect. There's probably some more code out there somewhere that will have problems as well. Glad I got my server doing the right thing now. Now all we need to do is make the RFC clear on that point... -- Curt Welch http://CurtWelch.Com/ curt@kcwc.com Webmaster for http://NewsReader.Com/
Re: Batched ARTICLE commands
Author: Curt Welch
Date: Mon, 28 Feb 2000 00:00
Date: Mon, 28 Feb 2000 00:00
65 lines
4148 bytes
4148 bytes
bhkraft@gj.net (Brian Kraft) wrote: > Andrew Gierth wrote: > > >The implication of the examples in the draft is that "ARTICLE <id>" > >should fail with 430, and "ARTICLE nnn" should fail with 423. > "423 no such article number in this group" doesn't seem to fit a > storage server situation where [nnn] still exists on a reader server > that is unable to retrieve the body from some other machine. > > Also, would someone tell me what they think of this response: > 430 Expired on upstream machine (423 No Such Article In Group ) The problem is that the RFC doesn't tell you which you should return when, so people either guess, or try to copy what some other server does. And now we have multiple servers returning differnt things. The newest draft RFC does imply what Andrew said above however. That 423 is used when you request an article by number, and 430 is what you get when you request it by Message-ID. I think that might match what INN does. > That's verbatim from the client's log. It's returned by a DNews > server which is setup for header only sucking of binaries groups. > The response is to ARTICLE or BODY [nnn] for any article number, I'm guessing DNEWS is the one which is "the most" non standard here. It should return 423 if the fetch was by number. I know for a fact that (at least one version of) INN will return 423 for a fetch by number of a canceled article. > canceled or out of range, that doesn't exist in the reader server's > list of articles. What the upstream server said is put in parentheses > to help resolve problems. For the same article, HEAD [nnn] returns: > 423 no such article number in this group That's bogus. HEAD and BODY should return the same code for the same error. The RFC doesn't say that it should, but it's bogus none the less. I'm sure most newsreadsers however treat 423 and 430 as equivilant ways of saying "The articles not available", and that's why DNEWS can get away with returning something differnt than diablo. Checking my newsreaders, I found an old one I wrote (using INN as the reference system), only ever checked for the 423 value. And I also find I "fixed" it later to also check for 430 because of "my" server --- which is doing the same thing as DNEWS is doing! So, I think what Andrew said above is what we should all be returning and what my server is doing and what DNEWS is doing is wrong. Mine will be fixed in few minutes :).... > Is this setup so different from a Diablo's storage server, so that the > 423 response is correct for Diablo, while 430 is correct for DNews? It just shows the weakness of the NNTP RFC. -- Curt Welch http://CurtWelch.Com/ curt@kcwc.com Webmaster for http://NewsReader.Com/
Re: Batched ARTICLE commands
Author: bill davidsen
Date: Tue, 29 Feb 2000 00:00
Date: Tue, 29 Feb 2000 00:00
59 lines
3783 bytes
3783 bytes
In article <bill-2602001125570001@192.168.254.8>, Bill Cole <bill@scconsult.com> wrote: | In article <250220002137494912%planb@newsreaders.com>, "J. Moreno" | <planb@newsreaders.com> wrote: | > Pipelining article commands results in a significant speed boost over | > doing things in sequence. This isn't of much concern to an online | > newsreader, but an offline newsreader will certainly want to take | > advantage of it, so documenting it explicitly would, IMO, be a good | > thing. If there is a significant improvement, the server is serious sick. The client software should be able to wait for a response and issue the next article request immediately. | Yes, and the selection of which commands should be pipelinable is simple: | if the command has a potential for leaving the session in a new state, it | cannot be pipelined. NNTP has fewer discrete states (for readers) than | SMTP, so fewer commands are likely to be dangerous. On the other hand, | commands which are intended to result in a state change but which may fail | (MODE, AUTHINFO, POST) are also pretty much useless to pipeline because it | is not safe for a client to assume that the next command is going to be | legal until there is a response. Add GROUP, obviously. | | > > But to say that the current RFC requires that it work is nonsense - | > > the RFC is simply silent on the issue. | > | > Curt's definitely right that it doesn't mention anything about being | > able to drop characters or requiring the client to wait for a response | > before proceeding, so I wouldn't exactly call it nonsense. If something isn't specified, how can you read a requirement that it work? The RFC doesn't address the issue, and I would read the request-response protocol to mean that the client should wait. | Curt is also right about the coding side: making a server that doesn't | pipeline means making a server that is more complex than it needs to be | from a coding perspective. The natural way to handle a protocol like NNTP | is to read every byte coming in and parse out commands, NOT to rely on | specific timing which is difficult (impossible on some OS's) to get | exactly right. I would be very surprised to find any server failing to | handle appropriately batched commands which is not otherwise broken in | some way. Could you give an example of an operating system which doesn't support a client server model which allows a client to send a request to the server and for the server to return a response? I don't see any "specific timing" involved, unless you mean that the request should come before the reply. It's easier to code that way ;-) -- bill davidsen <davidsen@tmr.com> CTO, TMR Associates, Inc When taking small children to a carnival, always have them go potty *before* you let them go on the rides, and let them eat all the junk food and candy *after*.
Re: Batched ARTICLE commands
Author: bill davidsen
Date: Tue, 29 Feb 2000 00:00
Date: Tue, 29 Feb 2000 00:00
66 lines
4033 bytes
4033 bytes
In article <20000225180328.114$Ys@newsreader.com>, Curt Welch <curt@kcwc.com> wrote: | Andrew Gierth <andrew@erlenstar.demon.co.uk> wrote: | > >>>>> "Curt" == Curt Welch <curt@kcwc.com> writes: | The truth is that the NNTP RFCs (at least all I've read), don't address the | issue at all. But it's very clear that if the client sends a valid | command, and the server decides to ignore it (or decides to ignore just | some of the bytes) -- then the server is not following the RFC. There's | just no other way to read the RFC. Actually I don't see any requirement that streaming be permitted, either. The RFC should say what the server must provide, and the current RFC seems to describe a request-response half duplex type of interraction. Streaming is not required, it falls out of some implementations for some request sequences. | > A case for comparison: the SMTP RFC documents a protocol with a | > somewhat similar form of commands & responses; but it turns out to be | > necessary for client implementations _not_ to pipeline commands by | > default (with ESMTP, the server can advertise that pipelining is OK). | | If the NNTP RFC called out cases where it was not OK for clients to | pipeline commands (and the only real reason for that I see -- is to | allow for servers to drop characters at that point), then a server which | dropped charcters at that point would be following the RFC. But none of | the RFCs I've seen allow for that. So, I think it's fair to see servers | which dropped characters anywhere in the stream are broken as per the | current RFCs. And if a server forked a process after a GROUP command? There might be a number of ARTICLE requests in a buffer of the parent, right? Which would not be dropped, but would be seen after the child terminated. | > This has been discussed (somewhat briefly) on the NNTP list, and the | > conclusion was that pipelining was OK with widely-deployed server | > implementations, with the exception of the MODE READER command (which | > in the rare cases when it is actually needed and is not a no-op, | > cannot be pipelined). I would be inclined to avoid trying it for | > AUTHINFO commands too. | | Yeah, I wasn't even thinking about the cases where the server is going | to try and hand-off the connection to another process. In that case, | it's hard to "get it right". But in my mind, INN has always been broken | in that respect. It's easy to get it right if you require the client to wait for a response before issuing another request. Suggestion: Rather than require some kind of streaming behaviour, why not extend the article command to take a list of articles, as do many other commands? Let the client unwind the stream. Should be able to use existing code for the most part, doesn't require streaming, allows whatever benefit someone thinks comes from doing this in the first plce, etc. -- bill davidsen <davidsen@tmr.com> CTO, TMR Associates, Inc When taking small children to a carnival, always have them go potty *before* you let them go on the rides, and let them eat all the junk food and candy *after*.
Re: Batched ARTICLE commands
Author: Brad Knowles
Date: Wed, 01 Mar 2000 00:00
Date: Wed, 01 Mar 2000 00:00
48 lines
3166 bytes
3166 bytes
In article <010320000300280729%planb@newsreaders.com>, "J. Moreno"
<planb@newsreaders.com> wrote:
> And comparing the underlying protocol versus the "natural" way of
> implementing the "top" protocol -- I think it's a close call, but
> absent a clear statement one way of the other you have to be as liberal
> as possible, and in this case that means accepting pipelining.
Agreed, but likewise we must also be as conservative as possible in
assuming what the other end can actually handle, which means that we do
not perform pipelining until and unless we're sure that the other end
can handle it (and this may need to be done on a case-by-case and
command-by-command basis).
This argument cuts two ways, and you can't win them both. The only
alternative is to be *explicit* on the issue of pipelining, in which
case there can be no argument.
> IMO it simply needs to be documented as standard behavior so that more
> clients will be able to take advantage of it and any future server
> authors will know that it is expected.
Document pipelining as part of the standard, please. Had that been
done earlier, we could have avoided this entire bloody thread.
> Given this situation, I think it'd be a mistake to not mention it, and
> the only possible thing to say is that it's a MUST to accept
> pipelining.
I don't think we can say "MUST" accept pipelining. I think we can
say "SHOULD" accept pipelining.
We already know that pipelining in certain implementations is broken
around certain commands, and I think you're talking about a pretty major
restructuring of INN if you want to force "MUST" on everyone across the
board.
--
Brad Knowles <brad@shub-internet.org> <http://www.shub-internet.org/brad/>
Note: No Microsoft programs were used in the creation or distribution of this
message. If you are using a Microsoft program to view this message, be
forewarned that I am not responsible for any harm you may encounter as a
result.
See <http://i-want-a-website.com/about-microsoft/twelve-step.html> for details.
Re: Batched ARTICLE commands
Author: J. Moreno
Date: Wed, 01 Mar 2000 00:00
Date: Wed, 01 Mar 2000 00:00
80 lines
4481 bytes
4481 bytes
Curt Welch <curt@kcwc.com> wrote: > davidsen@tmr.com (bill davidsen) wrote: > > If something isn't specified, how can you read a requirement that > > it work? > > You can't. But pipelining of commands in NNTP is specified. Some people > just don't know how to read an RFC. > > > The RFC doesn't address the issue, and I would read the > > request-response protocol to mean that the client should wait. > > Like I said. Some people don't know how to read an RFC. Where > does it say wait? > > If it doesn't specify a wait, how can you read a requirement that it > must do so? It's not explicit either way (except insofar as it inherits from other parts of the mechanism). And comparing the underlying protocol versus the "natural" way of implementing the "top" protocol -- I think it's a close call, but absent a clear statement one way of the other you have to be as liberal as possible, and in this case that means accepting pipelining. > I agree with you and the "others" that the natural asumption for a protocol > like this is that the client waits. But that's just because that's how we > think about these things, and how we (normally) write the software. And > because the RFC says nothing to get us out of that train of thought, people > reading the RFC can be confused. The authors of the RFC might not even > have given the issue much though. The authors might just have assumed that > the client would always be waiting. It seems that in general clients have made this assumption, servers haven't. > However, whatever the intent, the RFC they ended up with does define a > protocol that allows the client to pipeline commands. And that's the point > I've been trying to get across in this thread. > > Given the _fact_ that this protocol is based on a TCP/IP connection, a > "reliable data stream" -- i.e. one which guarantees the server receives > _every_ byte the client decides to send, the only way pipelining could fail > to work, is if the server failed to do it's job of parsing the input stream > into commands and data, and responding to each and every command sent by > the client. To a degree what the standard calls for is irrelevant, it's what actually gets implemented that is important -- and in that regards, pipelining seems to be very solid. I didn't get to test them all, but it seems to be supported by all the major news servers and is used by clients. IMO it simply needs to be documented as standard behavior so that more clients will be able to take advantage of it and any future server authors will know that it is expected. > And sure enough, the reason pipelining doesn't work sometimes in the > real world is just that. The server just decides that it's OK, to > take that "reliable data stream" as specified in the RFC, and turn it > into an "unreliable data stream". I can hear the server now, "Hey! > No fair! You sent that when I wasn't looking!". Right, tell it to > the judge... In the real world, it seems like mainly it just isn't a problem. One server with a reported 4000 byte incoming buffer, and one "server" (actually an echo of a web board) that treats it as a command/response protocol. Given this situation, I think it'd be a mistake to not mention it, and the only possible thing to say is that it's a MUST to accept pipelining. -- J. B. Moreno Pessimist: Half empty Optimist: Half full Engineer: Wrong size glass
Re: Batched ARTICLE commands
Author: Curt Welch
Date: Wed, 01 Mar 2000 00:00
Date: Wed, 01 Mar 2000 00:00
46 lines
3052 bytes
3052 bytes
davidsen@tmr.com (bill davidsen) wrote: > If something isn't specified, how can you read a requirement that it > work? You can't. But pipelining of commands in NNTP is specified. Some people just don't know how to read an RFC. > The RFC doesn't address the issue, and I would read the > request-response protocol to mean that the client should wait. Like I said. Some people don't know how to read an RFC. Where does it say wait? If it doesn't specify a wait, how can you read a requirement that it must do so? I agree with you and the "others" that the natural asumption for a protocol like this is that the client waits. But that's just because that's how we think about these things, and how we (normally) write the software. And because the RFC says nothing to get us out of that train of thought, people reading the RFC can be confused. The authors of the RFC might not even have given the issue much though. The authors might just have assumed that the client would always be waiting. However, whatever the intent, the RFC they ended up with does define a protocol that allows the client to pipeline commands. And that's the point I've been trying to get across in this thread. Given the _fact_ that this protocol is based on a TCP/IP connection, a "reliable data stream" -- i.e. one which guarantees the server receives _every_ byte the client decides to send, the only way pipelining could fail to work, is if the server failed to do it's job of parsing the input stream into commands and data, and responding to each and every command sent by the client. And sure enough, the reason pipelining doesn't work sometimes in the real world is just that. The server just decides that it's OK, to take that "reliable data stream" as specified in the RFC, and turn it into an "unreliable data stream". I can hear the server now, "Hey! No fair! You sent that when I wasn't looking!". Right, tell it to the judge... -- Curt Welch http://CurtWelch.Com/ curt@kcwc.com Webmaster for http://NewsReader.Com/
Re: Batched ARTICLE commands
Author: J. Moreno
Date: Wed, 01 Mar 2000 00:00
Date: Wed, 01 Mar 2000 00:00
80 lines
4708 bytes
4708 bytes
[[ This message was both posted and mailed: see the "To," "Cc," and "Newsgroups" headers for details. ]] In article <brad-DCB539.13171001032000@news.skynet.be>, Brad Knowles <brad@shub-internet.org> wrote: > In article <010320000300280729%planb@newsreaders.com>, "J. Moreno" > <planb@newsreaders.com> wrote: > > > And comparing the underlying protocol versus the "natural" way of > > implementing the "top" protocol -- I think it's a close call, but > > absent a clear statement one way of the other you have to be as liberal > > as possible, and in this case that means accepting pipelining. > > Agreed, but likewise we must also be as conservative as possible in > assuming what the other end can actually handle, which means that we do > not perform pipelining until and unless we're sure that the other end > can handle it (and this may need to be done on a case-by-case and > command-by-command basis). But we can do real world testing and see that except for some extreme cases it just works -- which was the other part of my argument. There may be problems (MODE READER and what not), but for basic piping of ARTICLE/BODY/HEAD/XHDR/XOVER commands, this seems to be pretty much the way things are done (although I'd like to get info from some more servers, still in the server world 8 of them is a lot). > This argument cuts two ways, and you can't win them both. The only > alternative is to be *explicit* on the issue of pipelining, in which > case there can be no argument. Well, that's what I'd like to see. > > IMO it simply needs to be documented as standard behavior so that more > > clients will be able to take advantage of it and any future server > > authors will know that it is expected. > > Document pipelining as part of the standard, please. Had that > been done earlier, we could have avoided this entire bloody thread. Yep. I had first tried finding it mentioned in the current draft, didn't see it, then I looked in the discussion archive and didn't see it there either, but on rechecking I see that it did come up under the subject "ietf-nntp Comments on the November draft" (brought up by Clive), but seemed to have stalled out (along with all of the other traffic) fairly quickly (although this could just be an artifact of the archive, I don't know what has actually happened on the list). I've just sent off a message to Stan about this, listing the various servers that I found that supported it. > > Given this situation, I think it'd be a mistake to not mention it, > > and the only possible thing to say is that it's a MUST to accept > > pipelining. > > I don't think we can say "MUST" accept pipelining. I think we can > say "SHOULD" accept pipelining. Unless someone pops up with some popular, real world, servers that don't support it, I think a MUST is reasonable. > We already know that pipelining in certain implementations is > broken around certain commands, and I think you're talking about a > pretty major restructuring of INN if you want to force "MUST" on > everyone across the board. Possibly a warning that it may break in some areas, but I think a blanket MUST (as long that is correct for most servers) would be best. If there are real problem areas that can't be fixed easily in INN (Russ?) then perhaps those areas could be excluded from the requirement (just as POST will/should be). -- J. B. Moreno Pessimist: Half empty Optimist: Half full Engineer: Wrong size glass
Re: Batched ARTICLE commands
Author: Curt Welch
Date: Wed, 01 Mar 2000 00:00
Date: Wed, 01 Mar 2000 00:00
22 lines
1945 bytes
1945 bytes
"J. Moreno" <planb@newsreaders.com> wrote: > In the real world, it seems like mainly it just isn't a problem. One > server with a reported 4000 byte incoming buffer, and one "server" > (actually an echo of a web board) that treats it as a command/response > protocol. Speaking of brain-dead servers, I thought you guys might enjoy this... After all this talk I've been doing about how the RFC clearly says that NNTP servers must do pipelining and that any server that can't is just a piece of crap, I get an e-mail from Forrest telling me that he had tracked down a recent probelm with his daily NNTP newsrate scripts and it turned out to be caused by _my_ server not pipelining LIST commands correctly! It's fixed now so I feel safe in sharing this with everyone :). -- Curt Welch http://CurtWelch.Com/ curt@kcwc.com Webmaster for http://NewsReader.Com/
Re: Batched ARTICLE commands
Author: Curt Welch
Date: Wed, 01 Mar 2000 00:00
Date: Wed, 01 Mar 2000 00:00
72 lines
4440 bytes
4440 bytes
davidsen@tmr.com (bill davidsen) wrote: > In article <bill-2602001125570001@192.168.254.8>, > Bill Cole <bill@scconsult.com> wrote: > | In article <250220002137494912%planb@newsreaders.com>, "J. Moreno" > | <planb@newsreaders.com> wrote: > > | > Pipelining article commands results in a significant speed boost over > | > doing things in sequence. This isn't of much concern to an online > | > newsreader, but an offline newsreader will certainly want to take > | > advantage of it, so documenting it explicitly would, IMO, be a good > | > thing. > > If there is a significant improvement, the server is serious sick. The > client software should be able to wait for a response and issue the next > article request immediately. Have you every tried it in real life Bill? You have heard of MODE STREAM haven't you? streaming ARTICLE commands will have the same effect but in the opposit direction. Lets do a few numbers just to illustate. The effect is largest with small articles, a fast server, and a high latency link. Think about the extream case -- a T3 to the moon. But to get real, lets say we are on 1 Mbit/sec link with a 100 msec ping time between the client and the server. Or, lets just say it takes 50 msec for a bit to travel one way in either direction. (about what you see going across the US). Lets say the ARTICLE command goes in a packet which is 50 bytes long. That's 400 bits, and .4 msec to transmit. Lets call that 0. After 50 msec of transit time, the server has it and has started working on fetching the article which lets say takes 20 msec. It's 960 bytes and fits in a a 1000 byte packet. That's 8000 bits and takes 8 msec to transmit. 50 msec later, the client has it and then fires off the next command. So that took 50+20+8+50 or 128 msec to get one 960 byte article. or 960 / .128sec is 7500 bytes per second. Next time we send two article commands at once. The packet is 12 bytes larger, so it takes .496 msec to send. Lets call that 1. plus 50 to get there. 20 msec later, the first article starts comming back. How long it takes for the server to get done depends on how good it is at parallel operations, but lets just say it can't do any of that in parallel and it takes another full 20 msec to get the second article and start it off on it's way back. Then, plus 50 msec of delay. So this time, we have 1+50+20+20+8+50 or a total of time or 149 msec for 2 articles. So this time, it's (960*2)/.149 sec or 12855 bytes per second. That's an extra 5, 385 bytes per second just by sending two article command at once instead of 1. If the server can keep up, full pipelining gets you a new article ever 20 msec. That would be 960 / .02 48K bytes per second. So, no pipelining - 7,500 Bytes per second. Full pipelining - 48,000 Bytes per second - 6.4x faster. Notice also that with a 6.5x improvement, you can gain the same speed-up if you use 7 parallel NNTP connections to do the fetches - each sequentially. The improvements are noticable even when you are on a local network with the server, just not as much as this. With a 5 msec transit delay instead of 50, you get: 5+20+8+5=38 msec per article with no pipelining or 25,263 bytes per second vs the same max as above with full pipelining or 48,000. Still more than a 2x speed up. -- Curt Welch http://CurtWelch.Com/ curt@kcwc.com Webmaster for http://NewsReader.Com/
Re: Batched ARTICLE commands
Author: J. Moreno
Date: Wed, 01 Mar 2000 00:00
Date: Wed, 01 Mar 2000 00:00
58 lines
3148 bytes
3148 bytes
In article <20000229221630.469$Gx@newsreader.com>, Curt Welch <curt@kcwc.com> wrote: > davidsen@tmr.com (bill davidsen) wrote: > > In article <bill-2602001125570001@192.168.254.8>, > > Bill Cole <bill@scconsult.com> wrote: > > | In article <250220002137494912%planb@newsreaders.com>, "J. Moreno" > > | <planb@newsreaders.com> wrote: > > > > | > Pipelining article commands results in a significant speed boost over > > | > doing things in sequence. This isn't of much concern to an online > > | > newsreader, but an offline newsreader will certainly want to take > > | > advantage of it, so documenting it explicitly would, IMO, be a good > > | > thing. > > > > If there is a significant improvement, the server is serious sick. The > > client software should be able to wait for a response and issue the next > > article request immediately. > > Have you every tried it in real life Bill? [...] > But to get real, lets say we are on 1 Mbit/sec link with a 100 msec > ping time between the client and the server. Or, lets just say it > takes 50 msec for a bit to travel one way in either direction. (about > what you see going across the US). [...] > With a 5 msec transit delay instead of 50, you get: 5+20+8+5=38 msec per > article with no pipelining or 25,263 bytes per second vs the same max > as above with full pipelining or 48,000. Still more than a 2x speed up. � Ping Completed � PING: curts.server PKT# RESULT TIME(ms) LENGTH 1 success 324 40 2 success 264 40 3 success 386 40 4 success 267 40 5 success 362 40 6 success 195 40 7 success 320 40 8 success 245 40 Packets out/in/bad/%loss = 8/8/0/0.0 Round Trip Time (ms) min/avg/max = 195/295/386 � Ping Completed � Not a trip to the moon, but not very fast either. From real world observations (untimed, but I'm watching different programs do the same groups, and it's pretty obvious that this makes a 3-4x difference [at least] for me). -- J. B. Moreno Pessimist: Half empty Optimist: Half full Engineer: Wrong size glass
Re: Batched ARTICLE commands
Author: Bill Cole
Date: Thu, 02 Mar 2000 00:00
Date: Thu, 02 Mar 2000 00:00
105 lines
6068 bytes
6068 bytes
In article <89hm53$bd1$1@newssvr02.news.prodigy.com>, davidsen@tmr.com (bill davidsen) wrote: > > In article <bill-2602001125570001@192.168.254.8>, > Bill Cole <bill@scconsult.com> wrote: > | In article <250220002137494912%planb@newsreaders.com>, "J. Moreno" > | <planb@newsreaders.com> wrote: > > | > Pipelining article commands results in a significant speed boost over > | > doing things in sequence. This isn't of much concern to an online > | > newsreader, but an offline newsreader will certainly want to take > | > advantage of it, so documenting it explicitly would, IMO, be a good > | > thing. > > If there is a significant improvement, the server is serious sick. The > client software should be able to wait for a response and issue the next > article request immediately. No. Think network latency. Think about the time it takes for a server to assemble a response. Consider that CHECK/TAKETHIS exists for the same reasons that batching ARTICLE/HEAD/XOVER/XHDR is useful. If a client pushes a series of commands on the session it can then sit back and wait for the responses. The server can also (if written well) prep all the responses and queue them so that there is ZERO pause between them. It is quite possible to be fetching an article from disk while sending the previously requested article over the wire, but ONLY if the command to do that fetch has been pushed along before the client has received the previous response. The server will not be sending any data for the RTT plus the response prep time if the client sticks to a pure request/response model. [...] > | Curt is also right about the coding side: making a server that doesn't > | pipeline means making a server that is more complex than it needs to be > | from a coding perspective. The natural way to handle a protocol like NNTP > | is to read every byte coming in and parse out commands, NOT to rely on > | specific timing which is difficult (impossible on some OS's) to get > | exactly right. I would be very surprised to find any server failing to > | handle appropriately batched commands which is not otherwise broken in > | some way. > > Could you give an example of an operating system which doesn't support > a client server model which allows a client to send a request to the > server and for the server to return a response? I don't see any > "specific timing" involved, unless you mean that the request should come > before the reply. It's easier to code that way ;-) I was speaking of the SERVER behavior. I'm pretty sure Curt was too. The problem is not in failing to allow a pure request/response model, but in attempting to enforce that model: it's hopelessly complex. The server has no way of determining when the client has seen all of a response, so it has no way of telling when a new command is 'legal' if pipelining is 'illegal' and in fact on some OS's (I was thinking specifically of MacOS where I've done some server coding, but I suspect many others as well such as Solaris or anything using STREAMS or similar layered abstractions for transport) it has no way to even know when a response has actually hit the wire. If there's no transparency to TCP ACK's, the server cannot know when a client has seen the last of a response and so could 'legally' send a new command. Even if it could, there's no way for the server to know that an app has actually read all the data from that stream, so any attempt by a server to enforce 'no streaming of commands' is hopeless in a protocol without an application-level ACK to responses. Failure to handle batched commands is an artifact of how servers are structured, usually (always?) a result of a state change that hands off a connection to a new process. THAT is understandable, and I think it is unwise for the spec to demand that a client can do something like this without waiting for responses: AUTHINFO USER me AUTHINFO PASS secretstuff GROUP news.software.nntp HOWEVER, a server that FAILS to handle a stream of batched ARTICLE, XOVER, HEAD, XHDR, or similar commands which do not evoke a state change in success or failure is problematic. The failures in INN are not much of an issue IMHO because a client that would try to batch the problem commands is a stupidly written client, however INN can't reliably drop commands batched that way (at least not in theory. I have not tested much) . The whole argument devolves into some silliness: no server not otherwise badly broken fails to work with batched commands that make sense to batch. If there is anything in the spec about this, I think it should define batching that a server MUST support and that servers MAY allow other batching with the warning that clients MUST wait for a response to any command if the following command presumes a specific sort of success of the command. I can even see batching GROUP commands in a common newsreading model (used for many GUI newsreaders) because typically there is a stream of GROUP commands sent just to get the current article counts for subscribed groups. -- Bill Cole, Geek at large I'm casually looking for a new job See: http://sc1.scconsult.com/~bill/resume.html for a resume and more 5094th at Freenix!!!
Re: Batched ARTICLE commands
Author: J. Moreno
Date: Fri, 03 Mar 2000 00:00
Date: Fri, 03 Mar 2000 00:00
20 lines
1843 bytes
1843 bytes
In article <bill-0203002213340001@192.168.254.8>, Bill Cole <bill@scconsult.com> wrote: > If there is anything in the spec about this, I think it should define > batching that a server MUST support and that servers MAY allow other > batching with the warning that clients MUST wait for a response to any > command if the following command presumes a specific sort of success of > the command. I can even see batching GROUP commands in a common > newsreading model (used for many GUI newsreaders) because typically there > is a stream of GROUP commands sent just to get the current article counts > for subscribed groups. YANW uses batched GROUP commands, which I believe it inherited from NewsWatcher. And it's used for just that purpose. -- J. B. Moreno Pessimist: Half empty Optimist: Half full Engineer: Wrong size glass
Page 1 of 2 • 55 total messages
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