<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
<channel>
<title>when to call ngx_handle_write_event?i am not really understanded.</title>
<description>when to call ngx_handle_write_event?i am not really understanded.
who can explain me?
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel</description><link>http://forum.nginx.org/read.php?29,227181,227181#msg-227181</link><lastBuildDate>Thu, 23 May 2013 11:44:07 -0400</lastBuildDate>
<generator>Phorum 5.2.16</generator>
<item>
<guid>http://forum.nginx.org/read.php?29,227181,227196#msg-227196</guid>
<title>Re: when to call ngx_handle_write_event?i am not really understanded.</title><link>http://forum.nginx.org/read.php?29,227181,227196#msg-227196</link><description><![CDATA[3Q again, :D<br /><br />2012/6/5 Vladimir Shebordaev &lt;vshebordaev@mail.ru&gt;:<br />&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt; soga, my src\os\win32\ is download from<br />&gt;&gt; https://github.com/hehaiqiang/nginx, where is the official source for<br />&gt;&gt; win32?<br />&gt;<br />&gt; Not sure about win32 specific sources, but you can get stock nginx 1.3.1 from<br />&gt;<br />&gt; svn://svn.nginx.org/nginx/trunk<br />&gt;<br />&gt;&gt;<br />&gt;&gt; 2012/6/5 Vladimir Shebordaev &lt;vshebordaev@mail.ru&gt;:<br />&gt;&gt;&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt;&gt;&gt; okay, 3Q.<br />&gt;&gt;&gt;&gt; another question, in ngx_wsasend.c 's ngx_wsasend function<br />&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt; #if 0 // is test code?or really should do it?<br />&gt;&gt;&gt;&gt;       if ((size_t) n &lt; size) {<br />&gt;&gt;&gt;&gt;           wev-&gt;ready = 0;<br />&gt;&gt;&gt;&gt;       }<br />&gt;&gt;&gt;&gt; #endif<br />&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;<br />&gt;&gt;&gt; As of the current release 'ready' flag is reset there. You should<br />&gt;&gt;&gt; update nginx sources.<br />&gt;&gt;&gt;<br />&gt;&gt;&gt; ngx_handle_write_event() belongs to upper layer interface and is<br />&gt;&gt;&gt; anyways expected to be called.<br />&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt; 2012/6/5 Vladimir Shebordaev &lt;vshebordaev@mail.ru&gt;:<br />&gt;&gt;&gt;&gt;&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt;&gt;&gt;&gt;&gt; sorry, fix: call ngx_handle_write_event?<br />&gt;&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt;&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt; if i do not call ngx_handle_write_event  the ngx_connection_t 's<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt; ngx_event_t *write will never be handler.<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt; it means after c-&gt;send(c, buf, n) then call c-&gt;send(c, buf, n)?<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt; Yes, you should firstly process the data then update the connection<br />&gt;&gt;&gt;&gt;&gt; state for the next event, i.e. call ngx_handle_write_event()<br />&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt; 2012/6/5 Vladimir Shebordaev &lt;vshebordaev@mail.ru&gt;:<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt; Hi!<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt; ngx_handle_write_event() is the event processiong state machine<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt; interface function that is to proper update event and connection<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt; states after write event is fired and the data has been probably<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt; written to the corresponding descriptor. It can optionally update<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt; send_lowat option on the connection socket.<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt; --<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt; Regards,<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt; Vladimir<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt; when to call ngx_handle_write_event?i am not really understanded.<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt; who can explain me?<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt; _______________________________________________<br />&gt;&gt;&gt;&gt;&gt; nginx-devel mailing list<br />&gt;&gt;&gt;&gt;&gt; nginx-devel@nginx.org<br />&gt;&gt;&gt;&gt;&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br />&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt; _______________________________________________<br />&gt;&gt;&gt;&gt; nginx-devel mailing list<br />&gt;&gt;&gt;&gt; nginx-devel@nginx.org<br />&gt;&gt;&gt;&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br />&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;<br />&gt;&gt;&gt; _______________________________________________<br />&gt;&gt;&gt; nginx-devel mailing list<br />&gt;&gt;&gt; nginx-devel@nginx.org<br />&gt;&gt;&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br />&gt;&gt;<br />&gt;&gt; _______________________________________________<br />&gt;&gt; nginx-devel mailing list<br />&gt;&gt; nginx-devel@nginx.org<br />&gt;&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br />&gt;&gt;<br />&gt;<br />&gt; _______________________________________________<br />&gt; nginx-devel mailing list<br />&gt; nginx-devel@nginx.org<br />&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br /><br />_______________________________________________<br />nginx-devel mailing list<br />nginx-devel@nginx.org<br />http://mailman.nginx.org/mailman/listinfo/nginx-devel]]></description>
<dc:creator>l.jay Yuan</dc:creator>
<category>Nginx Development</category><pubDate>Tue, 05 Jun 2012 08:14:01 -0400</pubDate></item>
<item>
<guid>http://forum.nginx.org/read.php?29,227181,227195#msg-227195</guid>
<title>Re: when to call ngx_handle_write_event?i am not really understanded.</title><link>http://forum.nginx.org/read.php?29,227181,227195#msg-227195</link><description><![CDATA[2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt; soga, my src\os\win32\ is download from<br />&gt; https://github.com/hehaiqiang/nginx, where is the official source for<br />&gt; win32?<br /><br />Not sure about win32 specific sources, but you can get stock nginx 1.3.1 from<br /><br />svn://svn.nginx.org/nginx/trunk<br /><br />&gt;<br />&gt; 2012/6/5 Vladimir Shebordaev &lt;vshebordaev@mail.ru&gt;:<br />&gt;&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt;&gt; okay, 3Q.<br />&gt;&gt;&gt; another question, in ngx_wsasend.c 's ngx_wsasend function<br />&gt;&gt;&gt;<br />&gt;&gt;&gt; #if 0 // is test code?or really should do it?<br />&gt;&gt;&gt;       if ((size_t) n &lt; size) {<br />&gt;&gt;&gt;           wev-&gt;ready = 0;<br />&gt;&gt;&gt;       }<br />&gt;&gt;&gt; #endif<br />&gt;&gt;&gt;<br />&gt;&gt;<br />&gt;&gt; As of the current release 'ready' flag is reset there. You should<br />&gt;&gt; update nginx sources.<br />&gt;&gt;<br />&gt;&gt; ngx_handle_write_event() belongs to upper layer interface and is<br />&gt;&gt; anyways expected to be called.<br />&gt;&gt;<br />&gt;&gt;&gt; 2012/6/5 Vladimir Shebordaev &lt;vshebordaev@mail.ru&gt;:<br />&gt;&gt;&gt;&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt;&gt;&gt;&gt; sorry, fix: call ngx_handle_write_event?<br />&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt;&gt;&gt;&gt;&gt; if i do not call ngx_handle_write_event  the ngx_connection_t 's<br />&gt;&gt;&gt;&gt;&gt;&gt; ngx_event_t *write will never be handler.<br />&gt;&gt;&gt;&gt;&gt;&gt; it means after c-&gt;send(c, buf, n) then call c-&gt;send(c, buf, n)?<br />&gt;&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt; Yes, you should firstly process the data then update the connection<br />&gt;&gt;&gt;&gt; state for the next event, i.e. call ngx_handle_write_event()<br />&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt;&gt; 2012/6/5 Vladimir Shebordaev &lt;vshebordaev@mail.ru&gt;:<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt; Hi!<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt; ngx_handle_write_event() is the event processiong state machine<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt; interface function that is to proper update event and connection<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt; states after write event is fired and the data has been probably<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt; written to the corresponding descriptor. It can optionally update<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt; send_lowat option on the connection socket.<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt; --<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt; Regards,<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt; Vladimir<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt; when to call ngx_handle_write_event?i am not really understanded.<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt; who can explain me?<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt; _______________________________________________<br />&gt;&gt;&gt;&gt; nginx-devel mailing list<br />&gt;&gt;&gt;&gt; nginx-devel@nginx.org<br />&gt;&gt;&gt;&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br />&gt;&gt;&gt;<br />&gt;&gt;&gt; _______________________________________________<br />&gt;&gt;&gt; nginx-devel mailing list<br />&gt;&gt;&gt; nginx-devel@nginx.org<br />&gt;&gt;&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br />&gt;&gt;&gt;<br />&gt;&gt;<br />&gt;&gt; _______________________________________________<br />&gt;&gt; nginx-devel mailing list<br />&gt;&gt; nginx-devel@nginx.org<br />&gt;&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br />&gt;<br />&gt; _______________________________________________<br />&gt; nginx-devel mailing list<br />&gt; nginx-devel@nginx.org<br />&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br />&gt;<br /><br />_______________________________________________<br />nginx-devel mailing list<br />nginx-devel@nginx.org<br />http://mailman.nginx.org/mailman/listinfo/nginx-devel]]></description>
<dc:creator>Vladimir Shebordaev</dc:creator>
<category>Nginx Development</category><pubDate>Tue, 05 Jun 2012 08:04:01 -0400</pubDate></item>
<item>
<guid>http://forum.nginx.org/read.php?29,227181,227194#msg-227194</guid>
<title>Re: when to call ngx_handle_write_event?i am not really understanded.</title><link>http://forum.nginx.org/read.php?29,227181,227194#msg-227194</link><description><![CDATA[soga, my src\os\win32\ is download from<br />https://github.com/hehaiqiang/nginx, where is the official source for<br />win32?<br /><br />2012/6/5 Vladimir Shebordaev &lt;vshebordaev@mail.ru&gt;:<br />&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt; okay, 3Q.<br />&gt;&gt; another question, in ngx_wsasend.c 's ngx_wsasend function<br />&gt;&gt;<br />&gt;&gt; #if 0 // is test code?or really should do it?<br />&gt;&gt;       if ((size_t) n &lt; size) {<br />&gt;&gt;           wev-&gt;ready = 0;<br />&gt;&gt;       }<br />&gt;&gt; #endif<br />&gt;&gt;<br />&gt;<br />&gt; As of the current release 'ready' flag is reset there. You should<br />&gt; update nginx sources.<br />&gt;<br />&gt; ngx_handle_write_event() belongs to upper layer interface and is<br />&gt; anyways expected to be called.<br />&gt;<br />&gt;&gt; 2012/6/5 Vladimir Shebordaev &lt;vshebordaev@mail.ru&gt;:<br />&gt;&gt;&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt;&gt;&gt; sorry, fix: call ngx_handle_write_event?<br />&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt;&gt;&gt;&gt; if i do not call ngx_handle_write_event  the ngx_connection_t 's<br />&gt;&gt;&gt;&gt;&gt; ngx_event_t *write will never be handler.<br />&gt;&gt;&gt;&gt;&gt; it means after c-&gt;send(c, buf, n) then call c-&gt;send(c, buf, n)?<br />&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;<br />&gt;&gt;&gt; Yes, you should firstly process the data then update the connection<br />&gt;&gt;&gt; state for the next event, i.e. call ngx_handle_write_event()<br />&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt; 2012/6/5 Vladimir Shebordaev &lt;vshebordaev@mail.ru&gt;:<br />&gt;&gt;&gt;&gt;&gt;&gt; Hi!<br />&gt;&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt;&gt; ngx_handle_write_event() is the event processiong state machine<br />&gt;&gt;&gt;&gt;&gt;&gt; interface function that is to proper update event and connection<br />&gt;&gt;&gt;&gt;&gt;&gt; states after write event is fired and the data has been probably<br />&gt;&gt;&gt;&gt;&gt;&gt; written to the corresponding descriptor. It can optionally update<br />&gt;&gt;&gt;&gt;&gt;&gt; send_lowat option on the connection socket.<br />&gt;&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt;&gt; --<br />&gt;&gt;&gt;&gt;&gt;&gt; Regards,<br />&gt;&gt;&gt;&gt;&gt;&gt; Vladimir<br />&gt;&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt;&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt; when to call ngx_handle_write_event?i am not really understanded.<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt; who can explain me?<br />&gt;&gt;&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;<br />&gt;&gt;&gt; _______________________________________________<br />&gt;&gt;&gt; nginx-devel mailing list<br />&gt;&gt;&gt; nginx-devel@nginx.org<br />&gt;&gt;&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br />&gt;&gt;<br />&gt;&gt; _______________________________________________<br />&gt;&gt; nginx-devel mailing list<br />&gt;&gt; nginx-devel@nginx.org<br />&gt;&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br />&gt;&gt;<br />&gt;<br />&gt; _______________________________________________<br />&gt; nginx-devel mailing list<br />&gt; nginx-devel@nginx.org<br />&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br /><br />_______________________________________________<br />nginx-devel mailing list<br />nginx-devel@nginx.org<br />http://mailman.nginx.org/mailman/listinfo/nginx-devel]]></description>
<dc:creator>l.jay Yuan</dc:creator>
<category>Nginx Development</category><pubDate>Tue, 05 Jun 2012 07:56:00 -0400</pubDate></item>
<item>
<guid>http://forum.nginx.org/read.php?29,227181,227192#msg-227192</guid>
<title>Re: when to call ngx_handle_write_event?i am not really understanded.</title><link>http://forum.nginx.org/read.php?29,227181,227192#msg-227192</link><description><![CDATA[2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt; okay, 3Q.<br />&gt; another question, in ngx_wsasend.c 's ngx_wsasend function<br />&gt;<br />&gt; #if 0 // is test code?or really should do it?<br />&gt;       if ((size_t) n &lt; size) {<br />&gt;           wev-&gt;ready = 0;<br />&gt;       }<br />&gt; #endif<br />&gt;<br /><br />As of the current release 'ready' flag is reset there. You should<br />update nginx sources.<br /><br />ngx_handle_write_event() belongs to upper layer interface and is<br />anyways expected to be called.<br /><br />&gt; 2012/6/5 Vladimir Shebordaev &lt;vshebordaev@mail.ru&gt;:<br />&gt;&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt;&gt; sorry, fix: call ngx_handle_write_event?<br />&gt;&gt;&gt;<br />&gt;&gt;&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt;&gt;&gt; if i do not call ngx_handle_write_event  the ngx_connection_t 's<br />&gt;&gt;&gt;&gt; ngx_event_t *write will never be handler.<br />&gt;&gt;&gt;&gt; it means after c-&gt;send(c, buf, n) then call c-&gt;send(c, buf, n)?<br />&gt;&gt;&gt;&gt;<br />&gt;&gt;<br />&gt;&gt; Yes, you should firstly process the data then update the connection<br />&gt;&gt; state for the next event, i.e. call ngx_handle_write_event()<br />&gt;&gt;<br />&gt;&gt;&gt;&gt; 2012/6/5 Vladimir Shebordaev &lt;vshebordaev@mail.ru&gt;:<br />&gt;&gt;&gt;&gt;&gt; Hi!<br />&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt; ngx_handle_write_event() is the event processiong state machine<br />&gt;&gt;&gt;&gt;&gt; interface function that is to proper update event and connection<br />&gt;&gt;&gt;&gt;&gt; states after write event is fired and the data has been probably<br />&gt;&gt;&gt;&gt;&gt; written to the corresponding descriptor. It can optionally update<br />&gt;&gt;&gt;&gt;&gt; send_lowat option on the connection socket.<br />&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt; --<br />&gt;&gt;&gt;&gt;&gt; Regards,<br />&gt;&gt;&gt;&gt;&gt; Vladimir<br />&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt;&gt;&gt;&gt;&gt; when to call ngx_handle_write_event?i am not really understanded.<br />&gt;&gt;&gt;&gt;&gt;&gt; who can explain me?<br />&gt;&gt;&gt;&gt;&gt;&gt;<br />&gt;&gt;<br />&gt;&gt; _______________________________________________<br />&gt;&gt; nginx-devel mailing list<br />&gt;&gt; nginx-devel@nginx.org<br />&gt;&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br />&gt;<br />&gt; _______________________________________________<br />&gt; nginx-devel mailing list<br />&gt; nginx-devel@nginx.org<br />&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br />&gt;<br /><br />_______________________________________________<br />nginx-devel mailing list<br />nginx-devel@nginx.org<br />http://mailman.nginx.org/mailman/listinfo/nginx-devel]]></description>
<dc:creator>Vladimir Shebordaev</dc:creator>
<category>Nginx Development</category><pubDate>Tue, 05 Jun 2012 07:48:00 -0400</pubDate></item>
<item>
<guid>http://forum.nginx.org/read.php?29,227181,227191#msg-227191</guid>
<title>Re: when to call ngx_handle_write_event?i am not really understanded.</title><link>http://forum.nginx.org/read.php?29,227181,227191#msg-227191</link><description><![CDATA[okay, 3Q.<br />another question, in ngx_wsasend.c 's ngx_wsasend function<br /><br />#if 0 // is test code?or really should do it?<br />if ((size_t) n &lt; size) {<br />wev-&gt;ready = 0;<br />}<br />#endif<br /><br />2012/6/5 Vladimir Shebordaev &lt;vshebordaev@mail.ru&gt;:<br />&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt; sorry, fix: call ngx_handle_write_event?<br />&gt;&gt;<br />&gt;&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt;&gt; if i do not call ngx_handle_write_event  the ngx_connection_t 's<br />&gt;&gt;&gt; ngx_event_t *write will never be handler.<br />&gt;&gt;&gt; it means after c-&gt;send(c, buf, n) then call c-&gt;send(c, buf, n)?<br />&gt;&gt;&gt;<br />&gt;<br />&gt; Yes, you should firstly process the data then update the connection<br />&gt; state for the next event, i.e. call ngx_handle_write_event()<br />&gt;<br />&gt;&gt;&gt; 2012/6/5 Vladimir Shebordaev &lt;vshebordaev@mail.ru&gt;:<br />&gt;&gt;&gt;&gt; Hi!<br />&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt; ngx_handle_write_event() is the event processiong state machine<br />&gt;&gt;&gt;&gt; interface function that is to proper update event and connection<br />&gt;&gt;&gt;&gt; states after write event is fired and the data has been probably<br />&gt;&gt;&gt;&gt; written to the corresponding descriptor. It can optionally update<br />&gt;&gt;&gt;&gt; send_lowat option on the connection socket.<br />&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt; --<br />&gt;&gt;&gt;&gt; Regards,<br />&gt;&gt;&gt;&gt; Vladimir<br />&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt;<br />&gt;&gt;&gt;&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt;&gt;&gt;&gt; when to call ngx_handle_write_event?i am not really understanded.<br />&gt;&gt;&gt;&gt;&gt; who can explain me?<br />&gt;&gt;&gt;&gt;&gt;<br />&gt;<br />&gt; _______________________________________________<br />&gt; nginx-devel mailing list<br />&gt; nginx-devel@nginx.org<br />&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br /><br />_______________________________________________<br />nginx-devel mailing list<br />nginx-devel@nginx.org<br />http://mailman.nginx.org/mailman/listinfo/nginx-devel]]></description>
<dc:creator>l.jay Yuan</dc:creator>
<category>Nginx Development</category><pubDate>Tue, 05 Jun 2012 07:30:01 -0400</pubDate></item>
<item>
<guid>http://forum.nginx.org/read.php?29,227181,227189#msg-227189</guid>
<title>Re: when to call ngx_handle_write_event?i am not really understanded.</title><link>http://forum.nginx.org/read.php?29,227181,227189#msg-227189</link><description><![CDATA[2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt; sorry, fix: call ngx_handle_write_event?<br />&gt;<br />&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt; if i do not call ngx_handle_write_event  the ngx_connection_t 's<br />&gt;&gt; ngx_event_t *write will never be handler.<br />&gt;&gt; it means after c-&gt;send(c, buf, n) then call c-&gt;send(c, buf, n)?<br />&gt;&gt;<br /><br />Yes, you should firstly process the data then update the connection<br />state for the next event, i.e. call ngx_handle_write_event()<br /><br />&gt;&gt; 2012/6/5 Vladimir Shebordaev &lt;vshebordaev@mail.ru&gt;:<br />&gt;&gt;&gt; Hi!<br />&gt;&gt;&gt;<br />&gt;&gt;&gt; ngx_handle_write_event() is the event processiong state machine<br />&gt;&gt;&gt; interface function that is to proper update event and connection<br />&gt;&gt;&gt; states after write event is fired and the data has been probably<br />&gt;&gt;&gt; written to the corresponding descriptor. It can optionally update<br />&gt;&gt;&gt; send_lowat option on the connection socket.<br />&gt;&gt;&gt;<br />&gt;&gt;&gt; --<br />&gt;&gt;&gt; Regards,<br />&gt;&gt;&gt; Vladimir<br />&gt;&gt;&gt;<br />&gt;&gt;&gt;<br />&gt;&gt;&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt;&gt;&gt; when to call ngx_handle_write_event?i am not really understanded.<br />&gt;&gt;&gt;&gt; who can explain me?<br />&gt;&gt;&gt;&gt;<br /><br />_______________________________________________<br />nginx-devel mailing list<br />nginx-devel@nginx.org<br />http://mailman.nginx.org/mailman/listinfo/nginx-devel]]></description>
<dc:creator>Vladimir Shebordaev</dc:creator>
<category>Nginx Development</category><pubDate>Tue, 05 Jun 2012 07:26:01 -0400</pubDate></item>
<item>
<guid>http://forum.nginx.org/read.php?29,227181,227188#msg-227188</guid>
<title>Re: when to call ngx_handle_write_event?i am not really understanded.</title><link>http://forum.nginx.org/read.php?29,227181,227188#msg-227188</link><description><![CDATA[sorry, fix: call ngx_handle_write_event?<br /><br />2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt; if i do not call ngx_handle_write_event  the ngx_connection_t 's<br />&gt; ngx_event_t *write will never be handler.<br />&gt; it means after c-&gt;send(c, buf, n) then call c-&gt;send(c, buf, n)?<br />&gt;<br />&gt; 2012/6/5 Vladimir Shebordaev &lt;vshebordaev@mail.ru&gt;:<br />&gt;&gt; Hi!<br />&gt;&gt;<br />&gt;&gt; ngx_handle_write_event() is the event processiong state machine<br />&gt;&gt; interface function that is to proper update event and connection<br />&gt;&gt; states after write event is fired and the data has been probably<br />&gt;&gt; written to the corresponding descriptor. It can optionally update<br />&gt;&gt; send_lowat option on the connection socket.<br />&gt;&gt;<br />&gt;&gt; --<br />&gt;&gt; Regards,<br />&gt;&gt; Vladimir<br />&gt;&gt;<br />&gt;&gt;<br />&gt;&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt;&gt; when to call ngx_handle_write_event?i am not really understanded.<br />&gt;&gt;&gt; who can explain me?<br />&gt;&gt;&gt;<br />&gt;&gt;&gt; _______________________________________________<br />&gt;&gt;&gt; nginx-devel mailing list<br />&gt;&gt;&gt; nginx-devel@nginx.org<br />&gt;&gt;&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br />&gt;&gt;&gt;<br />&gt;&gt;<br />&gt;&gt; _______________________________________________<br />&gt;&gt; nginx-devel mailing list<br />&gt;&gt; nginx-devel@nginx.org<br />&gt;&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br /><br />_______________________________________________<br />nginx-devel mailing list<br />nginx-devel@nginx.org<br />http://mailman.nginx.org/mailman/listinfo/nginx-devel]]></description>
<dc:creator>l.jay Yuan</dc:creator>
<category>Nginx Development</category><pubDate>Tue, 05 Jun 2012 07:18:01 -0400</pubDate></item>
<item>
<guid>http://forum.nginx.org/read.php?29,227181,227187#msg-227187</guid>
<title>Re: when to call ngx_handle_write_event?i am not really understanded.</title><link>http://forum.nginx.org/read.php?29,227181,227187#msg-227187</link><description><![CDATA[if i do not call ngx_handle_write_event the ngx_connection_t 's<br />ngx_event_t *write will never be handler.<br />it means after c-&gt;send(c, buf, n) then call c-&gt;send(c, buf, n)?<br /><br />2012/6/5 Vladimir Shebordaev &lt;vshebordaev@mail.ru&gt;:<br />&gt; Hi!<br />&gt;<br />&gt; ngx_handle_write_event() is the event processiong state machine<br />&gt; interface function that is to proper update event and connection<br />&gt; states after write event is fired and the data has been probably<br />&gt; written to the corresponding descriptor. It can optionally update<br />&gt; send_lowat option on the connection socket.<br />&gt;<br />&gt; --<br />&gt; Regards,<br />&gt; Vladimir<br />&gt;<br />&gt;<br />&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt; when to call ngx_handle_write_event?i am not really understanded.<br />&gt;&gt; who can explain me?<br />&gt;&gt;<br />&gt;&gt; _______________________________________________<br />&gt;&gt; nginx-devel mailing list<br />&gt;&gt; nginx-devel@nginx.org<br />&gt;&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br />&gt;&gt;<br />&gt;<br />&gt; _______________________________________________<br />&gt; nginx-devel mailing list<br />&gt; nginx-devel@nginx.org<br />&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br /><br />_______________________________________________<br />nginx-devel mailing list<br />nginx-devel@nginx.org<br />http://mailman.nginx.org/mailman/listinfo/nginx-devel]]></description>
<dc:creator>l.jay Yuan</dc:creator>
<category>Nginx Development</category><pubDate>Tue, 05 Jun 2012 07:18:01 -0400</pubDate></item>
<item>
<guid>http://forum.nginx.org/read.php?29,227181,227186#msg-227186</guid>
<title>Re: when to call ngx_handle_write_event?i am not really understanded.</title><link>http://forum.nginx.org/read.php?29,227181,227186#msg-227186</link><description><![CDATA[2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;    rc = WSASend(c-&gt;fd, &amp;wsabuf, 1, (DWORD *) &amp;n, 0, ovlp, NULL);<br />&gt;<br /><br />You'd better use platform-independent connection inteface here, i.e<br />ngx_send().<br /><br />ngx_handle_write_event() is also platform-independent and is expected<br />to be invoked right after you've done with the current write event<br />processing in your module and are about to await for the next one.<br /><br />&gt;    err = ngx_socket_errno;<br />&gt;<br />&gt;    if (rc == 0) {<br />&gt;        if (ovlp != NULL) {<br />&gt;            wev-&gt;ovlp.posted_zero_byte = 1;<br />&gt;            wev-&gt;ready = 0;<br />&gt;            return NGX_AGAIN;<br />&gt;        }<br />&gt;<br />&gt; #if 0 // is test code?<br />&gt;        if ((size_t) n &lt; size) {<br />&gt;            wev-&gt;ready = 0;<br />&gt;        }<br />&gt; #endif<br />&gt;<br />&gt; 2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt;&gt; when to call ngx_handle_write_event?i am not really understanded.<br />&gt;&gt; who can explain me?<br />&gt;<br />&gt; _______________________________________________<br />&gt; nginx-devel mailing list<br />&gt; nginx-devel@nginx.org<br />&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br />&gt;<br /><br />_______________________________________________<br />nginx-devel mailing list<br />nginx-devel@nginx.org<br />http://mailman.nginx.org/mailman/listinfo/nginx-devel]]></description>
<dc:creator>Vladimir Shebordaev</dc:creator>
<category>Nginx Development</category><pubDate>Tue, 05 Jun 2012 07:16:01 -0400</pubDate></item>
<item>
<guid>http://forum.nginx.org/read.php?29,227181,227185#msg-227185</guid>
<title>Re: when to call ngx_handle_write_event?i am not really understanded.</title><link>http://forum.nginx.org/read.php?29,227181,227185#msg-227185</link><description><![CDATA[Hi!<br /><br />ngx_handle_write_event() is the event processiong state machine<br />interface function that is to proper update event and connection<br />states after write event is fired and the data has been probably<br />written to the corresponding descriptor. It can optionally update<br />send_lowat option on the connection socket.<br /><br />--<br />Regards,<br />Vladimir<br /><br /><br />2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt; when to call ngx_handle_write_event?i am not really understanded.<br />&gt; who can explain me?<br />&gt;<br />&gt; _______________________________________________<br />&gt; nginx-devel mailing list<br />&gt; nginx-devel@nginx.org<br />&gt; http://mailman.nginx.org/mailman/listinfo/nginx-devel<br />&gt;<br /><br />_______________________________________________<br />nginx-devel mailing list<br />nginx-devel@nginx.org<br />http://mailman.nginx.org/mailman/listinfo/nginx-devel]]></description>
<dc:creator>Vladimir Shebordaev</dc:creator>
<category>Nginx Development</category><pubDate>Tue, 05 Jun 2012 06:50:00 -0400</pubDate></item>
<item>
<guid>http://forum.nginx.org/read.php?29,227181,227183#msg-227183</guid>
<title>Re: when to call ngx_handle_write_event?i am not really understanded.</title><link>http://forum.nginx.org/read.php?29,227181,227183#msg-227183</link><description><![CDATA[rc = WSASend(c-&gt;fd, &amp;wsabuf, 1, (DWORD *) &amp;n, 0, ovlp, NULL);<br /><br />err = ngx_socket_errno;<br /><br />if (rc == 0) {<br />if (ovlp != NULL) {<br />wev-&gt;ovlp.posted_zero_byte = 1;<br />wev-&gt;ready = 0;<br />return NGX_AGAIN;<br />}<br /><br />#if 0 // is test code?<br />if ((size_t) n &lt; size) {<br />wev-&gt;ready = 0;<br />}<br />#endif<br /><br />2012/6/5 l.jay Yuan &lt;pass86@gmail.com&gt;:<br />&gt; when to call ngx_handle_write_event?i am not really understanded.<br />&gt; who can explain me?<br /><br />_______________________________________________<br />nginx-devel mailing list<br />nginx-devel@nginx.org<br />http://mailman.nginx.org/mailman/listinfo/nginx-devel]]></description>
<dc:creator>l.jay Yuan</dc:creator>
<category>Nginx Development</category><pubDate>Tue, 05 Jun 2012 06:30:01 -0400</pubDate></item>
<item>
<guid>http://forum.nginx.org/read.php?29,227181,227181#msg-227181</guid>
<title>when to call ngx_handle_write_event?i am not really understanded.</title><link>http://forum.nginx.org/read.php?29,227181,227181#msg-227181</link><description><![CDATA[when to call ngx_handle_write_event?i am not really understanded.<br />who can explain me?<br /><br />_______________________________________________<br />nginx-devel mailing list<br />nginx-devel@nginx.org<br />http://mailman.nginx.org/mailman/listinfo/nginx-devel]]></description>
<dc:creator>l.jay Yuan</dc:creator>
<category>Nginx Development</category><pubDate>Tue, 05 Jun 2012 06:02:01 -0400</pubDate></item>
</channel>
</rss>