Re: [Vala] libsoup serves only one request at a time
- From: "Mark Delany" <v2h xray emu st>
- To: "Joseph Montanez" <jmontanez gorilla3d com>
- Cc: vala-list <vala-list gnome org>
- Subject: Re: [Vala] libsoup serves only one request at a time
- Date: 4 Apr 2012 07:15:40 +0000
On Fri, Mar 16, 2012 at 7:26 AM, Edwin DLCA <edwinspire gmail com> wrote:
I have a small application that serves html pages. It works fine, but when
the page is too large can not address other petivciones until finishes
sendingthe page.
Is there any way to make libsoup attend several requests on multiplethreads
at once?
I think it depends on where the blocking is occuring. You'll need to
explain what "too large" means. Is the handler reading this large
content from a file and taking too long?
If you have good control over the handler, one way that doesn't
require threads is to use the Soup.Server.pause_message() call and
then have a signal handler call Soup.Server.unpause_message() when the
content is available to send.
The other approach is to look at the chunking interface in
Soup.Message. That lets you feed bits of the response at a time.
Mark.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]