libmicrohttpd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [libmicrohttpd] feature request: get connection_timeout value from M


From: Evgeny Grin
Subject: Re: [libmicrohttpd] feature request: get connection_timeout value from MHD_Connection structure
Date: Wed, 15 Mar 2017 12:58:52 +0300
User-agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0

On 15.03.2017 8:43, Vitaliy T wrote:
> On 14 March 2017 at 23:30, Evgeny Grin <address@hidden> wrote:
>> You don't need to restore timeout value. It's not changed if you use
>> suspend/resume.
>> Timeout timer is restarted after each resume of connection.
> 
> My situation is:
> 
> 1. I set MHD_OPTION_CONNECTION_TIMEOUT to say 5 seconds.
> 2. Many clients connecting to the server simultaneously.
> 3. Only one connection will be proceed per a time, others will be suspended.
> 4. The active connection is working more than 5 seconds.
> 5. When the active connection is finished working I resume all
> connection that were suspended.
> 6. Instead of proceeding everything as expected MHD sends silently the
> hardcoded message above.

> 
> This is a workaround about the issue. I don't know how many seconds will be 
> last
> a "work" for an active connection. I can't set connection timeout too
> high because
> I don't know what is limit. In the same time I wish that there be some
> connection timeout for
> "slow" clients.

Why do you want to play with timeout during connection suspend?
Function description explicitly state:
"Suspended connections will NOT time out; timeouts will restart when the
connection handling is resumed."

> My business to suggest. Ok, I will fix this myself.

Could you describe in details: what do you want to get, how did you
start MHD and what is not working?
You omit important details in your description, it's hard to guess every
missing thing.
In one thread you are asking about external polling, in another - about
timeout and suspend/resume. Are those questions connected or independent
situations?

MHD API is very flexible, I will allow to do many things without any API
breakage.

> 
> Thanks!
> 
You are welcome!


-- 
Best Wishes,
Evgeny Grin



reply via email to

[Prev in Thread] Current Thread [Next in Thread]