🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.nntp
Article #67136

Re: Programming/NNTP Questions

#67136
From: aaronb
Date: Mon, 10 Nov 2003 18:42
44 lines
3436 bytes
What you are doing sounds similar to what I'm doing... I suppose. I don't
understand what you are defining as a packet... doesn't the server send you
all the data you've requested in one long stream? Isn't it up to us as the
programmer to decide where to break off receiving data and process it? I've
tried using anything from 1 byte at a time up to 4-8k bytes in one read....
but I have yet to find a sweet spot that I'm satisfied with.

Yes, data does build up when I use a 256 byte buffer... I started out using
a 32 byte buffer so that I didn't have much if anything left over after
receiving one complete header but I found that I shaved off some processing
time when moving up to 256.

I start off by creating a TCPClient and connect to the server, send my
commands, process the first 3 bytes received so I can know what response
code was given and treat it accordingly. When I know that the XOVER data
will be coming, I switch over to the 256byte buffer and loop till done.

I guess what I'm looking for is other conceptual methods of interacting with
the incoming stream that will increase the speed of the program. I've timed
Outlook express, Newsbin and Xnews and they are all very similar in speed,
but my process is anywhere from 2-5 times slower. I had not thought of
sending multiple XOVER commands to receive the data in multiple streams.
That does sound like a great idea.

"DS" <t.h.i.s.n.t.h.a.t@a.d.e.l.p.h.i.a..n.e.t> wrote in message
news:Xns942F59DEF723Aidispcom@24.48.107.54...
> "aaronb" <borgaaron@yahoo.com> wrote in
> news:3faf228c$0$801$c3e8da3@news.astraweb.com:
> So in response to the rx buffer size, I never messed with any of those
> settings. On a fast server, incoming data can be 4096K, on slower servers
> sometimes it's only a few hundred bytes. The only leftover data I'm
storing
> is incomplete header info. I end up processing all of the received data
> before I accept another packet. Depending on you're server's speed, and
the
> fact that you're only taking 256 bytes at a time, I can see the 'leftover'
> buffer growing to be huge at somepoint, depending on the additional
> processing you're doing.
>
>
> DS
>

Technical Details
Message-ID: <3fafdbf0$0$15854$c3e8da3@news.astraweb.com>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.20140818.mbox.gz!news5.aus1.giganews.com!firehose2!nntp4!intern1.nntp.aus1.giganews.com!border3.nntp.aus1.giganews.com!small1.nntp.aus1.giganews.com!nntp.giganews.com!newshub.sdsu.edu!cyclone.bc.net!news.alt.net!news.astraweb.com!news-big.astraweb.com!not-for-mail
References: <3fa1d38d$0$50372$c3e8da3@news.astraweb.com> <Xns94284B9E63709idispcom@24.48.107.53> <3faf228c$0$801$c3e8da3@news.astraweb.com> <Xns942F59DEF723Aidispcom@24.48.107.54>

Show Full Headers
Complete Article Headers
Message-ID: <3fafdbf0$0$15854$c3e8da3@news.astraweb.com>
Subject: Re: Programming/NNTP Questions
Date: Mon, 10 Nov 2003 10:42:30 -0800
From: "aaronb" <borgaaron@yahoo.com>
References: <3fa1d38d$0$50372$c3e8da3@news.astraweb.com> <Xns94284B9E63709idispcom@24.48.107.53> <3faf228c$0$801$c3e8da3@news.astraweb.com> <Xns942F59DEF723Aidispcom@24.48.107.54>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.20140818.mbox.gz!news5.aus1.giganews.com!firehose2!nntp4!intern1.nntp.aus1.giganews.com!border3.nntp.aus1.giganews.com!small1.nntp.aus1.giganews.com!nntp.giganews.com!newshub.sdsu.edu!cyclone.bc.net!news.alt.net!news.astraweb.com!news-big.astraweb.com!not-for-mail
Newsgroups: news.software.nntp
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
Lines: 44
Organization: Unlimited download news at news.astraweb.com
NNTP-Posting-Host: 35a90581.news.astraweb.com
X-Trace: DXC=Zg; @MgLL<; ?4K?0c7HD\@7L?0kYOcDh@:]WEZ@Q1WnG5Z\S; R>Ff7:4I@CL; Ai;
 YH:glAoj4X8HZ51gIBN7IX>Q6