]> granicus.if.org Git - libevent/commitdiff
Bump whatsnew-2.1 document
authorAzat Khuzhin <a3at.mail@gmail.com>
Sun, 22 Jan 2017 13:58:12 +0000 (16:58 +0300)
committerAzat Khuzhin <a3at.mail@gmail.com>
Wed, 25 Jan 2017 23:36:00 +0000 (02:36 +0300)
whatsnew-2.1.txt

index 0be54ae11b50d3d3af99f6d7090bf167949adfe9..c1f4df8f7878052812f457a9492310302e691ac5 100644 (file)
 
 1.3. Event finalization
 
-  [NOTE: This is an experimental feature in Libevent 2.1.3-alpha. Though
-  it seems solid so far, its API might change between now and the first
-  release candidate for Libevent 2.1.]
-
 1.3.1. Why event finalization?
 
   Libevent 2.1 now supports an API for safely "finalizing" events that
   evbuffer_readln() now supports an EVBUFFER_EOL_NUL argument to fetch
   NUL-terminated strings from buffers.
 
+  There's a new evbuffer_set_flags()/evbuffer_clear_flags() that you can use to
+  set EVBUFFER_FLAG_DRAINS_TO_FD.
+
 1.6. New functions and features: bufferevents
 
   You can now use the bufferevent_getcb() function to find out a
   You can manually trigger a bufferevent's callbacks via
   bufferevent_trigger() and bufferevent_trigger_event().
 
+  Also you can manually increment/decrement reference for bufferevent with
+  bufferevent_incref()/bufferevent_decref(), it is useful in situations where a
+  user may reference the bufferevent somewhere else.
+
+  Now bufferevent_openssl supports "dirty" shutdown (when the peer closes the
+  TCP connection before closing the SSL channel), see
+  bufferevent_openssl_get_allow_dirty_shutdown() and
+  bufferevent_openssl_set_allow_dirty_shutdown().
+
+  And also libevent supports openssl 1.1.
+
 1.7. New functions and features: evdns
 
   The previous evdns interface used an "open a test UDP socket" trick in
   There is a new evdns_base_clear_host_addresses() function to remove
   all the /etc/hosts addresses registered with an evdns instance.
 
+  Also there is evdns_base_get_nameserver_addr() for retrieve the address of
+  the 'idx'th configured nameserver.
+
 1.8. New functions and features: evconnlistener
 
   Libevent 2.1 adds the following evconnlistener flags:
     HTTP where the client always speaks first.  On operating systems
     that don't support this functionality, this option has no effect.
 
+    LEV_OPT_REUSEABLE_PORT -- Indicates that we ask to allow multiple servers
+    to bind to the same port if they each set the option Ionly on Linux and
+    >=3.9)
+
     LEV_OPT_DISABLED -- Creates an evconnlistener in the disabled (not
     listening) state.
 
   evhttp_connection_set_timeout_tv() to configure
   microsecond-granularity timeouts.
 
+  Also there is evhttp_connection_set_initial_retry_tv() to change initial
+  retry timeout.
+
   There are a new pair of functions: evhttp_set_bevcb() and
   evhttp_connection_base_bufferevent_new(), that you can use to
   configure which bufferevents will be used for incoming and outgoing
   The evhttp_request_set_on_complete_cb() facility adds a callback to be
   invoked on request completion.
 
+  You can add linger-close for http server by passing
+  EVHTTP_SERVER_LINGERING_CLOSE to evhttp_set_flags(), with this flag server
+  read all the clients body, and only after this respond with an error if the
+  clients body exceed max_body_size (since some clients cannot read response
+  otherwise).
+
+  The evhttp_connection_set_family() can bypass family hint to evdns.
+
+  There are some flags available for connections, which can be installed with
+  evhttp_connection_set_flags():
+  - EVHTTP_CON_REUSE_CONNECTED_ADDR -- reuse connection address on retry (avoid
+    extra DNS request).
+  - EVHTTP_CON_READ_ON_WRITE_ERROR - try read error, since server may already
+    close the connection.
+
+  The evhttp_connection_free_on_completion() can be used to tell libevent to
+  free the connection object after the last request has completed or failed.
+
+  There is evhttp_request_get_response_code_line() if
+  evhttp_request_get_response_code() is not enough for you.
+
+  There are *evhttp_uri_parse_with_flags() that accepts
+  EVHTTP_URI_NONCONFORMANT to tolerate URIs that do not conform to RFC3986.
+  The evhttp_uri_set_flags() can changes the flags on URI.
+
 1.10. New functions and features: evutil
 
   There's a function "evutil_secure_rng_set_urandom_device_file()" that
   you can use to override the default file that Libevent uses to seed
   its (sort-of) secure RNG.
 
+  The evutil_date_rfc1123() returns date in RFC1123
+
+  There are new API to work with monotonic timer -- monotonic time is
+  guaranteed never to run in reverse, but is not necessarily epoch-based. Use
+  it to make reliable measurements of elapsed time between events even when the
+  system time may be changed:
+  - evutil_monotonic_timer_new()/evutil_monotonic_timer_free()
+  - evutil_configure_monotonic_time()
+  - evutil_gettime_monotonic()
+
+  Use evutil_make_listen_socket_reuseable_port() to set SO_REUSEPORT (linux >=
+  3.9)
+
+  The evutil_make_tcp_listen_socket_deferred() can make a tcp listener socket
+  defer accept()s until there is data to read (TCP_DEFER_ACCEPT).
+
 2. Cross-platform performance improvements
 
 2.1. Better data structures
 5. Testing
 
   Libevent's test coverage level is more or less unchanged since before:
-  we still have over 80% line coverage in our tests on Linux and OSX.
+  we still have over 80% line coverage in our tests on Linux, FreeBSD, NetBSD,
+  Windows, OSX.
   There are some under-tested modules, though: we need to fix those.
+
+  And now we have CI:
+  - https://travis-ci.org/libevent/libevent
+  - https://ci.appveyor.com/project/nmathewson/libevent
+
+  And code coverage:
+  - https://coveralls.io/github/libevent/libevent
+
+  Plus there is vagrant boxes if you what to test it on more OS'es then
+  travis-ci allows, and there is a wrapper (in python) that will parse logs and
+  provide report:
+  - https://github.com/libevent/libevent-extras/blob/master/tools/vagrant-tests.py
+
+6. Contributing
+
+  From now we have contributing guide and checkpatch.sh.