facil.io v0.5.3 Release Notes

  • ๐Ÿ”„ Change: minor changes to the versioning scheme removed some version MACROS... this isn't API related, so I don't consider it a breaking change, but it might effect code that relied too much on internal workings. The only valid version macros are the FACIL_VERSION_* macros, in the facil.h header.

    ๐Ÿ”„ Change: (http) the HTTP/1.x parser was re-written and replaced. It should perform the same, while being easier to maintain. Also, the new parser could potentially be used to author an HTTP client.

    ๐Ÿ”„ Change: (websocket) the Websocket parser was re-written and replaced, decoupling the parser and message wrapper from the IO layer. Performance might slightly improve, but should mostly remain the same. The new code is easier to maintain and easier to port to other implementations. Also, the new parser supports a client mode (message masking).

    ๐Ÿ›  Fix: (websocket) fix #16, where a client's first message could have been lost due to long on_open processing times. This was fixed by fragmenting the upgrade event into two events, adding the facil_attach_locked feature and attaching the new protocol before sending the response. Credit to @madsheep and @nilclass for exposing the issue and tracking it down to the on_open callbacks.

    ๐Ÿ›  Fix: (sock) sockets created using the TCP/IP sock library now use TCP_NODELAY as the new default. This shouldn't be considered a breaking change as much as it should be considered a fix.

    ๐Ÿ›  Fix: (http1) HTTP/1.x is now more fragmented, avoiding a read loop to allow for mid-stream / mid-processing protocol upgrades. This also fixes #16 at it's root (besides the improved websocket callback handling).

    ๐Ÿ›  Fix: (http1) HTTP/1.x now correctly initializes the udata pointer to NULL fore each new request.

    ๐Ÿ›  Fix: (facil) the facil_run_every function now correctly calls the on_finish callback when a timer initialization fails. This fixes a leak that could have occurred due to inconsistent API expectations. Workarounds written due to this issue should be removed.

    ๐Ÿ›  Fix: (facil) connection timeout is now correctly ignored for timers.

    ๐Ÿ›  Fix: (defer) a shutdown issue in defer_perform_in_fork was detected by @cdkrot and his fix was implemented.

    ๐Ÿ›  Fix: (evio) fixed an issue where the evented IO library failed to reset the state indicator after evio_close was called, causing some functions to believe that events are still processed. Now the evio_isactive will correctly indicate that the evented IO is inactive after evio_close was called.

    ๐Ÿ›  Fix: (evio) fixes an issue where evio_add_timer would fail with EEXIST instead of reporting success (this might be related to timer consolidation concerns in the Linux kernel).

    ๐Ÿ›  Fix: (evio) better timer fd creation compatibility with different Linux kernels.

    ๐Ÿ›  Fix: (documentation) credit to @cdkrot for reporting an outdated demo in the README.

    ๐Ÿ›  Fix: (linking) added the missing -lm linker flag for gcc/Linux (I was using clang, which automatically links to the math library, so I didn't notice this).

    Portability: added extern "C" directive for untested C++ support.

    ๐Ÿ”‹ Feature: ๐ŸŽ‰ added a CLI helper service, allowing easy parsing and publishing of possible command line arguments.

    ๐Ÿ”‹ Feature: ๐ŸŽ‰๐ŸŽ‰ added a dynamic type library to facil.io's core, making some common web related tasks easier to manage.

    ๐Ÿ”‹ Feature: ๐ŸŽ‰๐ŸŽ‰๐ŸŽ‰ added native JSON support. JSON strings can be converted to fiobj_s * objects and fiobj_s * objects can be rendered as JSON! I'm hoping to get it benchmarked publicly.