Kong v0.9.0 RC3发布
jopen 8年前
<p style="text-align: center;"><img alt="" src="https://simg.open-open.com/show/22cdaab266499458882a505cb199be22.png" /></p> <p>Kong是在客户端和(微)服务间转发API通信的API网关,通过插件扩展功能。Kong有两个主要组件:</p> <ul> <li>Kong Server :基于nginx的服务器,用来接收API请求。</li> <li>Apache Cassandra :用来存储操作数据。</li> </ul> <p>你可以通过增加更多Kong Server机器对Kong服务进行水平扩展,通过前置的负载均衡器向这些机器分发请求。根据文档描述,两个Cassandra节点就足以支撑绝大多数情况,但如果网络非常拥挤,可以考虑适当增加更多节点。</p> <p>对于开源社区来说,Kong 中最诱人的一个特性是可以通过插件扩展已有功能,这些插件在 API 请求响应循环的生命周期中被执行。插件使用 Lua 编写,而且 Kong 还有如下几个基础功能:</p> <ul> <li> HTTP 基本认证</li> <li> 密钥认证</li> <li> CORS( Cross-origin Resource Sharing,跨域资源共享)</li> <li> TCP/UDP</li> <li> 文件日志</li> <li> API 请求限流</li> <li> 请求转发</li> <li> nginx 监控</li> </ul> <p style="text-align: center;"><img alt="" src="https://simg.open-open.com/show/8cc1737a2b0ff1e31dcec627751ec625.png" /></p> <h2>更新日志</h2> <p>这个版本的主要焦点是Kong的新的CLI。与一个简单的配置文件,新设置环境变量支持,新命令,以及一个新的翻译,新的CLI给Kong用户提供了更多的强大功能和灵活性,允许更容易集成在您的部署工作流,以及更好的测试开发人员和插件作者。此外,包括一些新的插件和性能改进以及一些bug修复。</p> <h3>改变</h3> <ul> <li>New CLI, with new commands and refined arguments. This new CLI uses the <code>resty-cli</code>interpreter (see <a href="/misc/goto?guid=4958992678298818615">lua-resty-cli</a>) instead of LuaJIT. As a result, the <code>resty</code> executable must be available in your <code>$PATH</code> (resty-cli is shipped in the OpenResty bundle) as well as the <code>bin/kong</code> executable. Kong does not rely on Luarocks installing the <code>bin/kong</code> executable anymore. This change of behavior is taken care of if you are using one of the official Kong packages.</li> <li>Kong uses a new configuration file, with an easier syntax than the previous YAML file.</li> <li>New arguments for the CLI, such as verbose, debug and tracing flags. We also avoid requiring the configuration file as an argument to each command as per the previous CLI.</li> <li>Customization of the Nginx configuration can now be taken care of using two different approaches: with a custom Nginx configuration template and using <code>kong start --template <file></code>, or by using<code>kong compile</code> to generate the Kong Nginx sub-configuration, and <code>include</code> it in a custom Nginx instance.</li> <li>Plugins: <ul> <li>Rate Limiting: the <code>continue_on_error</code> property is now called <code>cluster_fault_tolerant</code>.</li> <li>Response Rate Limiting: the <code>continue_on_error</code> property is now called<code>cluster_fault_tolerant</code>.</li> </ul> </li> </ul> <h3>新增</h3> <ul> <li> Support for overriding configuration settings with environment variables.</li> <li> Support for SSL connections between Kong and PostgreSQL. <a href="/misc/goto?guid=4958992678394107564">#1425</a></li> <li> Ability to apply plugins with more granularity: per-consumer, and global plugins are now possible. <a href="/misc/goto?guid=4958992678468230941">#1403</a></li> <li>New <code>kong check</code> command: validates a Kong configuration file.</li> <li>Better version check for third-party dependencies (OpenResty, Serf, dnsmasq). <a href="/misc/goto?guid=4958992678545480741">#1307</a></li> <li>Ability to configure the validation depth of database SSL certificates from the configuration file.<a href="/misc/goto?guid=4958992678626749591">#1420</a></li> <li><code>request_host</code>: internationalized url support; utf-8 domain names through punycode support and paths through %-encoding. <a href="/misc/goto?guid=4958992678704326775">#1300</a></li> <li>Implements caching locks when fetching database configuration (APIs, Plugins...) to avoid dog pile effect on cold nodes. <a href="/misc/goto?guid=4958992678786888164">#1402</a></li> <li>Internal locks when for datastore requests. Now Kong will only trigger maximum one request per node to the datastore when requesting a specific entity, which prevents the Dogpile effect. <a href="/misc/goto?guid=4958992678786888164">#1402</a></li> <li>Plugins: <ul> <li> <strong>New bot-detection plugin</strong>: protect your APIs by detecting and rejecting common bots and crawlers. <a href="/misc/goto?guid=4958992678859821612">#1413</a></li> <li>correlation-id: new "tracker" generator, identifying requests per worker and connection. <a href="/misc/goto?guid=4958992678933589912">#1288</a></li> <li>request/response-transformer: ability to add strings including colon characters. <a href="/misc/goto?guid=4958992679016927064">#1353</a></li> <li>rate-limiting: support for new rate-limiting policies (<code>cluster</code>, <code>local</code> and <code>redis</code>), and for a new<code>limit_by</code> property to force rate-limiting by <code>consumer</code>, <code>credential</code> or <code>ip</code>.</li> <li>response-rate-limiting: support for new rate-limiting policies (<code>cluster</code>, <code>local</code> and <code>redis</code>), and for a new <code>limit_by</code> property to force rate-limiting by <code>consumer</code>, <code>credential</code> or <code>ip</code>.</li> <li>galileo: performance improvements of ALF serialization. ALFs are not discarded when exceeding 20MBs anymore. <a href="/misc/goto?guid=4958993175303664870">#1463</a></li> <li>statsd: new <code>upstream_stream</code> latency metric. <a href="/misc/goto?guid=4958993175444358851">#1466</a></li> <li>datadog: new <code>upstream_stream</code> latency metric and tagging support for each metric. <a href="/misc/goto?guid=4958993175542725402">#1473</a></li> </ul> </li> </ul> <h3>移除</h3> <ul> <li>We now use <a href="/misc/goto?guid=4958993175649147254">lua-resty-jit-uuid</a> for UUID generation, which is a pure Lua implementation of <a href="/misc/goto?guid=4958993175748001980">RFC 4122</a>. As a result, libuuid is not a dependency of Kong anymore.</li> </ul> <h3>Bug修复</h3> <ul> <li>Sensitive configuration settings are not printed to stdout anymore. <a href="/misc/goto?guid=4958992679093158331">#1256</a></li> <li>Fixed bug that caused nodes to remove themselves from the database when they attempted to join the cluster. <a href="/misc/goto?guid=4958992679177273312">#1437</a></li> <li>Plugins: <ul> <li>request-size-limiting: use proper constant for MB units while setting the size limit. <a href="/misc/goto?guid=4958992679257803239">#1416</a></li> <li>OAuth2: security and config validation fixes. <a href="/misc/goto?guid=4958992679328427250">#1409</a> <a href="/misc/goto?guid=4958990866855162045">#1112</a></li> <li>request/response-transformer: better validation of fields provided without a value. <a href="/misc/goto?guid=4958992679437864583">#1399</a></li> <li>JWT: handle some edge-cases that could result in HTTP 500 errors. <a href="/misc/goto?guid=4958992679514401887">#1362</a></li> </ul> </li> </ul> <blockquote> <p><strong>internal</strong></p> <ul> <li>new test suite using resty-cli and removing the need to monkey-patch the <code>ngx</code> global.</li> <li>custom assertions and new helper methods (<code>wait_until()</code>) to gracefully fail in case of timeout.</li> <li>increase atomicity of the testing environment.</li> <li>lighter testing instance, only running 1 worker and not using dnsmasq by default.</li> </ul> </blockquote> <h2>下载</h2> <ul> <li><a href="/misc/goto?guid=4958993176101335567" rel="nofollow">16.7 MB<strong>kong-0.9.0rc3.aws.rpm</strong></a></li> <li><a href="/misc/goto?guid=4958993176201099891" rel="nofollow">16.2 MB<strong>kong-0.9.0rc3.el6.noarch.rpm</strong></a></li> <li><a href="/misc/goto?guid=4958993176303258570" rel="nofollow">16.7 MB<strong>kong-0.9.0rc3.el7.noarch.rpm</strong></a></li> <li><a href="/misc/goto?guid=4958993176411752983" rel="nofollow">16.7 MB<strong>kong-0.9.0rc3.jessie_all.deb</strong></a></li> <li><a href="/misc/goto?guid=4958993176516601475" rel="nofollow">12.4 MB<strong>kong-0.9.0rc3.osx.pkg</strong></a></li> <li><a href="/misc/goto?guid=4958993176617198149" rel="nofollow">16.4 MB<strong>kong-0.9.0rc3.precise_all.deb</strong></a></li> <li><a href="/misc/goto?guid=4958993176714738684" rel="nofollow">16.9 MB<strong>kong-0.9.0rc3.trusty_all.deb</strong></a></li> <li><a href="/misc/goto?guid=4958993176826673317" rel="nofollow">16.8 MB<strong>kong-0.9.0rc3.vivid_all.deb</strong></a></li> <li><a href="/misc/goto?guid=4958993176924833980" rel="nofollow">17.1 MB<strong>kong-0.9.0rc3.wheezy_all.deb</strong></a></li> <li><a href="/misc/goto?guid=4958993177023742975" rel="nofollow">17 MB<strong>kong-0.9.0rc3.xenial_all.deb</strong></a></li> <li><a href="/misc/goto?guid=4958993177125002978" rel="nofollow"><strong>Source code</strong> (zip)</a></li> <li><a href="/misc/goto?guid=4958993177229469249" rel="nofollow"><strong>Source code</strong> (tar.gz)</a></li> </ul> <p> </p> <p>本站原创,转载时保留以下信息:<br /> 本文转自:深度开源(open-open.com)<br /> 原文地址:<a href="http://www.open-open.com/news/view/65914321">http://www.open-open.com/news/view/65914321</a></p> <p><img src="file:///C:/Users/wqm/AppData/Local/Temp/enhtmlclip/Image(5).png" /> </p> <p> </p>