开源中国-最新资讯 ( ) • 2021-12-02 13:00

导语

Apache APISIX 从开源第一天就以社区方式成长,迅速成为全世界最活跃的开源 API 网关项目。这些成就,离不开社区小伙伴们的共同奋斗。

“独行者速,众行者远”。Apache APISIX 社区周报希望可以帮助社区小伙伴们更好地掌握 Apache APISIX 社区的进展,方便大家参与到 Apache APISIX 社区中来。

我们还整理了一些适合新来社区的小伙伴们参加的 Issue !感兴趣的同学们,走过路过不要错过!

贡献者统计

Good First Issue

Issue #5451

链接:

https://github.com/apache/apisix/issues/5451

问题描述:

Nginx 自带的响应内容替换库可以替换局部内容,如下:(http://nginx.org/en/docs/http/ngx\\_http\\_sub\\_module.html)

sub_filter '

有个支持正则替换的库(印象中 Openresty 已默认支持):ngx_http_substitutions_filter_module,可以通过正则表达式来替换内容:

 
subs_filter_types text/html text/css text/xml;subs_filter st(\d*).example.com $1.example.com ir;subs_filter a.example.com s.example.com;subs_filter http://$host https://$host;

但是 APISIX 的 response-rewrite 插件文档,好像只能支持完整替换,相当于直接将所有响应都换成插件设置的返回,并不支持部分内容替换: ​​​​

  •  
  •  
  •  
curl http://127.0.0.1:9080/apisix/admin/routes/1  -H 'X-API-KEY: edd1c9f034335f136f87ad84b625c8f1' -X PUT -d '{    "methods": ["GET"],    "uri": "/test/index.html",    "plugins": {        "response-rewrite": {            "body": "{\"code\":\"ok\",\"message\":\"new json body\"}",            "headers": {                "X-Server-id": 3,                "X-Server-status": "on",                "X-Server-balancer_addr": "$balancer_ip:$balancer_port"            },            "vars":[                [ "status","==","200" ]            ]        }    },    "upstream": {        "type": "roundrobin",        "nodes": {            "127.0.0.1:80": 1        }    }}'

这个插件是否支持部分替换或正则替换?如果不支持,APISIX 有没有其他解决方案呢?

Issue #5647

链接:

https://github.com/apache/apisix/issues/5647

问题描述: 当前文档提供了在 CentOS7 上直接使用 RPM 安装 APISIX 的方法,但是当前 APISIX 已经将依赖切换为 apisix-base 版本,没有提供 RPM 安装方法,会导致安装失败。

是否可以添加用于安装 apisix-base 的 RPM 的命令。

近期功能特性亮点

kafka-logger 支持记录请求体

相关 PR:

https://github.com/apache/apisix/pull/5501

贡献者:windyrjc

新增 azure-functions 插件

与 Azure Serverless Function 无缝集成

相关 PR:

https://github.com/apache/apisix/pull/5479

贡献者:bisakhmondal

wasm 插件支持在 header_filter 阶段运行

相关 PR:

https://github.com/apache/apisix/pull/5544

贡献者:spacewander

新增 google-cloud-logging 插件

用于推送日志到

Google Cloud logging Service

相关 PR:

https://github.com/apache/apisix/pull/5538

贡献者:shuaijinchao

新增 openwhisk 插件

与 Apache OpenWhisk serverless

平台集成

相关 PR:

https://github.com/apache/apisix/pull/5518

贡献者:bzp2010

kafka-logger 和 http 支持记录响应体

相关 PR:

https://github.com/apache/apisix/pull/5550

贡献者:dmsolr

在 APISIX Ingress 中对于 HTTPS 和 gRPCs 类型的 upstream 丰富了 mTLS 的支持

相关 PR:

https://github.com/apache/apisix-ingress-controller/pull/755

贡献者:nic-6443

Apache APISIX 的项目官网和 Github 上的 Issue 上已经积累了比较丰富的文档教程和使用经验,如果您遇到问题可以翻阅文档,用关键词在 Issue 中搜索,也可以参与 Issue 上的讨论,提出自己的想法和实践经验。

关于 Apache APISIX

Apache APISIX 是一个动态、实时、高性能的开源 API 网关,提供负载均衡、动态上游、灰度发布、服务熔断、身份认证、可观测性等丰富的流量管理功能。Apache APISIX 可以帮助企业快速、安全地处理 API 和微服务流量,包括网关、Kubernetes Ingress 和服务网格等。