🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.nntp
Article #84121

Re: File descriptor limits.

#84121
From: Julien ÉLIE
Date: Sat, 11 Jun 2011 22:02
47 lines
3549 bytes
Hi Russ,

> At this point, actually, the best solution to this problem would probably
> be to do the work to replace INN's event loop with something that handles
> all these details for us, like libevent.  See:
>
>      http://www.monkey.org/~provos/libevent/
>
> Adding our own portability for epoll would basically be redoing the work
> of libevent, except without the same user and testing base.

I have just taken time to read more carefully what libevent does.  (We 
recently spoke about it in a discussion for TLS support in innd.)

That library has great features.

I even see a evdns_getaddrinfo() function which does an asynchronous DNS 
request, with a callback when the resolution is done.

     http://mc.kev009.com/libevent/dns_8h.html

It would solve a long-standing feature request for INN!

I'm just wondering:  when should DNS requests be done?  Every time we 
have to open a socket?  (We therefore rely on the DNS cache capability 
of the system so that it does not send the actual request before the TTL.)

I see that libevent handles timeouts.  It could be useful at several 
places in our code (client timeout, channels timeout or things like that).
It also does buffering when sending data.  It could also be used in lieu 
of the buffering system in nnrpd for instance.

A bufferevent_openssl library exists…  It could be useful for TLS 
support in innd.  I assume it solves the problem of synchronizing TLS 
data blocks.


Well, libevent looks pretty promising to use with INN.
The libevent license allows to redistribute their source code.  So we 
basically just have to ship the relevant files in include/libevent?  (I 
hope they compile fine with gcc warnings on.)

-- 
Julien ÉLIE

« Un voyage de mille lieues commence toujours par un premier pas. »
   (Lao Zi)
Technical Details
Message-ID: <it0omf$hp5$1@news.trigofacile.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.20141118.mbox.gz!num2.nntp.dca.giganews.com!num1.nntp.dca.giganews.com!number.nntp.dca.giganews.com!backlog1.nntp.dca3.giganews.com!border1.nntp.dca3.giganews.com!border2.nntp.dca3.giganews.com!border4.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!npeer01.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!nx02.iad01.newshosting.com!newshosting.com!news2.euro.net!feeder.news-service.com!de-l.enfer-du-nord.net!feeder1.enfer-du-nord.net!gegeweb.org!news.trigofacile.com!.POSTED.aaubervilliers-552-1-21-61.w92-141.abo.wanadoo.fr!not-for-mail
References: <ijc6vh$12l$1@snarked.org> <95gqhdFd2hU1@mid.individual.net> <87k4csm9gs.fsf@windlord.stanford.edu>

Show Full Headers
Complete Article Headers
Message-ID: <it0omf$hp5$1@news.trigofacile.com>
Subject: Re: File descriptor limits.
Date: Sun, 12 Jun 2011 00:02:55 +0200
From: Julien ÉLIE <iulius@nom-de-mon-site.com.invalid>
References: <ijc6vh$12l$1@snarked.org> <95gqhdFd2hU1@mid.individual.net> <87k4csm9gs.fsf@windlord.stanford.edu>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.20141118.mbox.gz!num2.nntp.dca.giganews.com!num1.nntp.dca.giganews.com!number.nntp.dca.giganews.com!backlog1.nntp.dca3.giganews.com!border1.nntp.dca3.giganews.com!border2.nntp.dca3.giganews.com!border4.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!npeer01.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!nx02.iad01.newshosting.com!newshosting.com!news2.euro.net!feeder.news-service.com!de-l.enfer-du-nord.net!feeder1.enfer-du-nord.net!gegeweb.org!news.trigofacile.com!.POSTED.aaubervilliers-552-1-21-61.w92-141.abo.wanadoo.fr!not-for-mail
Newsgroups: news.software.nntp
Organization: TrigoFACILE -- http://www.trigofacile.com/
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 11 Jun 2011 22:02:55 +0000 (UTC)
Injection-Info: news.trigofacile.com;
 posting-host="aaubervilliers-552-1-21-61.w92-141.abo.wanadoo.fr:92.141.84.61";
 logging-data="18213"; mail-complaints-to="abuse@trigofacile.com"
User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; fr;
In-Reply-To: <87k4csm9gs.fsf@windlord.stanford.edu>
Lines: 46
X-Original-Bytes: 3216