<feed xmlns='http://www.w3.org/2005/Atom'>
<title>nginx.git/src/event/modules/ngx_win32_select_module.c, branch release-1.28.3</title>
<subtitle>nginx</subtitle>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/'/>
<entry>
<title>Events: available bytes calculation via ioctl(FIONREAD).</title>
<updated>2019-10-17T13:02:19+00:00</updated>
<author>
<name>Maxim Dounin</name>
<email>mdounin@mdounin.ru</email>
</author>
<published>2019-10-17T13:02:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=fac4c7bdf53ee7d8fec6568f1e9fecefcde6feba'/>
<id>fac4c7bdf53ee7d8fec6568f1e9fecefcde6feba</id>
<content type='text'>
This makes it possible to avoid looping for a long time while working
with a fast enough peer when data are added to the socket buffer faster
than we are able to read and process them (ticket #1431).  This is
basically what we already do on FreeBSD with kqueue, where information
about the number of bytes in the socket buffer is returned by
the kevent() call.

With other event methods rev-&gt;available is now set to -1 when the socket
is ready for reading.  Later in ngx_recv() and ngx_recv_chain(), if
full buffer is received, real number of bytes in the socket buffer is
retrieved using ioctl(FIONREAD).  Reading more than this number of bytes
ensures that even with edge-triggered event methods the event will be
triggered again, so it is safe to stop processing of the socket and
switch to other connections.

Using ioctl(FIONREAD) only after reading a full buffer is an optimization.
With this approach we only call ioctl(FIONREAD) when there are at least
two recv()/readv() calls.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This makes it possible to avoid looping for a long time while working
with a fast enough peer when data are added to the socket buffer faster
than we are able to read and process them (ticket #1431).  This is
basically what we already do on FreeBSD with kqueue, where information
about the number of bytes in the socket buffer is returned by
the kevent() call.

With other event methods rev-&gt;available is now set to -1 when the socket
is ready for reading.  Later in ngx_recv() and ngx_recv_chain(), if
full buffer is received, real number of bytes in the socket buffer is
retrieved using ioctl(FIONREAD).  Reading more than this number of bytes
ensures that even with edge-triggered event methods the event will be
triggered again, so it is safe to stop processing of the socket and
switch to other connections.

Using ioctl(FIONREAD) only after reading a full buffer is an optimization.
With this approach we only call ioctl(FIONREAD) when there are at least
two recv()/readv() calls.
</pre>
</div>
</content>
</entry>
<entry>
<title>Win32: detection of connect() errors in select().</title>
<updated>2019-01-24T19:00:44+00:00</updated>
<author>
<name>Maxim Dounin</name>
<email>mdounin@mdounin.ru</email>
</author>
<published>2019-01-24T19:00:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=38196b8ba63f04830db0b8793eca738e162c6d8e'/>
<id>38196b8ba63f04830db0b8793eca738e162c6d8e</id>
<content type='text'>
On Windows, connect() errors are only reported via exceptfds descriptor set
from select().  Previously exceptfds was set to NULL, and connect() errors
were not detected at all, so connects to closed ports were waiting till
a timeout occurred.

Since ongoing connect() means that there will be a write event active,
except descriptor set is copied from the write one.  While it is possible
to construct except descriptor set as a concatenation of both read and write
descriptor sets, this looks unneeded.

With this change, connect() errors are properly detected now when using
select().  Note well that it is not possible to detect connect() errors with
WSAPoll() (see https://daniel.haxx.se/blog/2012/10/10/wsapoll-is-broken/).
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
On Windows, connect() errors are only reported via exceptfds descriptor set
from select().  Previously exceptfds was set to NULL, and connect() errors
were not detected at all, so connects to closed ports were waiting till
a timeout occurred.

Since ongoing connect() means that there will be a write event active,
except descriptor set is copied from the write one.  While it is possible
to construct except descriptor set as a concatenation of both read and write
descriptor sets, this looks unneeded.

With this change, connect() errors are properly detected now when using
select().  Note well that it is not possible to detect connect() errors with
WSAPoll() (see https://daniel.haxx.se/blog/2012/10/10/wsapoll-is-broken/).
</pre>
</div>
</content>
</entry>
<entry>
<title>Added missing static specifiers.</title>
<updated>2017-03-02T13:46:00+00:00</updated>
<author>
<name>Eran Kornblau</name>
<email>erankor@gmail.com</email>
</author>
<published>2017-03-02T13:46:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=0759f088a532ec48170ca03d694cc103757a0f4c'/>
<id>0759f088a532ec48170ca03d694cc103757a0f4c</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Removed unix ngx_threaded and related ngx_process_changes.</title>
<updated>2015-03-20T03:43:19+00:00</updated>
<author>
<name>Ruslan Ermilov</name>
<email>ru@nginx.com</email>
</author>
<published>2015-03-20T03:43:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=b6029a8a3fbe8577386a2a5e67c86700900afaf6'/>
<id>b6029a8a3fbe8577386a2a5e67c86700900afaf6</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Thread pools implementation.</title>
<updated>2015-03-14T14:37:07+00:00</updated>
<author>
<name>Valentin Bartenev</name>
<email>vbart@nginx.com</email>
</author>
<published>2015-03-14T14:37:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=305fc021db799c87d751f0f1f5e99afee7bb2b3b'/>
<id>305fc021db799c87d751f0f1f5e99afee7bb2b3b</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Events: processing of posted events changed from LIFO to FIFO.</title>
<updated>2014-09-01T14:20:18+00:00</updated>
<author>
<name>Valentin Bartenev</name>
<email>vbart@nginx.com</email>
</author>
<published>2014-09-01T14:20:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=37d24e7e3be648a6f73bad18dcf53798a7a1aeb0'/>
<id>37d24e7e3be648a6f73bad18dcf53798a7a1aeb0</id>
<content type='text'>
In theory, this can provide a bit better distribution of latencies.

Also it simplifies the code, since ngx_queue_t is now used instead
of custom implementation.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In theory, this can provide a bit better distribution of latencies.

Also it simplifies the code, since ngx_queue_t is now used instead
of custom implementation.
</pre>
</div>
</content>
</entry>
<entry>
<title>Events: removed broken thread support from posted events.</title>
<updated>2014-09-01T14:20:03+00:00</updated>
<author>
<name>Valentin Bartenev</name>
<email>vbart@nginx.com</email>
</author>
<published>2014-09-01T14:20:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=2a81e0556611188a1b9b3e1240a06928dcebc1a2'/>
<id>2a81e0556611188a1b9b3e1240a06928dcebc1a2</id>
<content type='text'>
It's mostly dead code.  And the idea of thread support for this task has
been deprecated.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It's mostly dead code.  And the idea of thread support for this task has
been deprecated.
</pre>
</div>
</content>
</entry>
<entry>
<title>Win32: MinGW GCC compatibility.</title>
<updated>2013-09-04T16:48:28+00:00</updated>
<author>
<name>Maxim Dounin</name>
<email>mdounin@mdounin.ru</email>
</author>
<published>2013-09-04T16:48:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=48d96ced6ff6cea533d56d0d09129f6632a19e4d'/>
<id>48d96ced6ff6cea533d56d0d09129f6632a19e4d</id>
<content type='text'>
Several warnings silenced, notably (ngx_socket_t) -1 is now checked
on socket operations instead of -1, as ngx_socket_t is unsigned on win32
and gcc complains on comparison.

With this patch, it's now possible to compile nginx using mingw gcc,
with options we normally compile on win32.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Several warnings silenced, notably (ngx_socket_t) -1 is now checked
on socket operations instead of -1, as ngx_socket_t is unsigned on win32
and gcc complains on comparison.

With this patch, it's now possible to compile nginx using mingw gcc,
with options we normally compile on win32.
</pre>
</div>
</content>
</entry>
<entry>
<title>Copyright updated.</title>
<updated>2012-01-18T15:07:43+00:00</updated>
<author>
<name>Maxim Konovalov</name>
<email>maxim@nginx.com</email>
</author>
<published>2012-01-18T15:07:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=f8d59e33f34185c28d1d3c6625a897e214b7ca73'/>
<id>f8d59e33f34185c28d1d3c6625a897e214b7ca73</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>*) introduce ngx_time_sigsafe_update() to update the error log time only</title>
<updated>2010-03-25T09:10:10+00:00</updated>
<author>
<name>Igor Sysoev</name>
<email>igor@sysoev.ru</email>
</author>
<published>2010-03-25T09:10:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=6d45d8a50da07591ed0de584bba1e526cc9b9406'/>
<id>6d45d8a50da07591ed0de584bba1e526cc9b9406</id>
<content type='text'>
*) change ngx_time_update() interface
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
*) change ngx_time_update() interface
</pre>
</div>
</content>
</entry>
</feed>
