From: Eli Zaretskii <eliz@gnu.org>
To: Lars Ingebrigtsen <larsi@gnus.org>
Cc: emacs-devel@gnu.org
Subject: Re: Asynchronous DNS resolving
Date: Fri, 13 Feb 2015 10:46:04 +0200 [thread overview]
Message-ID: <83siea42sz.fsf@gnu.org> (raw)
In-Reply-To: <877fvmffrz.fsf@building.gnus.org>
> From: Lars Ingebrigtsen <larsi@gnus.org>
> Date: Fri, 13 Feb 2015 18:10:24 +1100
>
> So perhaps doing what Firefox used to do in the 90s would be a possibly
> solution, anyway? That is, have a teensy multi-threaded executable that
> reads commands from STDIN and outputs the replies on STDOUT. Like
> lib-src/dns-helper.c or something.
>
> The command format would be something like
>
> <tag> <command> <data>
>
> I.e.,
>
> 45 lookup fsf.org
> 46 lookup images.fsf.org
> ...
>
> (Tags for streaming commands and matching up the responses with the
> requests, a la IMAP.)
>
> We'd then have something like
>
> (with-domain-name-lookup (ip "fsf.org")
> (message "We got %s and now we're going to connect" ip)
> (with-url ("http://fsf.org" :ip-address ip ...)
> (pop-to-buffer (current-buffer))))
>
> to do a completely asynchronous web request.
>
> Or does anybody have a better idea for solving this problem?
Can't you simulate async resolution with timers? Or even by opening a
network-process to the DNS server and talking to it directly (which
can be done asynchronously with filters and sentinels and stuff)?
next prev parent reply other threads:[~2015-02-13 8:46 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-02-13 7:10 Asynchronous DNS resolving Lars Ingebrigtsen
2015-02-13 7:21 ` Paul Eggert
2015-02-13 7:32 ` Lars Ingebrigtsen
2015-02-13 7:58 ` Paul Eggert
2015-02-13 19:20 ` Stefan Monnier
2015-02-14 0:06 ` chad
2015-02-14 3:44 ` Lars Ingebrigtsen
2015-02-14 6:20 ` Paul Eggert
2015-02-15 4:54 ` Lars Ingebrigtsen
2015-02-13 8:46 ` Eli Zaretskii [this message]
2015-02-13 9:02 ` Lars Ingebrigtsen
2015-02-15 5:31 ` Lars Ingebrigtsen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=83siea42sz.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=emacs-devel@gnu.org \
--cc=larsi@gnus.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).