🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: alt.free.newsservers
Article #47405

Re: Test farm up, no restrictions, knock yourselves out.

#47405
From: James
Date: Tue, 08 Jun 2004 09:27
34 lines
3188 bytes
On Tue, 08 Jun 2004 06:07:06 GMT, Curt
<curt.hartung_NOSPAM@AT_highwinds-software.com> wrote:

>PROBLEM: Create a data structure which can insert at least 100 ID's per 
>second and associate at least two 32-bit values with them, but scale to 
>at least 5000 per second (so a server can catch up after at least 16 
>hours of downtime). While simultaneously (multithreaded) performing 
>lookups at a rate of at least 10 per second, randomly distributed amongst 
>every entry (ie- no assumptions can be made about locality). Oh and don't 
>strain the disks any more, they are already at capacity ;)

Flip the problem around, as NetApp does. Store by message-id (probably
using the hashed directory setup Squid does for cache spools), then
create a datastructure for tracking the article#->message-id mapping
for each newsgroup. Since these numbers increase monotonically and
message-ids have a relatively small bounded size, a ringbuffer should
suffice - and of course, you're already iterating over the groups
posted to for numbering purposes.

Of course, assuming an average two groups per article, that would
appear to imply 15,000 disk I/O operations per second (updating two
group ring buffers, plus writing the article itself) when catching up
on a feed - enough to ruin the day of even a big fast RAID array, even
before you factor in filesystem metadata. Fortunately, you can buffer
the group ring buffer updates for write coalescing, and structure the
article storage to allow multiple articles to be stored per I/O
operation there...

>Actually I think its fun as hell to write this stuff, call me a nerd :)

Not the only one, at least :)


James.
Technical Details
Message-ID: <7k0bc0d8524jieajirjst3qp720f5helhs@4ax.com>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!mbox2nntp-alt.free.newsservers.20140909.mbox.gz!number1.nntp.dca.giganews.com!internal1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!news-hub.cableinet.net!blueyonder!doctor.cableinet.net.POSTED!53ab2750!not-for-mail
References: <Xns9500CE3DBA6C3cunohighsger@216.77.188.18> <Xns9500E14851821vegasedvegasedvegase@63.223.5.254> <Xns9501EEACB410cunohighsger@216.77.188.18> <dvh8c0p99nbqhup10mcj80d2t9lct7idbo@4ax.com> <s_Zwc.6135478$iA2.705535@news.easynews.com> <kqr8c0hscgmju3s6bv6nmgocv4ofp2k73b@4ax.com> <3ot8c09aip1lb2r1j29efj3mke1m33ogma@192.168.1.3> <Xns95017384463B1vegasedvegasedvegase@63.223.5.254> <epg9c0tap8oc816bjq89stoqocl59fl1ps@192.168.1.3> <Xns9502168C6B10Acunohighsger@216.77.188.18>

Show Full Headers
Complete Article Headers
Message-ID: <7k0bc0d8524jieajirjst3qp720f5helhs@4ax.com>
Subject: Re: Test farm up, no restrictions, knock yourselves out.
Date: Tue, 08 Jun 2004 10:27:02 +0100
From: James <jas@spamcop.net>
References: <Xns9500CE3DBA6C3cunohighsger@216.77.188.18> <Xns9500E14851821vegasedvegasedvegase@63.223.5.254> <Xns9501EEACB410cunohighsger@216.77.188.18> <dvh8c0p99nbqhup10mcj80d2t9lct7idbo@4ax.com> <s_Zwc.6135478$iA2.705535@news.easynews.com> <kqr8c0hscgmju3s6bv6nmgocv4ofp2k73b@4ax.com> <3ot8c09aip1lb2r1j29efj3mke1m33ogma@192.168.1.3> <Xns95017384463B1vegasedvegasedvegase@63.223.5.254> <epg9c0tap8oc816bjq89stoqocl59fl1ps@192.168.1.3> <Xns9502168C6B10Acunohighsger@216.77.188.18>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!mbox2nntp-alt.free.newsservers.20140909.mbox.gz!number1.nntp.dca.giganews.com!internal1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!news-hub.cableinet.net!blueyonder!doctor.cableinet.net.POSTED!53ab2750!not-for-mail
Newsgroups: alt.free.newsservers
X-Newsreader: Forte Agent 2.0/32.652
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Lines: 34
NNTP-Posting-Host: 82.40.124.103
X-Complaints-To: abuse@blueyonder.co.uk
X-Trace: doctor.cableinet.net 1086686866 82.40.124.103 (Tue,
NNTP-Posting-Date: Tue, 08 Jun 2004 10:27:46 BST