OpenResty® 通过 Lua 扩展 NGINX 实现的可伸缩的 Web 平台

OpenResty XRay

Advanced observability built for OpenResty and more


limited time offer

Request TRIAL today and receive a diagnostic REPORT
Learn more
最新! OpenResty 已发布。
最新! OpenResty 已发布。
最新! 新博客文章 OpenResty XRay 移动端应用介绍 已发表。

ChangeLog 1.7.2

Yichun Zhang , 13 Jul 2014 (created 13 Jul 2014)

Version - 12 July 2014

  • upgraded the Nginx core to 1.7.2.
  • upgraded LuaJIT to v2.1-20140707:
    • imported Mike Pall's latest bug fixes and other changes:
      • feature: compile debug.getmetatable(). Thanks to Karel Tuma.
      • bugfix: Fix ABC elimination (for negative table indexes, for example).
      • bugfix: FFI: Fix compilation of reference field access.
      • bugfix: FFI: fixed frame traversal for backtraces with FFI callbacks.
      • bugfix: x86: lj_math_random_step() clobbers XMM regs on OSX Clang.
      • bugfix: fixed debug info for main chunk of stripped bytecode.
  • upgraded Lua Resty Core Library to 0.0.8.
  • upgraded Lua Resty DNS Library to 0.12.
    • feature: added support for the SRV resource record type (see RFC 2782). thanks Torbjörn Norinder for the patch.
  • upgraded Lua Resty Upstream Healthcheck Library to 0.02.
    • bugfix: for bad status lines, we could throw out the "bad argument #2 to 'sub'" error, reported by George Bashi.
    • doc: avoided using the \r\n sequence in Lua long brackets because Lua would squeeze it to \n, unfortunately. thanks George Bashi for the report.
    • doc: made it clear that multiple upstream {} blocks' checkers can share a single shm zone. thanks Robert Paprocki for asking.
    • doc: now we need to turn off lua_socket_log_errors explicitly in code examples.
  • upgraded Lua Resty Lrucache Library to 0.02.
    • feature: added an alternative implementation using FFI-based hash-table in the form of the new class resty.lrucache.pureffi, which is much faster than the default resty.lrucache class when there are a lot of key variations. thanks Shuxin Yang for the patch.
  • upgraded Lua Nginx Module to 0.9.10.
    • feature: stream-typed cosockets are now full-duplex: a reader "light thread" and a writer "light thread" can operate on the same cosocket simultaneously. thanks shun zhang and aviramc for the original patches.
    • feature: added new API function ngx.thread.kill() for killing a user "light thread". thanks aviramc for the original patch.
    • bugfix: the "coroutine" module table introduced by require('coroutine') was not working in our Lua context. thanks Paul K and Pierre-Yves Gérardy for the report.
    • bugfix: fixed the initial size of the ngx.worker table and the misleading comment due to a copy&paste mistake. thanks Suraj Jaiswal for the report.
    • bugfix: the "coctx cleanup" handler might not be called before being overidden by other operations. this could happen when failing to yield in an error handler (for xpcall).
    • bugfix: fixed an incorrect error message. thanks doujiang for the patch.
    • bugfix: fixed a compilation error regression when using the Microsoft Visual C/C++ compiler. thanks itpp16 for the patch.
    • bugfix: we should use c->buffered & NGX_HTTP_LOWLEVEL_BUFFERED instead of c->buffered for testing if the downstream connection is busy writing.
    • bugfix: we did not handle an out-of-memory case in ngx.req.set_body_data().
    • bugfix: ngx_http_lua_chain_get_free_buf(): avoided returning zero-sized memory bufs.
    • bugfix: body_filter_by_lua*: we might incorrectly pass zero-size bufs (in the form of "special sync bufs") at the beginning of a chain, which could get stuck in the buffer of ngx_http_writer_filter_module (or in other words, being "busy") while could still get recycled in the content handler (like content_by_lua), leading to buffer corruptions. thanks westhood for the report and patch.
    • bugfix: we did not clear all the fields in the ngx_buf_t C struct when recycling chain link buffers.
    • bugfix: the *_by_lua_file directives failed to load .lua files of exactly the size n*LUAL_BUFFERSIZE bytes with the error "'end' expected (to close 'function' at line 1) near ''". thanks kworr for the report.
    • change: now we always iterate through all the user light threads to ensure all threads are de-anchored even when the "uthreads" counter gets out of sync. also added an assertion on the "uthreads" counter.
    • change: now we turn off our C-land assertions by default unless the user explicitly specifies the C compiler option -DNGX_LUA_USE_ASSERT.
    • change: throw out the "no memory" Lua error consistently (instead of "out of memory") when failing to allocate on the nginx side.
    • change: we now still call ngx_pfree() in our own pcre_free hook.
    • doc: documented the NGX_LUA_USE_ASSERT and NGX_LUA_ABORT_AT_PANIC C macros.
    • doc: added performance notes to the sections for the ngx.var and ngx.ctx API.
    • doc: documented the types of Lua values that can be passed to the ngx.timer callback functions.
  • upgraded Form Input Nginx Module to 0.09.
    • bugfix: fixed warnings from the Microsoft Visual C/C++ compiler. thanks itpp16 for the report.
  • upgraded Echo Nginx Module to 0.54.
    • bugfix: the "unknown option for echo_subrequest_async" error was thrown when Nginx variables were used in both the "method" argument and URI argument of the echo_subrequest directive (and etc). thanks Utkarsh Upadhyay for the report.
    • bugfix: fixed a misleading error message.
  • upgraded Srcache Nginx Module to 0.28.
    • feature: log an error message when srcache_store subrequest has an error or returns a bad HTTP status code. thanks Yann Coleu for the report.
    • doc: typo fix from javasboy.
  • upgraded Memc Nginx Module to 0.15.
    • bugfix: we did not log error messages for invalid values of $memc_flags, $memc_exptime, and $memc_value, leading to hard-to-debug HTTP 400 status errors. thanks Yann Coleu for the report.
  • bugfix: ./configure --without-lua_resty_dns did not work as declared. thanks Vitaly for the report.
  • bugfix: use cc as the default C compiler for LuaJIT and Lua C libraries because modern FreeBSD 10 has no gcc by default and its clang is already featureful enough to compile everything. thanks Stefan Parvu for the suggestion.
  • change: ./configure --with-debug now also passes the extra C compiler options -DNGX_LUA_USE_ASSERT -DNGX_LUA_ABORT_AT_PANIC to the Lua Nginx Module build. See ChangeLog 1.7.0 for change log for OpenResty 1.7.0.x.