[GitHub] [apisix] jianmaikj opened a new issue #5648: limit-count plugin does not work in redis mode?

2021-11-29 Thread GitBox


jianmaikj opened a new issue #5648:
URL: https://github.com/apache/apisix/issues/5648


   ### Issue description
   
   When the policy is redis, this error occurs: `limit-count.lua:187: 
phase_func(): failed to limit count: connection refused`,
   Tested that redis is normally connectable
   
   ### Environment
   
   - apisix version (cmd: `apisix version`):2.10
   - OS (cmd: `uname -a`):Centos 7.6
   - OpenResty / Nginx version (cmd: `nginx -V` or `openresty -V`):
   - etcd version, if have (cmd: run `curl 
http://127.0.0.1:9090/v1/server_info` to get the info from server-info API):
   - apisix-dashboard version, if have:
   - the plugin runner version, if the issue is about a plugin runner (cmd: 
depended on the kind of runner):
   - luarocks version, if the issue is about installation (cmd: `luarocks 
--version`):
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] dongyudan commented on issue #5633: bug: enable skywalking plugin , the route rewrite is not affected

2021-11-29 Thread GitBox


dongyudan commented on issue #5633:
URL: https://github.com/apache/apisix/issues/5633#issuecomment-982367182


   >The upstream available
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] dongyudan commented on issue #5633: bug: enable skywalking plugin , the route rewrite is not affected

2021-11-29 Thread GitBox


dongyudan commented on issue #5633:
URL: https://github.com/apache/apisix/issues/5633#issuecomment-982366279


   > Have you checked whether the skywalking service is normal? According to 
the error message you provided, this is more like an exception thrown by a 
spring framework?
   
   spring boot service is normal,enable skywalking plugin,the proxy-rewrite 
plugin is not valid. disable skywalking plugin,the proxy-rewrite plugin work 
normally


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] bzp2010 opened a new issue #5647: docs: provide the apisix-base's RPM package

2021-11-29 Thread GitBox


bzp2010 opened a new issue #5647:
URL: https://github.com/apache/apisix/issues/5647


   ### Improved or typo fixed.
   
   The current documentation provides a way to install APISIX directly using 
RPM on CentOS7, but the current APISIX has switched its dependency to 
apisix-base version without providing its RPM installation method, which will 
cause the installation to fail.
   
   
![}7Y8{KOAPW6S2QJL2GRL5X4](https://user-images.githubusercontent.com/8078418/144004655-0c4881ea-ccc8-4a76-a384-4ef51779168e.png)
   
   
   ### Solution
   
   Add a command for install apisix-base‘s RPM. 
   
   ```shell
   sudo yum install -y 
https://repos.apiseven.com/packages/centos/7/x86_64/apisix-base-1.19.3.2.2-0.el7.x86_64.rpm
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] shuaijinchao opened a new pull request #5646: fix: google cloud logging plugin file config error

2021-11-29 Thread GitBox


shuaijinchao opened a new pull request #5646:
URL: https://github.com/apache/apisix/pull/5646


   ### What this PR does / why we need it:
   
   
   reading file config  abnormal
   
   ### Pre-submission checklist:
   
   
   
   * [x] Did you explain what problem does this PR solve? Or what new features 
have been added?
   * [x] Have you added corresponding test cases?
   * [ ] Have you modified the corresponding document?
   * [x] Is this PR backward compatible? **If it is not backward compatible, 
please discuss on the [mailing 
list](https://github.com/apache/apisix/tree/master#community) first**
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] tzssangglass commented on issue #5643: request help: body_filter how to send request in apisix

2021-11-29 Thread GitBox


tzssangglass commented on issue #5643:
URL: https://github.com/apache/apisix/issues/5643#issuecomment-982353405


   we can use a 0 delay  `ngx.timer.at`, see: 
https://github.com/openresty/lua-nginx-module#ngxtimerat


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-ingress-controller] chzhuo commented on issue #769: bug: Unable to reconnect to apisix, when all ep are deleted under svc of apisix

2021-11-29 Thread GitBox


chzhuo commented on issue #769:
URL: 
https://github.com/apache/apisix-ingress-controller/issues/769#issuecomment-982342929


   I encountered the same situation, but I also encountered the problem that 
the leader would not switch.
   Because the failed leader node give up and quickly restarts acquiring the 
lock again. 
   The leader not switch over last two days.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-dashboard] codecov-commenter edited a comment on pull request #2224: fix: stream route testcase CI failed frequent

2021-11-29 Thread GitBox


codecov-commenter edited a comment on pull request #2224:
URL: https://github.com/apache/apisix-dashboard/pull/2224#issuecomment-979757962


   # 
[Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 Report
   > Merging 
[#2224](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (ecd9654) into 
[master](https://codecov.io/gh/apache/apisix-dashboard/commit/b788ab37fdaae244a9415e9bc7b885668cbbf105?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (b788ab3) will **decrease** coverage by `0.19%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@Coverage Diff @@
   ##   master#2224  +/-   ##
   ==
   - Coverage   69.98%   69.79%   -0.20% 
   ==
 Files 184  184  
 Lines7257 7257  
 Branches  824  824  
   ==
   - Hits 5079 5065  -14 
   - Misses   1886 1896  +10 
   - Partials  292  296   +4 
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | backend-e2e-test | `44.40% <ø> (+0.25%)` | :arrow_up: |
   | backend-e2e-test-ginkgo | `51.03% <ø> (-0.98%)` | :arrow_down: |
   | backend-unit-test | `49.16% <ø> (ø)` | |
   | frontend-e2e-test | `68.13% <ø> (ø)` | |
   
   Flags with carried forward coverage won't be shown. [Click 
here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment)
 to find out more.
   
   | [Impacted 
Files](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 | Coverage Δ | |
   |---|---|---|
   | 
[api/internal/handler/upstream/upstream.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvdXBzdHJlYW0vdXBzdHJlYW0uZ28=)
 | `86.58% <0.00%> (-4.27%)` | :arrow_down: |
   | 
[api/internal/core/storage/etcd.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmFnZS9ldGNkLmdv)
 | `47.24% <0.00%> (-3.94%)` | :arrow_down: |
   | 
[api/internal/core/store/store.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvc3RvcmUuZ28=)
 | `89.58% <0.00%> (-1.05%)` | :arrow_down: |
   
   --
   
   [Continue to review full report at 
Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   > **Legend** - [Click here to learn 
more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   > `Δ = absolute  (impact)`, `ø = not affected`, `? = missing data`
   > Powered by 
[Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
 Last update 
[b788ab3...ecd9654](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
 Read the [comment 
docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comme

[GitHub] [apisix-dashboard] codecov-commenter commented on pull request #2229: chore(deps): bump actions/setup-python from 2.2.2 to 2.3.1

2021-11-29 Thread GitBox


codecov-commenter commented on pull request #2229:
URL: https://github.com/apache/apisix-dashboard/pull/2229#issuecomment-982329586


   # 
[Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2229?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 Report
   > Merging 
[#2229](https://codecov.io/gh/apache/apisix-dashboard/pull/2229?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (36b0223) into 
[master](https://codecov.io/gh/apache/apisix-dashboard/commit/d7b772235f1a13660541e6f52c4844a3bb7929f6?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (d7b7722) will **increase** coverage by `3.07%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/apisix-dashboard/pull/2229/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/apisix-dashboard/pull/2229?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@Coverage Diff @@
   ##   master#2229  +/-   ##
   ==
   + Coverage   64.99%   68.07%   +3.07% 
   ==
 Files 184  127  -57 
 Lines7257 3352-3905 
 Branches  824  824  
   ==
   - Hits 4717 2282-2435 
   + Misses   2258 1070-1188 
   + Partials  2820 -282 
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | backend-e2e-test | `?` | |
   | backend-unit-test | `?` | |
   | frontend-e2e-test | `68.07% <ø> (-0.06%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click 
here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment)
 to find out more.
   
   | [Impacted 
Files](https://codecov.io/gh/apache/apisix-dashboard/pull/2229?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 | Coverage Δ | |
   |---|---|---|
   | 
[web/src/helpers.tsx](https://codecov.io/gh/apache/apisix-dashboard/pull/2229/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-d2ViL3NyYy9oZWxwZXJzLnRzeA==)
 | `70.49% <0.00%> (-3.28%)` | :arrow_down: |
   | 
[api/internal/log/log.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2229/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2xvZy9sb2cuZ28=)
 | | |
   | 
[api/internal/handler/healthz/healthz.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2229/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvaGVhbHRoei9oZWFsdGh6Lmdv)
 | | |
   | 
[api/internal/core/store/store\_mock.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2229/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvc3RvcmVfbW9jay5nbw==)
 | | |
   | 
[api/internal/core/storage/etcd.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2229/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmFnZS9ldGNkLmdv)
 | | |
   | 
[api/internal/utils/pid.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2229/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL3V0aWxzL3BpZC5nbw==)
 | | |
   | 
[api/main.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2229/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL21haW4uZ28=)
 | | |
   | 
[.../internal/handler/authentication/authentication.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2229/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation

[GitHub] [apisix-dashboard] codecov-commenter commented on pull request #2230: chore(deps): bump actions/setup-node from 2.4.1 to 2.5.0

2021-11-29 Thread GitBox


codecov-commenter commented on pull request #2230:
URL: https://github.com/apache/apisix-dashboard/pull/2230#issuecomment-982327974


   # 
[Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2230?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 Report
   > Merging 
[#2230](https://codecov.io/gh/apache/apisix-dashboard/pull/2230?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (cac0d75) into 
[master](https://codecov.io/gh/apache/apisix-dashboard/commit/d7b772235f1a13660541e6f52c4844a3bb7929f6?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (d7b7722) will **increase** coverage by `3.13%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/apisix-dashboard/pull/2230/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/apisix-dashboard/pull/2230?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@Coverage Diff @@
   ##   master#2230  +/-   ##
   ==
   + Coverage   64.99%   68.13%   +3.13% 
   ==
 Files 184  127  -57 
 Lines7257 3352-3905 
 Branches  824  824  
   ==
   - Hits 4717 2284-2433 
   + Misses   2258 1068-1190 
   + Partials  2820 -282 
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | backend-e2e-test | `?` | |
   | backend-unit-test | `?` | |
   | frontend-e2e-test | `68.13% <ø> (ø)` | |
   
   Flags with carried forward coverage won't be shown. [Click 
here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment)
 to find out more.
   
   | [Impacted 
Files](https://codecov.io/gh/apache/apisix-dashboard/pull/2230?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 | Coverage Δ | |
   |---|---|---|
   | 
[api/internal/utils/pid.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2230/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL3V0aWxzL3BpZC5nbw==)
 | | |
   | 
[api/internal/core/store/store\_mock.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2230/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvc3RvcmVfbW9jay5nbw==)
 | | |
   | 
[api/internal/core/store/validate\_mock.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2230/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvdmFsaWRhdGVfbW9jay5nbw==)
 | | |
   | 
[api/main.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2230/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL21haW4uZ28=)
 | | |
   | 
[api/internal/utils/json\_patch.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2230/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL3V0aWxzL2pzb25fcGF0Y2guZ28=)
 | | |
   | 
[api/internal/core/entity/format.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2230/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L2Zvcm1hdC5nbw==)
 | | |
   | 
[api/internal/core/storage/etcd.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2230/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmFnZS9ldGNkLmdv)
 | | |
   | 
[api/internal/utils/consts/api\_error.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2230/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YX

[GitHub] [apisix-dashboard] codecov-commenter edited a comment on pull request #2224: fix: stream route testcase CI failed frequent

2021-11-29 Thread GitBox


codecov-commenter edited a comment on pull request #2224:
URL: https://github.com/apache/apisix-dashboard/pull/2224#issuecomment-979757962


   # 
[Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 Report
   > Merging 
[#2224](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (ecd9654) into 
[master](https://codecov.io/gh/apache/apisix-dashboard/commit/b788ab37fdaae244a9415e9bc7b885668cbbf105?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (b788ab3) will **increase** coverage by `1.22%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@Coverage Diff @@
   ##   master#2224  +/-   ##
   ==
   + Coverage   69.98%   71.21%   +1.22% 
   ==
 Files 184   57 -127 
 Lines7257 3905-3352 
 Branches  8240 -824 
   ==
   - Hits 5079 2781-2298 
   + Misses   1886  828-1058 
   - Partials  292  296   +4 
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | backend-e2e-test | `44.40% <ø> (+0.25%)` | :arrow_up: |
   | backend-e2e-test-ginkgo | `51.03% <ø> (-0.98%)` | :arrow_down: |
   | backend-unit-test | `49.16% <ø> (ø)` | |
   | frontend-e2e-test | `?` | |
   
   Flags with carried forward coverage won't be shown. [Click 
here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment)
 to find out more.
   
   | [Impacted 
Files](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 | Coverage Δ | |
   |---|---|---|
   | 
[api/internal/handler/upstream/upstream.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvdXBzdHJlYW0vdXBzdHJlYW0uZ28=)
 | `86.58% <0.00%> (-4.27%)` | :arrow_down: |
   | 
[api/internal/core/storage/etcd.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmFnZS9ldGNkLmdv)
 | `47.24% <0.00%> (-3.94%)` | :arrow_down: |
   | 
[api/internal/core/store/store.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvc3RvcmUuZ28=)
 | `89.58% <0.00%> (-1.05%)` | :arrow_down: |
   | 
[...ream/components/active-check/Healthy/Successes.tsx](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-d2ViL3NyYy9jb21wb25lbnRzL1Vwc3RyZWFtL2NvbXBvbmVudHMvYWN0aXZlLWNoZWNrL0hlYWx0aHkvU3VjY2Vzc2VzLnRzeA==)
 | | |
   | 
[web/src/pages/SSL/components/Step2/index.tsx](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-d2ViL3NyYy9wYWdlcy9TU0wvY29tcG9uZW50cy9TdGVwMi9pbmRleC50c3g=)
 | | |
   | 
[web/src/pages/Setting/service.ts](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-d2ViL3NyYy9wYWdlcy9TZXR0aW5nL3NlcnZpY2UudHM=)
 | | |
   | 
[web/src/pages/Consumer/service.ts](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_c

[GitHub] [apisix-dashboard] codecov-commenter edited a comment on pull request #2224: fix: stream route testcase CI failed frequent

2021-11-29 Thread GitBox


codecov-commenter edited a comment on pull request #2224:
URL: https://github.com/apache/apisix-dashboard/pull/2224#issuecomment-979757962


   # 
[Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 Report
   > Merging 
[#2224](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (ecd9654) into 
[master](https://codecov.io/gh/apache/apisix-dashboard/commit/b788ab37fdaae244a9415e9bc7b885668cbbf105?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (b788ab3) will **decrease** coverage by `2.25%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@Coverage Diff @@
   ##   master#2224  +/-   ##
   ==
   - Coverage   69.98%   67.73%   -2.26% 
   ==
 Files 184   57 -127 
 Lines7257 3905-3352 
 Branches  8240 -824 
   ==
   - Hits 5079 2645-2434 
   + Misses   1886  969 -917 
   + Partials  292  291   -1 
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | backend-e2e-test | `?` | |
   | backend-e2e-test-ginkgo | `51.03% <ø> (-0.98%)` | :arrow_down: |
   | backend-unit-test | `49.16% <ø> (ø)` | |
   | frontend-e2e-test | `?` | |
   
   Flags with carried forward coverage won't be shown. [Click 
here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment)
 to find out more.
   
   | [Impacted 
Files](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 | Coverage Δ | |
   |---|---|---|
   | 
[api/internal/handler/data\_loader/route\_import.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvZGF0YV9sb2FkZXIvcm91dGVfaW1wb3J0Lmdv)
 | `32.11% <0.00%> (-35.41%)` | :arrow_down: |
   | 
[api/internal/utils/closer.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL3V0aWxzL2Nsb3Nlci5nbw==)
 | `33.33% <0.00%> (-33.34%)` | :arrow_down: |
   | 
[api/internal/core/server/server.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc2VydmVyL3NlcnZlci5nbw==)
 | `44.68% <0.00%> (-17.03%)` | :arrow_down: |
   | 
[api/cmd/root.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2NtZC9yb290Lmdv)
 | `62.50% <0.00%> (-15.63%)` | :arrow_down: |
   | 
[api/internal/utils/utils.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL3V0aWxzL3V0aWxzLmdv)
 | `60.00% <0.00%> (-13.00%)` | :arrow_down: |
   | 
[api/internal/core/storage/etcd.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmFnZS9ldGNkLmdv)
 | `44.88% <0.00%> (-6.30%)` | :arrow_down: |
   | 
[api/internal/handler/upstream/upstream.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Sof

[GitHub] [apisix] spacewander merged pull request #5629: feat(discovery): check schema before starting

2021-11-29 Thread GitBox


spacewander merged pull request #5629:
URL: https://github.com/apache/apisix/pull/5629


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] spacewander closed issue #5277: request help: Can strict mode be supported and cannot be started when there is an error in configuration

2021-11-29 Thread GitBox


spacewander closed issue #5277:
URL: https://github.com/apache/apisix/issues/5277


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[apisix] branch master updated (50fcd66 -> cc0b601)

2021-11-29 Thread spacewander
This is an automated email from the ASF dual-hosted git repository.

spacewander pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/apisix.git.


from 50fcd66  feat: add gen-vote-content script (#5595)
 add cc0b601  feat(discovery): check schema before starting (#5629)

No new revisions were added by this update.

Summary of changes:
 apisix/cli/ops.lua | 15 
 .../{consul_kv.lua => consul_kv/init.lua}  | 86 +
 apisix/discovery/consul_kv/schema.lua  | 87 ++
 apisix/discovery/{dns.lua => dns/init.lua} | 25 +--
 .../{core/version.lua => discovery/dns/schema.lua} | 12 ++-
 apisix/discovery/{eureka.lua => eureka/init.lua}   | 39 +-
 .../discovery/eureka/schema.lua| 49 +---
 apisix/discovery/{nacos.lua => nacos/init.lua} | 55 +-
 apisix/discovery/nacos/schema.lua  | 57 ++
 docs/en/latest/discovery.md| 10 ++-
 docs/zh/latest/discovery.md| 10 ++-
 t/cli/test_validate_config.sh  | 25 +++
 t/discovery/dns/sanity.t   | 36 ++---
 13 files changed, 248 insertions(+), 258 deletions(-)
 rename apisix/discovery/{consul_kv.lua => consul_kv/init.lua} (85%)
 create mode 100644 apisix/discovery/consul_kv/schema.lua
 rename apisix/discovery/{dns.lua => dns/init.lua} (80%)
 copy apisix/{core/version.lua => discovery/dns/schema.lua} (78%)
 rename apisix/discovery/{eureka.lua => eureka/init.lua} (86%)
 copy example/apisix/plugins/3rd-party.lua => 
apisix/discovery/eureka/schema.lua (56%)
 rename apisix/discovery/{nacos.lua => nacos/init.lua} (87%)
 create mode 100644 apisix/discovery/nacos/schema.lua


[GitHub] [apisix-dashboard] codecov-commenter edited a comment on pull request #2224: fix: stream route testcase CI failed frequent

2021-11-29 Thread GitBox


codecov-commenter edited a comment on pull request #2224:
URL: https://github.com/apache/apisix-dashboard/pull/2224#issuecomment-979757962


   # 
[Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 Report
   > Merging 
[#2224](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (ecd9654) into 
[master](https://codecov.io/gh/apache/apisix-dashboard/commit/b788ab37fdaae244a9415e9bc7b885668cbbf105?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (b788ab3) will **decrease** coverage by `20.82%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@ Coverage Diff @@
   ##   master#2224   +/-   ##
   ===
   - Coverage   69.98%   49.16%   -20.83% 
   ===
 Files 184   41  -143 
 Lines7257 3171 -4086 
 Branches  8240  -824 
   ===
   - Hits 5079 1559 -3520 
   + Misses   1886 1412  -474 
   + Partials  292  200   -92 
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | backend-e2e-test | `?` | |
   | backend-e2e-test-ginkgo | `?` | |
   | backend-unit-test | `49.16% <ø> (ø)` | |
   | frontend-e2e-test | `?` | |
   
   Flags with carried forward coverage won't be shown. [Click 
here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment)
 to find out more.
   
   | [Impacted 
Files](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 | Coverage Δ | |
   |---|---|---|
   | 
[api/main.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL21haW4uZ28=)
 | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | 
[api/internal/utils/version.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL3V0aWxzL3ZlcnNpb24uZ28=)
 | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | 
[api/internal/filter/request\_id.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2ZpbHRlci9yZXF1ZXN0X2lkLmdv)
 | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | 
[api/internal/core/entity/entity.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L2VudGl0eS5nbw==)
 | `0.00% <0.00%> (-90.91%)` | :arrow_down: |
   | 
[api/internal/core/store/storehub.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvc3RvcmVodWIuZ28=)
 | `0.00% <0.00%> (-72.60%)` | :arrow_down: |
   | 
[api/internal/filter/cors.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2ZpbHRlci9jb3JzLmdv)
 | `0.00% <0.00%> (-70.00%)` | :arrow_down: |
   | 
[api/internal/handler/proto/proto.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvcHJvdG8vcHJvd

[GitHub] [apisix-dashboard] dependabot[bot] opened a new pull request #2230: chore(deps): bump actions/setup-node from 2.4.1 to 2.5.0

2021-11-29 Thread GitBox


dependabot[bot] opened a new pull request #2230:
URL: https://github.com/apache/apisix-dashboard/pull/2230


   Bumps [actions/setup-node](https://github.com/actions/setup-node) from 2.4.1 
to 2.5.0.
   
   Release notes
   Sourced from https://github.com/actions/setup-node/releases";>actions/setup-node's 
releases.
   
   Adding Node.js version file support
   In scope of this release we add the node-version-file input 
and update actions/cache dependency to the latest version.
   Adding Node.js version file support
   The new input (node-version-file) provides functionality to 
specify the path to the file containing Node.js's version with such 
behaviour:
   
   If the file does not exist the action will throw an error.
   If you specify both node-version and 
node-version-file inputs, the action will use value from the 
node-version input and throw the following warning: Both 
node-version and node-version-file inputs are specified, only node-version will 
be used.
   For now the action does not support all of the variety of values for 
Node.js version files. The action can handle values according to the https://github.com/actions/setup-node#supported-version-syntax";>documentation
 and values with v prefix (v14)
   
   steps:
 - uses: actions/checkout@v2
 - name: Setup node from node version file
   uses: actions/setup-node@v2
   with:
 node-version-file: '.nvmrc'
 - run: npm install
 - run: npm test
   
   Update actions/cache dependency to 1.0.8 version.
   We updated actions/cache dependency to the latest version (1.0.8). For 
more information please refer to the https://github.com/actions/toolkit/blob/main/packages/cache/RELEASES.md";>toolkit/cache.
   
   
   
   Commits
   
   https://github.com/actions/setup-node/commit/04c56d2f954f1e4c69436aa54cfef261a018f458";>04c56d2
 update cache to 1.0.8 (https://github-redirect.dependabot.com/actions/setup-node/issues/367";>#367)
   https://github.com/actions/setup-node/commit/d08cf222111d5c1d21b3cd4b958937f818d10d9a";>d08cf22
 Adding Node.js version file support (https://github-redirect.dependabot.com/actions/setup-node/issues/338";>#338)
   https://github.com/actions/setup-node/commit/360ab8b75b056fc18d368ee27a78d34e29c0b2d9";>360ab8b
 Fix typo in the bug_report template (https://github-redirect.dependabot.com/actions/setup-node/issues/353";>#353)
   https://github.com/actions/setup-node/commit/fd4bd829f2dd6b6c1420bd94a93449c54612ffc2";>fd4bd82
 Add issue and pull request templates (https://github-redirect.dependabot.com/actions/setup-node/issues/344";>#344)
   https://github.com/actions/setup-node/commit/a4b8ed2f4e9dd97eeae325f6967ce23d5478bd53";>a4b8ed2
 Update dependencies (https://github-redirect.dependabot.com/actions/setup-node/issues/346";>#346)
   See full diff in https://github.com/actions/setup-node/compare/v2.4.1...v2.5.0";>compare 
view
   
   
   
   
   
   [![Dependabot compatibility 
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=actions/setup-node&package-manager=github_actions&previous-version=2.4.1&new-version=2.5.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
   
   Dependabot will resolve any conflicts with this PR as long as you don't 
alter it yourself. You can also trigger a rebase manually by commenting 
`@dependabot rebase`.
   
   [//]: # (dependabot-automerge-start)
   [//]: # (dependabot-automerge-end)
   
   ---
   
   
   Dependabot commands and options
   
   
   You can trigger Dependabot actions by commenting on this PR:
   - `@dependabot rebase` will rebase this PR
   - `@dependabot recreate` will recreate this PR, overwriting any edits that 
have been made to it
   - `@dependabot merge` will merge this PR after your CI passes on it
   - `@dependabot squash and merge` will squash and merge this PR after your CI 
passes on it
   - `@dependabot cancel merge` will cancel a previously requested merge and 
block automerging
   - `@dependabot reopen` will reopen this PR if it is closed
   - `@dependabot close` will close this PR and stop Dependabot recreating it. 
You can achieve the same result by closing it manually
   - `@dependabot ignore this major version` will close this PR and stop 
Dependabot creating any more for this major version (unless you reopen the PR 
or upgrade to it yourself)
   - `@dependabot ignore this minor version` will close this PR and stop 
Dependabot creating any more for this minor version (unless you reopen the PR 
or upgrade to it yourself)
   - `@dependabot ignore this dependency` will close this PR and stop 
Dependabot creating any more for this dependency (unless you reopen the PR or 
upgrade to it yourself)
   
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubsc

[GitHub] [apisix-dashboard] dependabot[bot] opened a new pull request #2229: chore(deps): bump actions/setup-python from 2.2.2 to 2.3.1

2021-11-29 Thread GitBox


dependabot[bot] opened a new pull request #2229:
URL: https://github.com/apache/apisix-dashboard/pull/2229


   Bumps [actions/setup-python](https://github.com/actions/setup-python) from 
2.2.2 to 2.3.1.
   
   Release notes
   Sourced from https://github.com/actions/setup-python/releases";>actions/setup-python's 
releases.
   
   Update actions/cache version to 1.0.8
   We have updated https://github.com/actions/toolkit/blob/main/packages/cache/RELEASES.md#108";>actions/cache
 dependency version to 1.0.8 to support 10GB cache upload
   Support caching dependencies
   This release introduces dependency caching support (https://github-redirect.dependabot.com/actions/setup-python/pull/266";>actions/setup-python#266)
   Caching dependencies.
   The action has a built-in functionality for caching and restoring 
pip/pipenv dependencies. The cache input is optional, and caching 
is turned off by default.
   Besides, this release introduces dependency caching support for mono 
repos and repositories with complex structure.
   By default, the action searches for the dependency file (requirements.txt 
for pip or Pipfile.lock for pipenv) in the whole repository. Use the 
cache-dependency-path input for cases when you want to override 
current behaviour and use different file for hash generation (for example 
requirements-dev.txt). This input supports wildcards or a list of file names 
for caching multiple dependencies.
   Caching pip dependencies:
   steps:
   - uses: actions/checkout@v2
   - uses: actions/setup-python@v2
 with:
   python-version: '3.9'
   cache: 'pip'
   - run: pip install -r requirements.txt
   - run: pip test
   
   Caching pipenv dependencies:
   steps:
   - uses: actions/checkout@v2
   - name: Install pipenv
 run: pipx install pipenv
   - uses: actions/setup-python@v2
 with:
   python-version: '3.9'
   cache: 'pipenv'
   - run: pipenv install
   - run: pipenv test
   
   Change dependency file:
   steps:
   - uses: actions/checkout@v2
   - uses: actions/setup-python@v2
 with:
   python-version: '3.9'
   cache: 'pip'
   cache-dependency-path: '**/requirements-dev.txt'
   - run: pip install -r subdirectory/requirements-dev.txt
   - run: pip test
    
   
   
   ... (truncated)
   
   
   Commits
   
   https://github.com/actions/setup-python/commit/f38219332975fe8f9c04cca981d674bf22aea1d3";>f382193
 Update @​actions/cache version to 1.0.8 (https://github-redirect.dependabot.com/actions/setup-python/issues/283";>#283)
   https://github.com/actions/setup-python/commit/3ef38b826b0d09ce746cd326f8cdfa37933f0d6d";>3ef38b8
 Create ADR for integrating cache functionality to setup-python action (https://github-redirect.dependabot.com/actions/setup-python/issues/247";>#247)
   https://github.com/actions/setup-python/commit/0066b88440aa9562be742e2c60ee750fc57d8849";>0066b88
 Add a workflow to release a new version of the action (https://github-redirect.dependabot.com/actions/setup-python/issues/274";>#274)
   https://github.com/actions/setup-python/commit/280924fbefbb16de742b89e8dd82ba01b5769011";>280924f
 Implementation of python's caching (https://github-redirect.dependabot.com/actions/setup-python/issues/266";>#266)
   https://github.com/actions/setup-python/commit/52636cf49aeef8753e61f027f11758ed8a3e9f77";>52636cf
 Fix consistency in README (https://github-redirect.dependabot.com/actions/setup-python/issues/250";>#250)
   https://github.com/actions/setup-python/commit/ca5c59064f84b344ed097d6094ee1ce7137e4dee";>ca5c590
 Update version for setup-python in package.json (https://github-redirect.dependabot.com/actions/setup-python/issues/264";>#264)
   https://github.com/actions/setup-python/commit/feeaa3ba49f2b4104b79d61cc6a65fbe66e4637a";>feeaa3b
 Add issue and pull request templates (https://github-redirect.dependabot.com/actions/setup-python/issues/258";>#258)
   https://github.com/actions/setup-python/commit/002b1e40449cd70913538589c187c2728a41cb61";>002b1e4
 Change python version for pypy in workflow files (https://github-redirect.dependabot.com/actions/setup-python/issues/259";>#259)
   https://github.com/actions/setup-python/commit/d12543aa2aa2d1de65cea946cbe1f0c3b720eaae";>d12543a
 Merge pull request https://github-redirect.dependabot.com/actions/setup-python/issues/252";>#252
 from dmitry-shibanov/v-dmshib/update-dependencies
   https://github.com/actions/setup-python/commit/4aa563ba8c162b807c18c46445057827cf6e2cb8";>4aa563b
 update dependencies
   Additional commits viewable in https://github.com/actions/setup-python/compare/v2.2.2...v2.3.1";>compare 
view
   
   
   
   
   
   [![Dependabot compatibility 
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=actions/setup-python&package-manager=github_actions&previous-version=2.2.2&new-version=2.3.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
   
   Dependabot will 

[apisix-dashboard] branch dependabot/github_actions/actions/setup-node-2.5.0 created (now cac0d75)

2021-11-29 Thread github-bot
This is an automated email from the ASF dual-hosted git repository.

github-bot pushed a change to branch 
dependabot/github_actions/actions/setup-node-2.5.0
in repository https://gitbox.apache.org/repos/asf/apisix-dashboard.git.


  at cac0d75  chore(deps): bump actions/setup-node from 2.4.1 to 2.5.0

No new revisions were added by this update.


[apisix-dashboard] branch dependabot/github_actions/actions/setup-python-2.3.1 created (now 36b0223)

2021-11-29 Thread github-bot
This is an automated email from the ASF dual-hosted git repository.

github-bot pushed a change to branch 
dependabot/github_actions/actions/setup-python-2.3.1
in repository https://gitbox.apache.org/repos/asf/apisix-dashboard.git.


  at 36b0223  chore(deps): bump actions/setup-python from 2.2.2 to 2.3.1

No new revisions were added by this update.


[GitHub] [apisix] xianshun163 closed issue #5607: bug: traffic-split err

2021-11-29 Thread GitBox


xianshun163 closed issue #5607:
URL: https://github.com/apache/apisix/issues/5607


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-dashboard] zaunist commented on pull request #2226: fix: plugin_configs should store with etcd prefix

2021-11-29 Thread GitBox


zaunist commented on pull request #2226:
URL: https://github.com/apache/apisix-dashboard/pull/2226#issuecomment-982312126


   > > > LGTM, just wait the CI passed.
   > > 
   > > 
   > > Hi, in this PR, the backend-e2e-ginkgo just run alarm test, is this 
normal ?
   > 
   > cc @bzp2010
   
   😂,I checked again and there is no problem, I was looking at it wrong before, 
this test is running so fast I can't believe it


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-dashboard] juzhiyuan commented on pull request #2226: fix: plugin_configs should store with etcd prefix

2021-11-29 Thread GitBox


juzhiyuan commented on pull request #2226:
URL: https://github.com/apache/apisix-dashboard/pull/2226#issuecomment-982309794


   > > LGTM, just wait the CI passed.
   > 
   > Hi, in this PR, the backend-e2e-ginkgo just run alarm test, is this normal 
?
   
   cc @bzp2010 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-dashboard] zaunist commented on pull request #2226: fix: plugin_configs should store with etcd prefix

2021-11-29 Thread GitBox


zaunist commented on pull request #2226:
URL: https://github.com/apache/apisix-dashboard/pull/2226#issuecomment-982303559


   > LGTM, just wait the CI passed.
   
   Hi, in this PR, the backend-e2e-ginkgo just run alarm test, is this normal ?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] dependabot[bot] opened a new pull request #5644: chore(deps): bump actions/setup-node from 2.4.1 to 2.5.0

2021-11-29 Thread GitBox


dependabot[bot] opened a new pull request #5644:
URL: https://github.com/apache/apisix/pull/5644


   Bumps [actions/setup-node](https://github.com/actions/setup-node) from 2.4.1 
to 2.5.0.
   
   Release notes
   Sourced from https://github.com/actions/setup-node/releases";>actions/setup-node's 
releases.
   
   Adding Node.js version file support
   In scope of this release we add the node-version-file input 
and update actions/cache dependency to the latest version.
   Adding Node.js version file support
   The new input (node-version-file) provides functionality to 
specify the path to the file containing Node.js's version with such 
behaviour:
   
   If the file does not exist the action will throw an error.
   If you specify both node-version and 
node-version-file inputs, the action will use value from the 
node-version input and throw the following warning: Both 
node-version and node-version-file inputs are specified, only node-version will 
be used.
   For now the action does not support all of the variety of values for 
Node.js version files. The action can handle values according to the https://github.com/actions/setup-node#supported-version-syntax";>documentation
 and values with v prefix (v14)
   
   steps:
 - uses: actions/checkout@v2
 - name: Setup node from node version file
   uses: actions/setup-node@v2
   with:
 node-version-file: '.nvmrc'
 - run: npm install
 - run: npm test
   
   Update actions/cache dependency to 1.0.8 version.
   We updated actions/cache dependency to the latest version (1.0.8). For 
more information please refer to the https://github.com/actions/toolkit/blob/main/packages/cache/RELEASES.md";>toolkit/cache.
   
   
   
   Commits
   
   https://github.com/actions/setup-node/commit/04c56d2f954f1e4c69436aa54cfef261a018f458";>04c56d2
 update cache to 1.0.8 (https://github-redirect.dependabot.com/actions/setup-node/issues/367";>#367)
   https://github.com/actions/setup-node/commit/d08cf222111d5c1d21b3cd4b958937f818d10d9a";>d08cf22
 Adding Node.js version file support (https://github-redirect.dependabot.com/actions/setup-node/issues/338";>#338)
   https://github.com/actions/setup-node/commit/360ab8b75b056fc18d368ee27a78d34e29c0b2d9";>360ab8b
 Fix typo in the bug_report template (https://github-redirect.dependabot.com/actions/setup-node/issues/353";>#353)
   https://github.com/actions/setup-node/commit/fd4bd829f2dd6b6c1420bd94a93449c54612ffc2";>fd4bd82
 Add issue and pull request templates (https://github-redirect.dependabot.com/actions/setup-node/issues/344";>#344)
   https://github.com/actions/setup-node/commit/a4b8ed2f4e9dd97eeae325f6967ce23d5478bd53";>a4b8ed2
 Update dependencies (https://github-redirect.dependabot.com/actions/setup-node/issues/346";>#346)
   See full diff in https://github.com/actions/setup-node/compare/v2.4.1...v2.5.0";>compare 
view
   
   
   
   
   
   [![Dependabot compatibility 
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=actions/setup-node&package-manager=github_actions&previous-version=2.4.1&new-version=2.5.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
   
   Dependabot will resolve any conflicts with this PR as long as you don't 
alter it yourself. You can also trigger a rebase manually by commenting 
`@dependabot rebase`.
   
   [//]: # (dependabot-automerge-start)
   [//]: # (dependabot-automerge-end)
   
   ---
   
   
   Dependabot commands and options
   
   
   You can trigger Dependabot actions by commenting on this PR:
   - `@dependabot rebase` will rebase this PR
   - `@dependabot recreate` will recreate this PR, overwriting any edits that 
have been made to it
   - `@dependabot merge` will merge this PR after your CI passes on it
   - `@dependabot squash and merge` will squash and merge this PR after your CI 
passes on it
   - `@dependabot cancel merge` will cancel a previously requested merge and 
block automerging
   - `@dependabot reopen` will reopen this PR if it is closed
   - `@dependabot close` will close this PR and stop Dependabot recreating it. 
You can achieve the same result by closing it manually
   - `@dependabot ignore this major version` will close this PR and stop 
Dependabot creating any more for this major version (unless you reopen the PR 
or upgrade to it yourself)
   - `@dependabot ignore this minor version` will close this PR and stop 
Dependabot creating any more for this minor version (unless you reopen the PR 
or upgrade to it yourself)
   - `@dependabot ignore this dependency` will close this PR and stop 
Dependabot creating any more for this dependency (unless you reopen the PR or 
upgrade to it yourself)
   
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisi

[apisix] branch dependabot/github_actions/actions/setup-node-2.5.0 created (now 6484c77)

2021-11-29 Thread github-bot
This is an automated email from the ASF dual-hosted git repository.

github-bot pushed a change to branch 
dependabot/github_actions/actions/setup-node-2.5.0
in repository https://gitbox.apache.org/repos/asf/apisix.git.


  at 6484c77  chore(deps): bump actions/setup-node from 2.4.1 to 2.5.0

No new revisions were added by this update.


[GitHub] [apisix] spacewander merged pull request #5595: feat: add gen-vote-content script

2021-11-29 Thread GitBox


spacewander merged pull request #5595:
URL: https://github.com/apache/apisix/pull/5595


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[apisix] branch master updated: feat: add gen-vote-content script (#5595)

2021-11-29 Thread spacewander
This is an automated email from the ASF dual-hosted git repository.

spacewander pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/apisix.git


The following commit(s) were added to refs/heads/master by this push:
 new 50fcd66  feat: add gen-vote-content script (#5595)
50fcd66 is described below

commit 50fcd660f5ec00060a22f43b1a91cad7e7b6572a
Author: litesun 
AuthorDate: Tue Nov 30 12:58:36 2021 +0800

feat: add gen-vote-content script (#5595)
---
 Makefile   |  1 +
 utils/gen-vote-contents.sh | 93 ++
 2 files changed, 94 insertions(+)

diff --git a/Makefile b/Makefile
index cc83e7e..ac08efa 100644
--- a/Makefile
+++ b/Makefile
@@ -363,6 +363,7 @@ release-src: compress-tar
mv $(project_release_name).tgz release/$(project_release_name).tgz
mv $(project_release_name).tgz.asc 
release/$(project_release_name).tgz.asc
mv $(project_release_name).tgz.sha512 
release/$(project_release_name).tgz.sha512
+   ./utils/gen-vote-contents.sh $(VERSION)
@$(call func_echo_success_status, "$@ -> [ Done ]")
 
 
diff --git a/utils/gen-vote-contents.sh b/utils/gen-vote-contents.sh
new file mode 100755
index 000..cccae13
--- /dev/null
+++ b/utils/gen-vote-contents.sh
@@ -0,0 +1,93 @@
+#!/bin/sh
+
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+VERSION=$1
+
+SUBSTRING1=$(echo $VERSION| cut -d'.' -f 1)
+SUBSTRING2=$(echo $VERSION| cut -d'.' -f 2)
+BLOB_VERSION=$SUBSTRING1.$SUBSTRING2
+CHANGELOG_HASH=$(printf $VERSION | sed 's/\.//g')
+
+RELEASE_NOTE_PR="https://github.com/apache/apisix/blob/release/$BLOB_VERSION/CHANGELOG.md#$CHANGELOG_HASH";
+COMMIT_ID=$(git rev-parse --short HEAD)
+
+vote_contents=$(cat  ./release/apache-apisix-$VERSION-vote-contents.txt


[GitHub] [apisix-dashboard] codecov-commenter edited a comment on pull request #2224: fix: stream route testcase CI failed frequent

2021-11-29 Thread GitBox


codecov-commenter edited a comment on pull request #2224:
URL: https://github.com/apache/apisix-dashboard/pull/2224#issuecomment-979757962


   # 
[Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 Report
   > Merging 
[#2224](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (0038470) into 
[master](https://codecov.io/gh/apache/apisix-dashboard/commit/b788ab37fdaae244a9415e9bc7b885668cbbf105?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (b788ab3) will **decrease** coverage by `14.73%`.
   > The diff coverage is `n/a`.
   
   > :exclamation: Current head 0038470 differs from pull request most recent 
head df3b4b0. Consider uploading reports for the commit df3b4b0 to get more 
accurate results
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@ Coverage Diff @@
   ##   master#2224   +/-   ##
   ===
   - Coverage   69.98%   55.25%   -14.74% 
   ===
 Files 184  184   
 Lines7257 7257   
 Branches  824  824   
   ===
   - Hits 5079 4010 -1069 
   - Misses   1886 2963 +1077 
   + Partials  292  284-8 
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | backend-e2e-test | `44.19% <ø> (+0.05%)` | :arrow_up: |
   | backend-e2e-test-ginkgo | `?` | |
   | backend-unit-test | `?` | |
   | frontend-e2e-test | `68.13% <ø> (ø)` | |
   
   Flags with carried forward coverage won't be shown. [Click 
here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment)
 to find out more.
   
   | [Impacted 
Files](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 | Coverage Δ | |
   |---|---|---|
   | 
[api/internal/core/migrate/conflict.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvbWlncmF0ZS9jb25mbGljdC5nbw==)
 | `0.00% <0.00%> (-80.00%)` | :arrow_down: |
   | 
[api/internal/handler/schema/plugin.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvc2NoZW1hL3BsdWdpbi5nbw==)
 | `20.00% <0.00%> (-80.00%)` | :arrow_down: |
   | 
[api/internal/core/migrate/migrate.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvbWlncmF0ZS9taWdyYXRlLmdv)
 | `0.00% <0.00%> (-76.20%)` | :arrow_down: |
   | 
[api/internal/handler/schema/schema.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvc2NoZW1hL3NjaGVtYS5nbw==)
 | `28.00% <0.00%> (-72.00%)` | :arrow_down: |
   | 
[api/internal/handler/ssl/ssl.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvc3NsL3NzbC5nbw==)
 | `11.84% <0.00%> (-62.56%)` | :arrow_down: |
   | 
[api/internal/utils/runtime/runtime.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL3V0aWxzL3J1bnRpbWUvcnVudGltZS5nbw==)
 | `5.55% <0.00%> (-

[GitHub] [apisix] spacewander merged pull request #5635: refactor: exact APISIX vars

2021-11-29 Thread GitBox


spacewander merged pull request #5635:
URL: https://github.com/apache/apisix/pull/5635


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[apisix] branch master updated: refactor: exact APISIX vars (#5635)

2021-11-29 Thread spacewander
This is an automated email from the ASF dual-hosted git repository.

spacewander pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/apisix.git


The following commit(s) were added to refs/heads/master by this push:
 new 2969a4b  refactor: exact APISIX vars (#5635)
2969a4b is described below

commit 2969a4bf55910dbbb75f44a4ea1779fbf40f68bf
Author: 罗泽轩 
AuthorDate: Tue Nov 30 12:30:41 2021 +0800

refactor: exact APISIX vars (#5635)
---
 apisix/core/ctx.lua | 32 
 1 file changed, 12 insertions(+), 20 deletions(-)

diff --git a/apisix/core/ctx.lua b/apisix/core/ctx.lua
index 30c7644..f07665a 100644
--- a/apisix/core/ctx.lua
+++ b/apisix/core/ctx.lua
@@ -143,6 +143,16 @@ do
 var_x_forwarded_proto = true,
 }
 
+local apisix_var_names = {
+route_id = true,
+route_name = true,
+service_id = true,
+service_name = true,
+consumer_name = true,
+balancer_ip = true,
+balancer_port = true,
+}
+
 local mt = {
 __index = function(t, key)
 local cached = t._cache[key]
@@ -205,26 +215,8 @@ do
 key = sub_str(key, 9)
 val = get_parsed_graphql()[key]
 
-elseif key == "route_id" then
-val = ngx.ctx.api_ctx and ngx.ctx.api_ctx.route_id
-
-elseif key == "service_id" then
-val = ngx.ctx.api_ctx and ngx.ctx.api_ctx.service_id
-
-elseif key == "consumer_name" then
-val = ngx.ctx.api_ctx and ngx.ctx.api_ctx.consumer_name
-
-elseif key == "route_name" then
-val = ngx.ctx.api_ctx and ngx.ctx.api_ctx.route_name
-
-elseif key == "service_name" then
-val = ngx.ctx.api_ctx and ngx.ctx.api_ctx.service_name
-
-elseif key == "balancer_ip" then
-val = ngx.ctx.api_ctx and ngx.ctx.api_ctx.balancer_ip
-
-elseif key == "balancer_port" then
-val = ngx.ctx.api_ctx and ngx.ctx.api_ctx.balancer_port
+elseif apisix_var_names[key] then
+val = ngx.ctx.api_ctx and ngx.ctx.api_ctx[key]
 
 else
 val = get_var(key, t._request)


[GitHub] [apisix] bisakhmondal commented on a change in pull request #5594: feat(plugins): aws lambda serverless

2021-11-29 Thread GitBox


bisakhmondal commented on a change in pull request #5594:
URL: https://github.com/apache/apisix/pull/5594#discussion_r758502099



##
File path: t/admin/plugins.t
##
@@ -40,7 +40,7 @@ __DATA__
 --- request
 GET /apisix/admin/plugins/list
 --- response_body_like eval
-qr/\["real-ip","client-control","ext-plugin-pre-req","zipkin","request-id","fault-injection","serverless-pre-function","batch-requests","cors","ip-restriction","ua-restriction","referer-restriction","uri-blocker","request-validation","openid-connect","authz-casbin","wolf-rbac","ldap-auth","hmac-auth","basic-auth","jwt-auth","key-auth","consumer-restriction","authz-keycloak","proxy-mirror","proxy-cache","proxy-rewrite","api-breaker","limit-conn","limit-count","limit-req","gzip","server-info","traffic-split","redirect","response-rewrite","grpc-transcode","prometheus","datadog","echo","http-logger","skywalking-logger","google-cloud-logging","sls-logger","tcp-logger","kafka-logger","syslog","udp-logger","example-plugin","azure-functions","openwhisk","serverless-post-function","ext-plugin-post-req"\]/
+qr/\["real-ip","client-control","ext-plugin-pre-req","zipkin","request-id","fault-injection","serverless-pre-function","batch-requests","cors","ip-restriction","ua-restriction","referer-restriction","uri-blocker","request-validation","openid-connect","authz-casbin","wolf-rbac","ldap-auth","hmac-auth","basic-auth","jwt-auth","key-auth","consumer-restriction","authz-keycloak","proxy-mirror","proxy-cache","proxy-rewrite","api-breaker","limit-conn","limit-count","limit-req","gzip","server-info","traffic-split","redirect","response-rewrite","grpc-transcode","prometheus","datadog","echo","http-logger","skywalking-logger","google-cloud-logging","sls-logger","tcp-logger","kafka-logger","syslog","udp-logger","example-plugin","aws-lambda","azure-functions","openwhisk","serverless-post-function","ext-plugin-post-req"\]/

Review comment:
   Guys, here it is: https://github.com/apache/apisix/pull/5642




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-dashboard] bzp2010 merged pull request #2226: fix: plugin_configs should store with etcd prefix

2021-11-29 Thread GitBox


bzp2010 merged pull request #2226:
URL: https://github.com/apache/apisix-dashboard/pull/2226


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[apisix-dashboard] branch master updated: fix: plugin_config ingore etcd prefix configure (#2226)

2021-11-29 Thread bzp2010
This is an automated email from the ASF dual-hosted git repository.

bzp2010 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/apisix-dashboard.git


The following commit(s) were added to refs/heads/master by this push:
 new d7b7722  fix: plugin_config ingore etcd prefix configure (#2226)
d7b7722 is described below

commit d7b772235f1a13660541e6f52c4844a3bb7929f6
Author: MizuhaHimuraki 
AuthorDate: Tue Nov 30 12:11:17 2021 +0800

fix: plugin_config ingore etcd prefix configure (#2226)
---
 api/internal/core/store/storehub.go | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/api/internal/core/store/storehub.go 
b/api/internal/core/store/storehub.go
index 9ef224a..1184a3f 100644
--- a/api/internal/core/store/storehub.go
+++ b/api/internal/core/store/storehub.go
@@ -194,7 +194,7 @@ func InitStores() error {
}
 
err = InitStore(HubKeyPluginConfig, GenericStoreOption{
-   BasePath: "/apisix/plugin_configs",
+   BasePath: conf.ETCDConfig.Prefix + "/plugin_configs",
ObjType:  reflect.TypeOf(entity.PluginConfig{}),
KeyFunc: func(obj interface{}) string {
r := obj.(*entity.PluginConfig)


[apisix-website] branch dependabot/github_actions/actions/setup-node-2.5.0 created (now 8dd58dd)

2021-11-29 Thread github-bot
This is an automated email from the ASF dual-hosted git repository.

github-bot pushed a change to branch 
dependabot/github_actions/actions/setup-node-2.5.0
in repository https://gitbox.apache.org/repos/asf/apisix-website.git.


  at 8dd58dd  chore(deps): bump actions/setup-node from 2.4.1 to 2.5.0

No new revisions were added by this update.


[apisix-website] branch dependabot/github_actions/actions/setup-python-2.3.1 created (now a35491f)

2021-11-29 Thread github-bot
This is an automated email from the ASF dual-hosted git repository.

github-bot pushed a change to branch 
dependabot/github_actions/actions/setup-python-2.3.1
in repository https://gitbox.apache.org/repos/asf/apisix-website.git.


  at a35491f  chore(deps): bump actions/setup-python from 2.2.2 to 2.3.1

No new revisions were added by this update.


[GitHub] [apisix-website] dependabot[bot] opened a new pull request #779: chore(deps): bump actions/setup-python from 2.2.2 to 2.3.1

2021-11-29 Thread GitBox


dependabot[bot] opened a new pull request #779:
URL: https://github.com/apache/apisix-website/pull/779


   Bumps [actions/setup-python](https://github.com/actions/setup-python) from 
2.2.2 to 2.3.1.
   
   Release notes
   Sourced from https://github.com/actions/setup-python/releases";>actions/setup-python's 
releases.
   
   Update actions/cache version to 1.0.8
   We have updated https://github.com/actions/toolkit/blob/main/packages/cache/RELEASES.md#108";>actions/cache
 dependency version to 1.0.8 to support 10GB cache upload
   Support caching dependencies
   This release introduces dependency caching support (https://github-redirect.dependabot.com/actions/setup-python/pull/266";>actions/setup-python#266)
   Caching dependencies.
   The action has a built-in functionality for caching and restoring 
pip/pipenv dependencies. The cache input is optional, and caching 
is turned off by default.
   Besides, this release introduces dependency caching support for mono 
repos and repositories with complex structure.
   By default, the action searches for the dependency file (requirements.txt 
for pip or Pipfile.lock for pipenv) in the whole repository. Use the 
cache-dependency-path input for cases when you want to override 
current behaviour and use different file for hash generation (for example 
requirements-dev.txt). This input supports wildcards or a list of file names 
for caching multiple dependencies.
   Caching pip dependencies:
   steps:
   - uses: actions/checkout@v2
   - uses: actions/setup-python@v2
 with:
   python-version: '3.9'
   cache: 'pip'
   - run: pip install -r requirements.txt
   - run: pip test
   
   Caching pipenv dependencies:
   steps:
   - uses: actions/checkout@v2
   - name: Install pipenv
 run: pipx install pipenv
   - uses: actions/setup-python@v2
 with:
   python-version: '3.9'
   cache: 'pipenv'
   - run: pipenv install
   - run: pipenv test
   
   Change dependency file:
   steps:
   - uses: actions/checkout@v2
   - uses: actions/setup-python@v2
 with:
   python-version: '3.9'
   cache: 'pip'
   cache-dependency-path: '**/requirements-dev.txt'
   - run: pip install -r subdirectory/requirements-dev.txt
   - run: pip test
    
   
   
   ... (truncated)
   
   
   Commits
   
   https://github.com/actions/setup-python/commit/f38219332975fe8f9c04cca981d674bf22aea1d3";>f382193
 Update @​actions/cache version to 1.0.8 (https://github-redirect.dependabot.com/actions/setup-python/issues/283";>#283)
   https://github.com/actions/setup-python/commit/3ef38b826b0d09ce746cd326f8cdfa37933f0d6d";>3ef38b8
 Create ADR for integrating cache functionality to setup-python action (https://github-redirect.dependabot.com/actions/setup-python/issues/247";>#247)
   https://github.com/actions/setup-python/commit/0066b88440aa9562be742e2c60ee750fc57d8849";>0066b88
 Add a workflow to release a new version of the action (https://github-redirect.dependabot.com/actions/setup-python/issues/274";>#274)
   https://github.com/actions/setup-python/commit/280924fbefbb16de742b89e8dd82ba01b5769011";>280924f
 Implementation of python's caching (https://github-redirect.dependabot.com/actions/setup-python/issues/266";>#266)
   https://github.com/actions/setup-python/commit/52636cf49aeef8753e61f027f11758ed8a3e9f77";>52636cf
 Fix consistency in README (https://github-redirect.dependabot.com/actions/setup-python/issues/250";>#250)
   https://github.com/actions/setup-python/commit/ca5c59064f84b344ed097d6094ee1ce7137e4dee";>ca5c590
 Update version for setup-python in package.json (https://github-redirect.dependabot.com/actions/setup-python/issues/264";>#264)
   https://github.com/actions/setup-python/commit/feeaa3ba49f2b4104b79d61cc6a65fbe66e4637a";>feeaa3b
 Add issue and pull request templates (https://github-redirect.dependabot.com/actions/setup-python/issues/258";>#258)
   https://github.com/actions/setup-python/commit/002b1e40449cd70913538589c187c2728a41cb61";>002b1e4
 Change python version for pypy in workflow files (https://github-redirect.dependabot.com/actions/setup-python/issues/259";>#259)
   https://github.com/actions/setup-python/commit/d12543aa2aa2d1de65cea946cbe1f0c3b720eaae";>d12543a
 Merge pull request https://github-redirect.dependabot.com/actions/setup-python/issues/252";>#252
 from dmitry-shibanov/v-dmshib/update-dependencies
   https://github.com/actions/setup-python/commit/4aa563ba8c162b807c18c46445057827cf6e2cb8";>4aa563b
 update dependencies
   Additional commits viewable in https://github.com/actions/setup-python/compare/v2.2.2...v2.3.1";>compare 
view
   
   
   
   
   
   [![Dependabot compatibility 
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=actions/setup-python&package-manager=github_actions&previous-version=2.2.2&new-version=2.3.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
   
   Dependabot will reso

[GitHub] [apisix-website] dependabot[bot] commented on pull request #752: chore(deps): bump actions/setup-python from 2.2.2 to 2.3.0

2021-11-29 Thread GitBox


dependabot[bot] commented on pull request #752:
URL: https://github.com/apache/apisix-website/pull/752#issuecomment-982265577


   Superseded by #779.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-website] dependabot[bot] opened a new pull request #780: chore(deps): bump actions/setup-node from 2.4.1 to 2.5.0

2021-11-29 Thread GitBox


dependabot[bot] opened a new pull request #780:
URL: https://github.com/apache/apisix-website/pull/780


   Bumps [actions/setup-node](https://github.com/actions/setup-node) from 2.4.1 
to 2.5.0.
   
   Release notes
   Sourced from https://github.com/actions/setup-node/releases";>actions/setup-node's 
releases.
   
   Adding Node.js version file support
   In scope of this release we add the node-version-file input 
and update actions/cache dependency to the latest version.
   Adding Node.js version file support
   The new input (node-version-file) provides functionality to 
specify the path to the file containing Node.js's version with such 
behaviour:
   
   If the file does not exist the action will throw an error.
   If you specify both node-version and 
node-version-file inputs, the action will use value from the 
node-version input and throw the following warning: Both 
node-version and node-version-file inputs are specified, only node-version will 
be used.
   For now the action does not support all of the variety of values for 
Node.js version files. The action can handle values according to the https://github.com/actions/setup-node#supported-version-syntax";>documentation
 and values with v prefix (v14)
   
   steps:
 - uses: actions/checkout@v2
 - name: Setup node from node version file
   uses: actions/setup-node@v2
   with:
 node-version-file: '.nvmrc'
 - run: npm install
 - run: npm test
   
   Update actions/cache dependency to 1.0.8 version.
   We updated actions/cache dependency to the latest version (1.0.8). For 
more information please refer to the https://github.com/actions/toolkit/blob/main/packages/cache/RELEASES.md";>toolkit/cache.
   
   
   
   Commits
   
   https://github.com/actions/setup-node/commit/04c56d2f954f1e4c69436aa54cfef261a018f458";>04c56d2
 update cache to 1.0.8 (https://github-redirect.dependabot.com/actions/setup-node/issues/367";>#367)
   https://github.com/actions/setup-node/commit/d08cf222111d5c1d21b3cd4b958937f818d10d9a";>d08cf22
 Adding Node.js version file support (https://github-redirect.dependabot.com/actions/setup-node/issues/338";>#338)
   https://github.com/actions/setup-node/commit/360ab8b75b056fc18d368ee27a78d34e29c0b2d9";>360ab8b
 Fix typo in the bug_report template (https://github-redirect.dependabot.com/actions/setup-node/issues/353";>#353)
   https://github.com/actions/setup-node/commit/fd4bd829f2dd6b6c1420bd94a93449c54612ffc2";>fd4bd82
 Add issue and pull request templates (https://github-redirect.dependabot.com/actions/setup-node/issues/344";>#344)
   https://github.com/actions/setup-node/commit/a4b8ed2f4e9dd97eeae325f6967ce23d5478bd53";>a4b8ed2
 Update dependencies (https://github-redirect.dependabot.com/actions/setup-node/issues/346";>#346)
   See full diff in https://github.com/actions/setup-node/compare/v2.4.1...v2.5.0";>compare 
view
   
   
   
   
   
   [![Dependabot compatibility 
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=actions/setup-node&package-manager=github_actions&previous-version=2.4.1&new-version=2.5.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
   
   Dependabot will resolve any conflicts with this PR as long as you don't 
alter it yourself. You can also trigger a rebase manually by commenting 
`@dependabot rebase`.
   
   [//]: # (dependabot-automerge-start)
   [//]: # (dependabot-automerge-end)
   
   ---
   
   
   Dependabot commands and options
   
   
   You can trigger Dependabot actions by commenting on this PR:
   - `@dependabot rebase` will rebase this PR
   - `@dependabot recreate` will recreate this PR, overwriting any edits that 
have been made to it
   - `@dependabot merge` will merge this PR after your CI passes on it
   - `@dependabot squash and merge` will squash and merge this PR after your CI 
passes on it
   - `@dependabot cancel merge` will cancel a previously requested merge and 
block automerging
   - `@dependabot reopen` will reopen this PR if it is closed
   - `@dependabot close` will close this PR and stop Dependabot recreating it. 
You can achieve the same result by closing it manually
   - `@dependabot ignore this major version` will close this PR and stop 
Dependabot creating any more for this major version (unless you reopen the PR 
or upgrade to it yourself)
   - `@dependabot ignore this minor version` will close this PR and stop 
Dependabot creating any more for this minor version (unless you reopen the PR 
or upgrade to it yourself)
   - `@dependabot ignore this dependency` will close this PR and stop 
Dependabot creating any more for this dependency (unless you reopen the PR or 
upgrade to it yourself)
   
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...

[GitHub] [apisix-website] dependabot[bot] closed pull request #752: chore(deps): bump actions/setup-python from 2.2.2 to 2.3.0

2021-11-29 Thread GitBox


dependabot[bot] closed pull request #752:
URL: https://github.com/apache/apisix-website/pull/752


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] spacewander commented on a change in pull request #5595: feat: add gen-vote-content script

2021-11-29 Thread GitBox


spacewander commented on a change in pull request #5595:
URL: https://github.com/apache/apisix/pull/5595#discussion_r758913257



##
File path: utils/gen-vote-contents.sh
##
@@ -0,0 +1,93 @@
+#!/bin/sh
+
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+VERSION=$1
+
+SUBSTRING1=$(echo $VERSION| cut -d'.' -f 1)
+SUBSTRING2=$(echo $VERSION| cut -d'.' -f 2)
+BLOB_VERSION=$SUBSTRING1.$SUBSTRING2
+CHANGELOG_HASH=$(printf $VERSION | sed 's/\.//g')
+
+RELEASE_NOTE_PR="https://github.com/apache/apisix/blob/release/$BLOB_VERSION/CHANGELOG.md#$CHANGELOG_HASH";
+COMMIT_ID=`git rev-parse --short HEAD`

Review comment:
   ```suggestion
   COMMIT_ID=$(git rev-parse --short HEAD)
   ```




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] bisakhmondal commented on a change in pull request #5594: feat(plugins): aws lambda serverless

2021-11-29 Thread GitBox


bisakhmondal commented on a change in pull request #5594:
URL: https://github.com/apache/apisix/pull/5594#discussion_r758913144



##
File path: apisix/plugins/aws-lambda.lua
##
@@ -0,0 +1,183 @@
+--
+-- Licensed to the Apache Software Foundation (ASF) under one or more
+-- contributor license agreements.  See the NOTICE file distributed with
+-- this work for additional information regarding copyright ownership.
+-- The ASF licenses this file to You under the Apache License, Version 2.0
+-- (the "License"); you may not use this file except in compliance with
+-- the License.  You may obtain a copy of the License at
+--
+-- http://www.apache.org/licenses/LICENSE-2.0
+--
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+
+local ngx = ngx
+local hmac = require("resty.hmac")
+local hex_encode = require("resty.string").to_hex
+local resty_sha256 = require("resty.sha256")
+local str_strip = require("pl.stringx").strip
+local norm_path = require("pl.path").normpath
+local pairs = pairs
+local tab_concat = table.concat
+local tab_sort = table.sort
+local os = os
+
+
+local plugin_name = "aws-lambda"
+local plugin_version = 0.1
+local priority = -1899
+
+local ALGO = "AWS4-HMAC-SHA256"
+
+local function hmac256(key, msg)
+return hmac:new(key, hmac.ALGOS.SHA256):final(msg)
+end
+
+local function sha256(msg)
+local hash = resty_sha256:new()
+hash:update(msg)
+local digest = hash:final()
+return hex_encode(digest)
+end
+
+local function get_signature_key(key, datestamp, region, service)
+local kDate = hmac256("AWS4" .. key, datestamp)
+local kRegion = hmac256(kDate, region)
+local kService = hmac256(kRegion, service)
+local kSigning = hmac256(kService, "aws4_request")
+return kSigning
+end
+
+local aws_authz_schema = {
+type = "object",
+properties = {
+-- API Key based authorization
+apikey = {type = "string"},
+-- IAM role based authorization, works via aws v4 request signing
+-- more at 
https://docs.aws.amazon.com/general/latest/gr/sigv4_signing.html
+iam = {
+type = "object",
+properties = {
+accesskey = {
+type = "string",
+description = "access key id from from aws iam console"
+},
+secretkey = {
+type = "string",
+description = "secret access key from from aws iam console"
+},
+aws_region = {
+type = "string",
+default = "us-east-1",
+description = "the aws region that is receiving the 
request"
+},
+service = {
+type = "string",
+default = "execute-api",
+description = "the service that is receiving the request"
+}
+},
+required = {"accesskey", "secretkey"}
+}
+}
+}
+
+local function request_processor(conf, ctx, params)
+local headers = params.headers
+-- set authorization headers if not already set by the client
+-- we are following not to overwrite the authz keys
+if not headers["x-api-key"] then
+if conf.authorization and conf.authorization.apikey then
+headers["x-api-key"] = conf.authorization.apikey
+return
+end
+end
+
+-- performing aws v4 request signing for IAM authorization
+-- visit 
https://docs.aws.amazon.com/general/latest/gr/sigv4-signed-request-examples.html
+-- to look at the pseudocode in python.
+if headers["authorization"] or not conf.authorization or not 
conf.authorization.iam then
+return
+end
+
+-- create a date for headers and the credential string
+local t = ngx.time()
+local amzdate =  os.date("!%Y%m%dT%H%M%SZ", t)
+local datestamp = os.date("!%Y%m%d", t) -- Date w/o time, used in 
credential scope
+headers["X-Amz-Date"] = amzdate
+
+-- computing canonical uri
+local canonical_uri = norm_path(params.path)
+if canonical_uri ~= "/" then
+if canonical_uri:sub(-1, -1) == "/" then
+canonical_uri = canonical_uri:sub(1, -2)
+end
+if canonical_uri:sub(1, 1) ~= "/" then
+canonical_uri = "/" .. canonical_uri
+end
+end
+
+-- computing canonical query string
+local canonical_qs = {}
+for k, v in pairs(params.query) do
+canonical_qs[#canonical_qs+1] = ngx.unescape_uri(k) .. "=" .. 
ngx.unescape_uri(v)
+end
+
+tab_sort(canonical_qs)
+canonical_qs = tab_concat(canonical_qs, "&")
+
+-- computing canonical and signed headers
+

[apisix] branch master updated: refactor: plugins list test representation (#5642)

2021-11-29 Thread spacewander
This is an automated email from the ASF dual-hosted git repository.

spacewander pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/apisix.git


The following commit(s) were added to refs/heads/master by this push:
 new 95af20a  refactor: plugins list test representation (#5642)
95af20a is described below

commit 95af20ac73d3dbd433157e99a462a18529033fb4
Author: Bisakh 
AuthorDate: Tue Nov 30 09:25:56 2021 +0530

refactor: plugins list test representation (#5642)
---
 t/admin/plugins.t | 79 ---
 1 file changed, 76 insertions(+), 3 deletions(-)

diff --git a/t/admin/plugins.t b/t/admin/plugins.t
index f20b8b9..4305b66 100644
--- a/t/admin/plugins.t
+++ b/t/admin/plugins.t
@@ -38,9 +38,82 @@ __DATA__
 
 === TEST 1: get plugins' name
 --- request
-GET /apisix/admin/plugins/list
 response_body_like eval
-qr/\["real-ip","client-control","ext-plugin-pre-req","zipkin","request-id","fault-injection","serverless-pre-function","batch-requests","cors","ip-restriction","ua-restriction","referer-restriction","uri-blocker","request-validation","openid-connect","authz-casbin","wolf-rbac","ldap-auth","hmac-auth","basic-auth","jwt-auth","key-auth","consumer-restriction","authz-keycloak","proxy-mirror","proxy-cache","proxy-rewrite","api-breaker","limit-conn","limit-count","limit-req","gzip","server-in
 [...]
+--- config
+location /t {
+content_by_lua_block {
+local t = require("lib.test_admin").test
+local json = require('cjson')
+local code, _, body = t("/apisix/admin/plugins/list", "GET")
+ if code >= 300 then
+ngx.status = code
+ngx.say(body)
+return
+end
+
+local tab = json.decode(body)
+for _, v in ipairs(tab) do
+ngx.say(v)
+end
+}
+}
+--- request
+GET /t
+
+--- response_body
+real-ip
+client-control
+ext-plugin-pre-req
+zipkin
+request-id
+fault-injection
+serverless-pre-function
+batch-requests
+cors
+ip-restriction
+ua-restriction
+referer-restriction
+uri-blocker
+request-validation
+openid-connect
+authz-casbin
+wolf-rbac
+ldap-auth
+hmac-auth
+basic-auth
+jwt-auth
+key-auth
+consumer-restriction
+authz-keycloak
+proxy-mirror
+proxy-cache
+proxy-rewrite
+api-breaker
+limit-conn
+limit-count
+limit-req
+gzip
+server-info
+traffic-split
+redirect
+response-rewrite
+grpc-transcode
+prometheus
+datadog
+echo
+http-logger
+skywalking-logger
+google-cloud-logging
+sls-logger
+tcp-logger
+kafka-logger
+syslog
+udp-logger
+example-plugin
+azure-functions
+openwhisk
+serverless-post-function
+ext-plugin-post-req
+
 --- no_error_log
 [error]
 


[GitHub] [apisix] spacewander merged pull request #5642: refactor: plugins list test representation

2021-11-29 Thread GitBox


spacewander merged pull request #5642:
URL: https://github.com/apache/apisix/pull/5642


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-java-plugin-runner] tiankanghello opened a new issue #92: request help: How to get all the information in the original request header.

2021-11-29 Thread GitBox


tiankanghello opened a new issue #92:
URL: https://github.com/apache/apisix-java-plugin-runner/issues/92


   
   What can I do to get all the information in the original request header, 
including the host and URI of the request, and the query parameter in the URI. 
ApiSix doesn't seem to have a good example of how to get the content in the 
original request


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-dashboard] codecov-commenter edited a comment on pull request #2226: fix: plugin_configs should store with etcd prefix

2021-11-29 Thread GitBox


codecov-commenter edited a comment on pull request #2226:
URL: https://github.com/apache/apisix-dashboard/pull/2226#issuecomment-982233726


   # 
[Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2226?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 Report
   > Merging 
[#2226](https://codecov.io/gh/apache/apisix-dashboard/pull/2226?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (ad710f8) into 
[master](https://codecov.io/gh/apache/apisix-dashboard/commit/a55568408cec5eb2628971d2098a9bef992ff548?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (a555684) will **increase** coverage by `7.45%`.
   > The diff coverage is `100.00%`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/apisix-dashboard/pull/2226/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/apisix-dashboard/pull/2226?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@Coverage Diff @@
   ##   master#2226  +/-   ##
   ==
   + Coverage   62.43%   69.89%   +7.45% 
   ==
 Files  57  184 +127 
 Lines3905 7257+3352 
 Branches0  824 +824 
   ==
   + Hits 2438 5072+2634 
   - Misses   1185 1891 +706 
   - Partials  282  294  +12 
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | backend-e2e-test | `44.19% <100.00%> (-0.11%)` | :arrow_down: |
   | backend-e2e-test-ginkgo | `52.06% <100.00%> (?)` | |
   | backend-unit-test | `49.16% <0.00%> (+0.03%)` | :arrow_up: |
   | frontend-e2e-test | `68.13% <ø> (?)` | |
   
   Flags with carried forward coverage won't be shown. [Click 
here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment)
 to find out more.
   
   | [Impacted 
Files](https://codecov.io/gh/apache/apisix-dashboard/pull/2226?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 | Coverage Δ | |
   |---|---|---|
   | 
[api/internal/core/store/storehub.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2226/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvc3RvcmVodWIuZ28=)
 | `72.59% <100.00%> (+17.03%)` | :arrow_up: |
   | 
[web/src/constants.ts](https://codecov.io/gh/apache/apisix-dashboard/pull/2226/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-d2ViL3NyYy9jb25zdGFudHMudHM=)
 | `100.00% <0.00%> (ø)` | |
   | 
[web/src/components/PluginFlow/PluginFlow.tsx](https://codecov.io/gh/apache/apisix-dashboard/pull/2226/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-d2ViL3NyYy9jb21wb25lbnRzL1BsdWdpbkZsb3cvUGx1Z2luRmxvdy50c3g=)
 | `1.42% <0.00%> (ø)` | |
   | 
[web/src/components/Plugin/UI/limit-conn.tsx](https://codecov.io/gh/apache/apisix-dashboard/pull/2226/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-d2ViL3NyYy9jb21wb25lbnRzL1BsdWdpbi9VSS9saW1pdC1jb25uLnRzeA==)
 | `92.30% <0.00%> (ø)` | |
   | 
[web/src/components/Plugin/UI/plugin.tsx](https://codecov.io/gh/apache/apisix-dashboard/pull/2226/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-d2ViL3NyYy9jb21wb25lbnRzL1BsdWdpbi9VSS9wbHVnaW4udHN4)
 | `91.66% <0.00%> (ø)` | |
   | 
[...nents/Upstream/components/ServiceDiscoveryArgs.tsx](https://codecov.io/gh/apache/apisix-dashboard/pull/2226/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-d2ViL3NyYy9jb21wb25lbnRzL1Vwc3RyZWFtL2NvbXBvbmVudHMvU2VydmljZURpc2NvdmVyeUFyZ3MudHN4)
 | `100.00% <0.00%> (ø)` | |
   | 
[web/src/components/Upstream/components/TLS.tsx](https://codecov.io/gh/apache/apisix-dashboard/pull/2226/diff?src=pr&el=tree&utm_m

[GitHub] [apisix-ingress-controller] gxthrj commented on pull request #774: fix: delete the cluster object when give up the leadership

2021-11-29 Thread GitBox


gxthrj commented on pull request #774:
URL: 
https://github.com/apache/apisix-ingress-controller/pull/774#issuecomment-982258373


   > > better to add e2e for this feature.
   > 
   > First of all, this is not a feature, indeed it's a bugfix, also, it's 
tough to add cases for it.
   
   I think the bugfix also need e2e test , You can restart the APISIX pod 
during the test, and then check the behavior of the Ingress controller.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] bisakhmondal commented on a change in pull request #5594: feat(plugins): aws lambda serverless

2021-11-29 Thread GitBox


bisakhmondal commented on a change in pull request #5594:
URL: https://github.com/apache/apisix/pull/5594#discussion_r758909397



##
File path: t/plugin/aws-lambda.t
##
@@ -0,0 +1,299 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+use t::APISIX 'no_plan';
+
+repeat_each(1);
+no_long_string();
+no_root_location();
+no_shuffle();
+
+add_block_preprocessor(sub {
+my ($block) = @_;
+
+my $inside_lua_block = $block->inside_lua_block // "";
+chomp($inside_lua_block);
+my $http_config = $block->http_config // <<_EOC_;
+
+server {
+listen 8765;
+
+location /httptrigger {
+content_by_lua_block {
+ngx.req.read_body()
+local msg = "aws lambda invoked"
+ngx.header['Content-Length'] = #msg + 1
+ngx.header['Connection'] = "Keep-Alive"
+ngx.say(msg)
+}
+}
+
+location /generic {
+content_by_lua_block {
+$inside_lua_block
+}
+}
+}
+_EOC_
+
+$block->set_value("http_config", $http_config);
+
+if (!$block->request) {
+$block->set_value("request", "GET /t");
+}
+if (!$block->no_error_log && !$block->error_log) {
+$block->set_value("no_error_log", "[error]\n[alert]");
+}
+});
+
+run_tests;
+
+__DATA__
+
+=== TEST 1: checking iam schema
+--- config
+location /t {
+content_by_lua_block {
+local plugin = require("apisix.plugins.aws-lambda")
+local ok, err = plugin.check_schema({
+function_uri = "https://api.amazonaws.com";,
+authorization = {
+iam = {
+accesskey = "key1",
+secretkey = "key2"
+}
+}
+})
+if not ok then
+ngx.say(err)
+else
+ngx.say("done")
+end
+}
+}
+--- response_body
+done
+
+
+
+=== TEST 2: missing fields in iam schema
+--- config
+location /t {
+content_by_lua_block {
+local plugin = require("apisix.plugins.aws-lambda")
+local ok, err = plugin.check_schema({
+function_uri = "https://api.amazonaws.com";,
+authorization = {
+iam = {
+secretkey = "key2"
+}
+}
+})
+if not ok then
+ngx.say(err)
+else
+ngx.say("done")
+end
+}
+}
+--- response_body
+property "authorization" validation failed: property "iam" validation failed: 
property "accesskey" is required
+
+
+
+=== TEST 3: create route with aws plugin enabled
+--- config
+location /t {
+content_by_lua_block {
+local t = require("lib.test_admin").test
+
+local code, body = t('/apisix/admin/routes/1',
+ ngx.HTTP_PUT,
+ [[{
+"plugins": {
+"aws-lambda": {
+"function_uri": 
"http://localhost:8765/httptrigger";,
+"authorization": {
+"apikey" : "testkey"
+}
+}
+},
+"uri": "/aws"
+}]],
+[[{
+"node": {
+"value": {
+"plugins": {
+"aws-lambda": {
+"keepalive": true,
+"timeout": 3000,
+"ssl_verify": true,
+"keepalive_timeout": 6,
+"keepalive_pool": 5,
+"function_uri": 
"http://localhost:8765/httptrigger";,
+"authorization": {
+"apikey": "testkey"
+}
+}
+

[GitHub] [apisix] bisakhmondal commented on a change in pull request #5594: feat(plugins): aws lambda serverless

2021-11-29 Thread GitBox


bisakhmondal commented on a change in pull request #5594:
URL: https://github.com/apache/apisix/pull/5594#discussion_r758908789



##
File path: docs/en/latest/plugins/aws-lambda.md
##
@@ -0,0 +1,156 @@
+---
+title: aws-lambda
+---
+
+
+
+## Summary
+
+- [Summary](#summary)
+- [Name](#name)
+- [Attributes](#attributes)
+  - [IAM Authorization Schema](#iam-authorization-schema)
+- [How To Enable](#how-to-enable)
+- [Disable Plugin](#disable-plugin)
+
+## Name
+
+`aws-lambda` is a serverless plugin built into Apache APISIX for seamless 
integration with [AWS Lambda](https://aws.amazon.com/lambda/), a widely used 
serverless solution, as a dynamic upstream to proxy all requests for a 
particular URI to the AWS cloud - one of the highly used public cloud platforms 
for production environment. If enabled, this plugin terminates the ongoing 
request to that particular URI and initiates a new request to the aws lambda 
gateway uri (the new upstream) on behalf of the client with the suitable 
authorization details set by the users, request headers, request body, params ( 
all these three components are passed from the original request ) and returns 
the response body, status code and the headers back to the original client that 
has invoked the request to the APISIX agent.
+At present, the plugin supports authorization via aws api key and aws IAM 
Secrets.
+
+## Attributes
+
+| Name | Type   | Requirement  | Default  | Valid   | 
Description 
   |
+| ---  | -- | ---  | ---  | -   | 

   |
+| function_uri  | string | required|  |   | The aws api 
gateway endpoint which triggers the lambda serverless function code.   |
+| authorization   | object | optional| | |  Authorization 
credentials to access the cloud function.   
  |
+| authorization.apikey | string | optional| | | Field 
inside _authorization_. The generate API Key to authorize requests to that 
endpoint of the aws gateway. | |
+| authorization.iam | object | optional| | | Field inside 
_authorization_. AWS IAM role based authorization, performed via aws v4 request 
signing. See schema details below ([here](#iam-authorization-schema)). |
 |
+| timeout  | integer | optional| 3000   | [100,...] | Proxy 
request timeout in milliseconds.   |
+| ssl_verify  | boolean | optional| true   | true/false | If 
enabled performs SSL verification of the server. |
+| keepalive  | boolean | optional| true   | true/false | To 
reuse the same proxy connection in near future. Set to false to disable 
keepalives and immediately close the connection.|
+| keepalive_pool  | integer | optional| 5  | [1,...] | The 
maximum number of connections in the pool.  |
+| keepalive_timeout  | integer | optional| 6   | [1000,...]
 |  The maximal idle timeout (ms). |
+
+### IAM Authorization Schema
+
+| Name | Type   | Requirement  | Default| Valid   | 
Description 
   |
+| ---  | -- | ---  | ---| -   | 

   |
+| accesskey| string | required || | 
Genereated  access key ID from aws IAM console. 
   |
+| secret_key   | string | required || | 
Genereated access key secret from aws IAM console.  
   |
+| aws_region   | string | optional | "us-east-1"| | 
The aws region where the request is being sent. 
   |
+| service  | string | optional | "execute-api"  | | 
The service that is receiving the request (In case of Http Trigger it is 
"execute-api").   |
+
+## How To Enable
+
+The following is an example of how to enable the aws-lambda faas plugin for a 
specific route URI. Calling the APISIX route uri will make an invocation to the 
lambda function uri (the new upstream).  We are assuming your cloud function is 
already up and running.
+
+```shell
+# enable aws lambda for a route via api key authorization
+curl http://127.0.0.1:9080/apisix/admin/routes/1 -H 'X-API-KEY: 
edd1c9f034335f136f87ad84b625c8f1' -X PUT -d '
+{
+"plugins": {
+"aws-lambda": {
+"function_uri": 
"https://x9w6z07gb9.execute-api.us-east-1.amazonaws.com/default/test-apisix";,
+ 

[GitHub] [apisix] bisakhmondal commented on a change in pull request #5594: feat(plugins): aws lambda serverless

2021-11-29 Thread GitBox


bisakhmondal commented on a change in pull request #5594:
URL: https://github.com/apache/apisix/pull/5594#discussion_r758908633



##
File path: docs/en/latest/plugins/aws-lambda.md
##
@@ -0,0 +1,156 @@
+---
+title: aws-lambda
+---
+
+
+
+## Summary
+
+- [Summary](#summary)
+- [Name](#name)
+- [Attributes](#attributes)
+  - [IAM Authorization Schema](#iam-authorization-schema)
+- [How To Enable](#how-to-enable)
+- [Disable Plugin](#disable-plugin)
+
+## Name
+
+`aws-lambda` is a serverless plugin built into Apache APISIX for seamless 
integration with [AWS Lambda](https://aws.amazon.com/lambda/), a widely used 
serverless solution, as a dynamic upstream to proxy all requests for a 
particular URI to the AWS cloud - one of the highly used public cloud platforms 
for production environment. If enabled, this plugin terminates the ongoing 
request to that particular URI and initiates a new request to the aws lambda 
gateway uri (the new upstream) on behalf of the client with the suitable 
authorization details set by the users, request headers, request body, params ( 
all these three components are passed from the original request ) and returns 
the response body, status code and the headers back to the original client that 
has invoked the request to the APISIX agent.
+At present, the plugin supports authorization via aws api key and aws IAM 
Secrets.
+
+## Attributes
+
+| Name | Type   | Requirement  | Default  | Valid   | 
Description 
   |
+| ---  | -- | ---  | ---  | -   | 

   |
+| function_uri  | string | required|  |   | The aws api 
gateway endpoint which triggers the lambda serverless function code.   |
+| authorization   | object | optional| | |  Authorization 
credentials to access the cloud function.   
  |
+| authorization.apikey | string | optional| | | Field 
inside _authorization_. The generate API Key to authorize requests to that 
endpoint of the aws gateway. | |
+| authorization.iam | object | optional| | | Field inside 
_authorization_. AWS IAM role based authorization, performed via aws v4 request 
signing. See schema details below ([here](#iam-authorization-schema)). |
 |
+| timeout  | integer | optional| 3000   | [100,...] | Proxy 
request timeout in milliseconds.   |
+| ssl_verify  | boolean | optional| true   | true/false | If 
enabled performs SSL verification of the server. |
+| keepalive  | boolean | optional| true   | true/false | To 
reuse the same proxy connection in near future. Set to false to disable 
keepalives and immediately close the connection.|
+| keepalive_pool  | integer | optional| 5  | [1,...] | The 
maximum number of connections in the pool.  |
+| keepalive_timeout  | integer | optional| 6   | [1000,...]
 |  The maximal idle timeout (ms). |
+
+### IAM Authorization Schema
+
+| Name | Type   | Requirement  | Default| Valid   | 
Description 
   |
+| ---  | -- | ---  | ---| -   | 

   |
+| accesskey| string | required || | 
Genereated  access key ID from aws IAM console. 
   |
+| secret_key   | string | required || | 
Genereated access key secret from aws IAM console.  
   |
+| aws_region   | string | optional | "us-east-1"| | 
The aws region where the request is being sent. 
   |
+| service  | string | optional | "execute-api"  | | 
The service that is receiving the request (In case of Http Trigger it is 
"execute-api").   |
+
+## How To Enable
+
+The following is an example of how to enable the aws-lambda faas plugin for a 
specific route URI. Calling the APISIX route uri will make an invocation to the 
lambda function uri (the new upstream).  We are assuming your cloud function is 
already up and running.
+
+```shell
+# enable aws lambda for a route via api key authorization
+curl http://127.0.0.1:9080/apisix/admin/routes/1 -H 'X-API-KEY: 
edd1c9f034335f136f87ad84b625c8f1' -X PUT -d '
+{
+"plugins": {
+"aws-lambda": {
+"function_uri": 
"https://x9w6z07gb9.execute-api.us-east-1.amazonaws.com/default/test-apisix";,
+ 

[apisix-website] branch master updated: docs: update README with Slack banner (#757)

2021-11-29 Thread sunyi
This is an automated email from the ASF dual-hosted git repository.

sunyi pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/apisix-website.git


The following commit(s) were added to refs/heads/master by this push:
 new 62340e2  docs: update README with Slack banner (#757)
62340e2 is described below

commit 62340e23220fd3b39d54e01d06d53039f7041a63
Author: 琚致远 
AuthorDate: Tue Nov 30 11:40:05 2021 +0800

docs: update README with Slack banner (#757)
---
 README.md | 5 -
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/README.md b/README.md
index 31d5809..95d6fd8 100644
--- a/README.md
+++ b/README.md
@@ -1,6 +1,9 @@
+
 # Apache APISIX® Website
 
-The website of [Apache APISIX®](https://github.com/apache/apisix), a 
cloud-native microservices api gateway.
+[https://firstcontributions.github.io/assets/Readme/join-slack-team.png";>](https://apisix.apache.org/docs/general/community)
+
+The website of [Apache APISIX®](https://apisix.apache.org/), a cloud-native 
microservices api gateway.
 
 ## Usage
 


[GitHub] [apisix-website] LiteSun merged pull request #757: docs: update README with Slack banner

2021-11-29 Thread GitBox


LiteSun merged pull request #757:
URL: https://github.com/apache/apisix-website/pull/757


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-ingress-controller] xianshun163 opened a new issue #776: request help: Can I use admin api to define some rule, and use the upstream the crd defiled?

2021-11-29 Thread GitBox


xianshun163 opened a new issue #776:
URL: https://github.com/apache/apisix-ingress-controller/issues/776


   ### Issue description
   I  deploy the apisix as a deployment in the k8s, and use the 
apisix-ingress-controller  ​CRDS  to define some default  rule  for the service.
   
   
   I have two  questions:
   
   1、 I   want  todefile  some   complex  ​rules  can  I use  the  admin 
api  to  defile some other rule, and the rule may use the upstream id  ,which 
is create  by the  apisix-ingress-controller?
   
   2、I have some  other app, they do not deploy in the k8s,  can  I  use  admin 
api to  defile some rule for them?
   
   
   ### Environment
   
   * your apisix-ingress-controller version (output of 
`apisix-ingress-controller version --long`);1.0.0
   * your Kubernetes cluster version (output of `kubectl version`);1.19.3
   * if you run apisix-ingress-controller in Bare-metal environment, also show 
your OS version (`uname -a`).
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] bisakhmondal commented on a change in pull request #5641: docs: minor update in azure faas http2 documentation

2021-11-29 Thread GitBox


bisakhmondal commented on a change in pull request #5641:
URL: https://github.com/apache/apisix/pull/5641#discussion_r758905790



##
File path: docs/en/latest/plugins/azure-functions.md
##
@@ -104,20 +104,20 @@ Request-Context: 
appId=cid-v1:38aae829-293b-43c2-82c6-fa94aec0a071
 Date: Wed, 17 Nov 2021 14:46:55 GMT
 Server: APISIX/2.10.2
 
-Hello, apisix
+Hello, APISIX
 ```
 
-For requests where the mode of communication between the client and the Apache 
APISIX gateway is HTTP/2, the example looks like ( make sure you are running 
APISIX agent with `enable_http2: true` for a port in conf.yaml or uncomment 
port 9081 of `node_listen` field inside 
[config-default.yaml](../../../../conf/config-default.yaml) ) :
+For requests where the mode of communication between the client and the Apache 
APISIX gateway is HTTP/2, the example looks like ( make sure you are running 
APISIX agent with `enable_http2: true` for a port in 
[config-default.yaml](../../../../conf/config-default.yaml). You can do it by 
uncommenting the port 9081 from `apisix.node_listen` field ) :

Review comment:
   I see, I guess It's because of the relative path URL. Updated




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] kevinw66 commented on issue #5626: bug: attempt to concatenate field 'shm_name' (a nil value)

2021-11-29 Thread GitBox


kevinw66 commented on issue #5626:
URL: https://github.com/apache/apisix/issues/5626#issuecomment-982234001


   After I re-run make deps, the lua-resty-etcd version is upgrade from 1.5.4 
to 1.6.0 and this problem disappear.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] kevinw66 closed issue #5626: bug: attempt to concatenate field 'shm_name' (a nil value)

2021-11-29 Thread GitBox


kevinw66 closed issue #5626:
URL: https://github.com/apache/apisix/issues/5626


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-dashboard] bzp2010 commented on pull request #2226: fix: plugin_configs should store with etcd prefix

2021-11-29 Thread GitBox


bzp2010 commented on pull request #2226:
URL: https://github.com/apache/apisix-dashboard/pull/2226#issuecomment-982233792


   LGTM, just wait the CI passed.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-dashboard] codecov-commenter commented on pull request #2226: fix: plugin_configs should store with etcd prefix

2021-11-29 Thread GitBox


codecov-commenter commented on pull request #2226:
URL: https://github.com/apache/apisix-dashboard/pull/2226#issuecomment-982233726


   # 
[Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2226?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 Report
   > Merging 
[#2226](https://codecov.io/gh/apache/apisix-dashboard/pull/2226?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (ad710f8) into 
[master](https://codecov.io/gh/apache/apisix-dashboard/commit/a55568408cec5eb2628971d2098a9bef992ff548?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (a555684) will **decrease** coverage by `13.26%`.
   > The diff coverage is `0.00%`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/apisix-dashboard/pull/2226/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/apisix-dashboard/pull/2226?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@ Coverage Diff @@
   ##   master#2226   +/-   ##
   ===
   - Coverage   62.43%   49.16%   -13.27% 
   ===
 Files  57   41   -16 
 Lines3905 3171  -734 
   ===
   - Hits 2438 1559  -879 
   - Misses   1185 1412  +227 
   + Partials  282  200   -82 
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | backend-e2e-test | `?` | |
   | backend-unit-test | `49.16% <0.00%> (+0.03%)` | :arrow_up: |
   
   Flags with carried forward coverage won't be shown. [Click 
here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment)
 to find out more.
   
   | [Impacted 
Files](https://codecov.io/gh/apache/apisix-dashboard/pull/2226?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 | Coverage Δ | |
   |---|---|---|
   | 
[api/internal/core/store/storehub.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2226/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvc3RvcmVodWIuZ28=)
 | `0.00% <0.00%> (-55.56%)` | :arrow_down: |
   | 
[api/main.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2226/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL21haW4uZ28=)
 | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | 
[api/internal/utils/version.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2226/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL3V0aWxzL3ZlcnNpb24uZ28=)
 | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | 
[api/internal/filter/request\_id.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2226/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2ZpbHRlci9yZXF1ZXN0X2lkLmdv)
 | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | 
[api/internal/filter/cors.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2226/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2ZpbHRlci9jb3JzLmdv)
 | `0.00% <0.00%> (-70.00%)` | :arrow_down: |
   | 
[api/internal/core/entity/entity.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2226/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L2VudGl0eS5nbw==)
 | `0.00% <0.00%> (-68.19%)` | :arrow_down: |
   | 
[api/internal/utils/closer.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2226/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL3V0aWxzL2Nsb3Nlci5nbw==)
 | `0.00% <0.00%> (-66.67%)` | :arrow_down: |
   | 
[api/internal/utils/consts/api\_error.go](https://codecov.

[GitHub] [apisix] MizuhaHimuraki commented on a change in pull request #5640: feat: report error when use etcd client cert auth

2021-11-29 Thread GitBox


MizuhaHimuraki commented on a change in pull request #5640:
URL: https://github.com/apache/apisix/pull/5640#discussion_r75778



##
File path: apisix/cli/etcd.lua
##
@@ -347,6 +347,11 @@ function _M.init(env, args)
 util.die(errmsg)
 end
 
+if res_put:find("CommonName of client sending a request against 
gateway", 1, true) then
+errmsg = str_format("etcd client cert auth cannot be used with 
gRPC-gateway\n")

Review comment:
   done




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] kevinw66 commented on issue #5626: bug: attempt to concatenate field 'shm_name' (a nil value)

2021-11-29 Thread GitBox


kevinw66 commented on issue #5626:
URL: https://github.com/apache/apisix/issues/5626#issuecomment-982225198


   but this can work correctly on branch release/2.11, I'm confused


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-website] wang-yeliang commented on pull request #776: docs: add contribution guidelines

2021-11-29 Thread GitBox


wang-yeliang commented on pull request #776:
URL: https://github.com/apache/apisix-website/pull/776#issuecomment-982223851


   For the first time, there is a detailed guide for blogs, and other types of 
contribution guides can be derived later.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] LiteSun commented on a change in pull request #5595: feat: add gen-vote-content script

2021-11-29 Thread GitBox


LiteSun commented on a change in pull request #5595:
URL: https://github.com/apache/apisix/pull/5595#discussion_r758884633



##
File path: utils/gen-vote-contents.sh
##
@@ -0,0 +1,92 @@
+#!/bin/sh
+
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+VERSION=$1
+
+SUBSTRING1=$(echo $VERSION| cut -d'.' -f 1)
+SUBSTRING2=$(echo $VERSION| cut -d'.' -f 2)
+BLOB_VERSION=$SUBSTRING1.$SUBSTRING2
+
+read -p "Please enter release note pr: " RELEASE_NOTE_PR
+read -p "Please enter release commit id: " COMMIT_ID
+
+vote_contents=$(cat <

[GitHub] [apisix] kevinw66 edited a comment on issue #5626: bug: attempt to concatenate field 'shm_name' (a nil value)

2021-11-29 Thread GitBox


kevinw66 edited a comment on issue #5626:
URL: https://github.com/apache/apisix/issues/5626#issuecomment-982221673


   @shuaijinchao 
   Environment
   apisix version:master branch
   OS:Darwin wuzhiguodeMacBook-Pro.local 20.6.0 Darwin Kernel Version 20.6.0: 
Mon Aug 30 06:12:21 PDT 2021; root:xnu-7195.141.6~3/RELEASE_X86_64 x86_64
   OpenResty / Nginx version:nginx version: openresty/1.19.9.1
   etcd version:3.5.0
   luarocks version, if the issue is about installation:3.8.0


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] zhangweidongyyl opened a new issue #5643: request help: body_filter how to send request in apisix

2021-11-29 Thread GitBox


zhangweidongyyl opened a new issue #5643:
URL: https://github.com/apache/apisix/issues/5643


   ### Issue description
   
   i want send request in body_filter,based on last request returned Status to 
send different req
   
   
   
   ### Environment
   
   - apisix version (cmd: `apisix version`):
   - OS (cmd: `uname -a`):
   - OpenResty / Nginx version (cmd: `nginx -V` or `openresty -V`):
   - etcd version, if have (cmd: run `curl 
http://127.0.0.1:9090/v1/server_info` to get the info from server-info API):
   - apisix-dashboard version, if have:
   - the plugin runner version, if the issue is about a plugin runner (cmd: 
depended on the kind of runner):
   - luarocks version, if the issue is about installation (cmd: `luarocks 
--version`):
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] kevinw66 commented on issue #5626: bug: attempt to concatenate field 'shm_name' (a nil value)

2021-11-29 Thread GitBox


kevinw66 commented on issue #5626:
URL: https://github.com/apache/apisix/issues/5626#issuecomment-98228


   
![image](https://user-images.githubusercontent.com/31196226/143975036-fbb6a5fe-23a5-4dee-80f0-208857ceeb0f.png)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-website] juzhiyuan commented on a change in pull request #776: docs: add contribution guidelines

2021-11-29 Thread GitBox


juzhiyuan commented on a change in pull request #776:
URL: https://github.com/apache/apisix-website/pull/776#discussion_r758878114



##
File path: website/docs/general/blog-contributing-guide.md
##
@@ -0,0 +1,353 @@
+---
+id: blog
+title: Blog Contributing Guide
+keywords:
+- API gateway
+- APISIX
+- Apache APISIX
+- blog guide
+description: This article is a set of guidelines for contributors who want to 
write blogs. This guideline will teach you how to contribute if you want to add 
a new blog, or modify existing blog contents.
+---
+
+## Overview
+
+This guideline will teach you how to contribute if you want to add a new blog, 
or modify existing blog contents.
+
+If you find an issue on current documents, please feel free to [file an 
issue](https://github.com/apache/apisix-website/issues/new) and let the 
community know about it, or you can [sumbit a pull 
request](https://github.com/apache/apisix-website/pulls) to fix or update. Both 
actions are welcome and recommended.
+
+The blogs are written in two languages: English and Chinese. We encourage 
contributors to add blogs in their preferred language. It is completely up to 
you. We can handle translations and ask you to do a pull request review later.
+
+English blogs are located in the `website/blog` directory, in which they are 
categorized by year, month and date. For example, 
`website/blog/2021/11/22/develop-apisix-ingress-with-nocalhost-in-kubernetes.md`
 means that a blog named 
`develop-apisix-ingress-with-nocalhost-in-kubernetes.md` was published on 
November 22nd, 2021, and it is located in the `website/blog/2021/11/22 
directory`.
+
+Similarly, Chinese blogs are located in 
`website/i18n/zh/docusaurus-plugin-content-blog` directory and follow the same 
rules described above.
+
+## What you can contribute
+
+We encourge contributors and users to write blogs about Apache APISIX and 
publish them on the website. As long as blogs fit in the catogories listed 
below:
+
+- **User Case**: User Case, this is also very straightforward. Please tell us 
how you use Apache APISIX and your feelings about Apache APISIX.
+- **Practical Case**: Best practices, easily confused with Technology. The 
factors that determine whether an article is a Technology or a Practical Case 
are: the content of the article and the subject of the description. For 
example, if the article is about "Running Apache APISIX on xxx platform", then 
it is a Practical Case; for example, if the article is about technical stuff, 
"Apache APISIX v.s. Envoy", then it is Technology.
+- **Technology**: Technical articles, easily confused with Practical Case. The 
factors that determine whether an article is a Technology or a Practical Case 
are: the content of the article and the subject of the description. For 
example, if the article is about "Running Apache APISIX on xxx platform", then 
it is a Practical Case; for example, if the article is about technical stuff, 
"Apache APISIX v.s. Envoy", then it is Technology.
+- **Community**: community related, e.g. "How to contribute to an open source 
project without writing code?"
+- **Security**: Security vulnerability notification and methods to bypass 
security vulnerabilities, currently there are only two articles, very good to 
identify, generally have CVE-xxx is it.
+

Review comment:
   We could help authors to use a better Category once a PR is submitted 😄

##
File path: website/docs/general/blog-contributing-guide.md
##
@@ -0,0 +1,353 @@
+---
+id: blog
+title: Blog Contributing Guide
+keywords:
+- API gateway
+- APISIX
+- Apache APISIX
+- blog guide
+description: This article is a set of guidelines for contributors who want to 
write blogs. This guideline will teach you how to contribute if you want to add 
a new blog, or modify existing blog contents.
+---
+
+## Overview
+
+This guideline will teach you how to contribute if you want to add a new blog, 
or modify existing blog contents.
+
+If you find an issue on current documents, please feel free to [file an 
issue](https://github.com/apache/apisix-website/issues/new) and let the 
community know about it, or you can [sumbit a pull 
request](https://github.com/apache/apisix-website/pulls) to fix or update. Both 
actions are welcome and recommended.
+
+The blogs are written in two languages: English and Chinese. We encourage 
contributors to add blogs in their preferred language. It is completely up to 
you. We can handle translations and ask you to do a pull request review later.
+
+English blogs are located in the `website/blog` directory, in which they are 
categorized by year, month and date. For example, 
`website/blog/2021/11/22/develop-apisix-ingress-with-nocalhost-in-kubernetes.md`
 means that a blog named 
`develop-apisix-ingress-with-nocalhost-in-kubernetes.md` was published on 
November 22nd, 2021, and it is located in the `website/blog/2021/11/22 
directory`.
+
+Similarly, Chinese blogs are located in 
`website/i18n/zh/docusa

[GitHub] [apisix] kevinw66 commented on issue #5626: bug: attempt to concatenate field 'shm_name' (a nil value)

2021-11-29 Thread GitBox


kevinw66 commented on issue #5626:
URL: https://github.com/apache/apisix/issues/5626#issuecomment-982221673


   Environment
   apisix version:master branch
   OS:Darwin wuzhiguodeMacBook-Pro.local 20.6.0 Darwin Kernel Version 20.6.0: 
Mon Aug 30 06:12:21 PDT 2021; root:xnu-7195.141.6~3/RELEASE_X86_64 x86_64
   OpenResty / Nginx version:nginx version: openresty/1.19.9.1
   etcd version:3.5.0
   luarocks version, if the issue is about installation:3.8.0


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] tzssangglass commented on a change in pull request #5594: feat(plugins): aws lambda serverless

2021-11-29 Thread GitBox


tzssangglass commented on a change in pull request #5594:
URL: https://github.com/apache/apisix/pull/5594#discussion_r758881212



##
File path: apisix/plugins/aws-lambda.lua
##
@@ -0,0 +1,183 @@
+--
+-- Licensed to the Apache Software Foundation (ASF) under one or more
+-- contributor license agreements.  See the NOTICE file distributed with
+-- this work for additional information regarding copyright ownership.
+-- The ASF licenses this file to You under the Apache License, Version 2.0
+-- (the "License"); you may not use this file except in compliance with
+-- the License.  You may obtain a copy of the License at
+--
+-- http://www.apache.org/licenses/LICENSE-2.0
+--
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+
+local ngx = ngx
+local hmac = require("resty.hmac")
+local hex_encode = require("resty.string").to_hex
+local resty_sha256 = require("resty.sha256")
+local str_strip = require("pl.stringx").strip
+local norm_path = require("pl.path").normpath
+local pairs = pairs
+local tab_concat = table.concat
+local tab_sort = table.sort
+local os = os
+
+
+local plugin_name = "aws-lambda"
+local plugin_version = 0.1
+local priority = -1899
+
+local ALGO = "AWS4-HMAC-SHA256"
+
+local function hmac256(key, msg)
+return hmac:new(key, hmac.ALGOS.SHA256):final(msg)
+end
+
+local function sha256(msg)
+local hash = resty_sha256:new()
+hash:update(msg)
+local digest = hash:final()
+return hex_encode(digest)
+end
+
+local function get_signature_key(key, datestamp, region, service)
+local kDate = hmac256("AWS4" .. key, datestamp)
+local kRegion = hmac256(kDate, region)
+local kService = hmac256(kRegion, service)
+local kSigning = hmac256(kService, "aws4_request")
+return kSigning
+end
+
+local aws_authz_schema = {
+type = "object",
+properties = {
+-- API Key based authorization
+apikey = {type = "string"},
+-- IAM role based authorization, works via aws v4 request signing
+-- more at 
https://docs.aws.amazon.com/general/latest/gr/sigv4_signing.html
+iam = {
+type = "object",
+properties = {
+accesskey = {
+type = "string",
+description = "access key id from from aws iam console"
+},
+secretkey = {
+type = "string",
+description = "secret access key from from aws iam console"
+},
+aws_region = {
+type = "string",
+default = "us-east-1",
+description = "the aws region that is receiving the 
request"
+},
+service = {
+type = "string",
+default = "execute-api",
+description = "the service that is receiving the request"
+}
+},
+required = {"accesskey", "secretkey"}
+}
+}
+}
+
+local function request_processor(conf, ctx, params)
+local headers = params.headers
+-- set authorization headers if not already set by the client
+-- we are following not to overwrite the authz keys
+if not headers["x-api-key"] then
+if conf.authorization and conf.authorization.apikey then
+headers["x-api-key"] = conf.authorization.apikey
+return
+end
+end
+
+-- performing aws v4 request signing for IAM authorization
+-- visit 
https://docs.aws.amazon.com/general/latest/gr/sigv4-signed-request-examples.html
+-- to look at the pseudocode in python.
+if headers["authorization"] or not conf.authorization or not 
conf.authorization.iam then
+return
+end
+
+-- create a date for headers and the credential string
+local t = ngx.time()
+local amzdate =  os.date("!%Y%m%dT%H%M%SZ", t)
+local datestamp = os.date("!%Y%m%d", t) -- Date w/o time, used in 
credential scope
+headers["X-Amz-Date"] = amzdate
+
+-- computing canonical uri
+local canonical_uri = norm_path(params.path)
+if canonical_uri ~= "/" then
+if canonical_uri:sub(-1, -1) == "/" then
+canonical_uri = canonical_uri:sub(1, -2)
+end
+if canonical_uri:sub(1, 1) ~= "/" then
+canonical_uri = "/" .. canonical_uri
+end
+end
+
+-- computing canonical query string
+local canonical_qs = {}
+for k, v in pairs(params.query) do
+canonical_qs[#canonical_qs+1] = ngx.unescape_uri(k) .. "=" .. 
ngx.unescape_uri(v)
+end
+
+tab_sort(canonical_qs)
+canonical_qs = tab_concat(canonical_qs, "&")
+
+-- computing canonical and signed headers
+

[GitHub] [apisix] xianshun163 commented on issue #5607: bug: traffic-split err

2021-11-29 Thread GitBox


xianshun163 commented on issue #5607:
URL: https://github.com/apache/apisix/issues/5607#issuecomment-982219109


   the upstreamid  are exist, they  are  create by the apisix  auto.
   
   I can't reproduce the  issue now, 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[apisix-dashboard] branch master updated (a555684 -> b788ab3)

2021-11-29 Thread juzhiyuan
This is an automated email from the ASF dual-hosted git repository.

juzhiyuan pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/apisix-dashboard.git.


from a555684  test: migrate global rule e2e (#2202)
 add b788ab3  fix: migrate testcase CI crash (#2228)

No new revisions were added by this update.

Summary of changes:
 api/test/e2enew/migrate/migrate_test.go | 235 ++--
 1 file changed, 129 insertions(+), 106 deletions(-)


[apisix-docker] branch release/apisix-2.11.0 created (now 2031794)

2021-11-29 Thread sunyi
This is an automated email from the ASF dual-hosted git repository.

sunyi pushed a change to branch release/apisix-2.11.0
in repository https://gitbox.apache.org/repos/asf/apisix-docker.git.


  at 2031794  feat: upgrade APISIX to 2.11.0 (#250)

No new revisions were added by this update.


[apisix-docker] branch master updated (369f084 -> 2031794)

2021-11-29 Thread spacewander
This is an automated email from the ASF dual-hosted git repository.

spacewander pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/apisix-docker.git.


from 369f084  fix: all-in-one docker image build error (#249)
 add 2031794  feat: upgrade APISIX to 2.11.0 (#250)

No new revisions were added by this update.

Summary of changes:
 .github/workflows/apisix-docker-test.yaml | 2 +-
 Makefile  | 2 +-
 alpine/Dockerfile | 2 +-
 centos/Dockerfile | 2 +-
 4 files changed, 4 insertions(+), 4 deletions(-)


[GitHub] [apisix-website] juzhiyuan commented on a change in pull request #776: docs: add contribution guidelines

2021-11-29 Thread GitBox


juzhiyuan commented on a change in pull request #776:
URL: https://github.com/apache/apisix-website/pull/776#discussion_r758876911



##
File path: website/docs/general/blog-contributing-guide.md
##
@@ -0,0 +1,353 @@
+---
+id: blog
+title: Blog Contributing Guide
+keywords:
+- API gateway
+- APISIX
+- Apache APISIX
+- blog guide
+description: This article is a set of guidelines for contributors who want to 
write blogs. This guideline will teach you how to contribute if you want to add 
a new blog, or modify existing blog contents.
+---
+
+## Overview
+
+This guideline will teach you how to contribute if you want to add a new blog, 
or modify existing blog contents.
+
+If you find an issue on current documents, please feel free to [file an 
issue](https://github.com/apache/apisix-website/issues/new) and let the 
community know about it, or you can [sumbit a pull 
request](https://github.com/apache/apisix-website/pulls) to fix or update. Both 
actions are welcome and recommended.
+
+The blogs are written in two languages: English and Chinese. We encourage 
contributors to add blogs in their preferred language. It is completely up to 
you. We can handle translations and ask you to do a pull request review later.
+
+English blogs are located in the `website/blog` directory, in which they are 
categorized by year, month and date. For example, 
`website/blog/2021/11/22/develop-apisix-ingress-with-nocalhost-in-kubernetes.md`
 means that a blog named 
`develop-apisix-ingress-with-nocalhost-in-kubernetes.md` was published on 
November 22nd, 2021, and it is located in the `website/blog/2021/11/22 
directory`.

Review comment:
   Would better add the final URL after it's published 😄

##
File path: website/docs/general/blog-contributing-guide.md
##
@@ -0,0 +1,353 @@
+---
+id: blog
+title: Blog Contributing Guide
+keywords:
+- API gateway
+- APISIX
+- Apache APISIX
+- blog guide

Review comment:
   😂 Blog guide?

##
File path: website/docs/general/blog-contributing-guide.md
##
@@ -0,0 +1,353 @@
+---
+id: blog
+title: Blog Contributing Guide
+keywords:
+- API gateway
+- APISIX
+- Apache APISIX
+- blog guide
+description: This article is a set of guidelines for contributors who want to 
write blogs. This guideline will teach you how to contribute if you want to add 
a new blog, or modify existing blog contents.
+---
+
+## Overview
+
+This guideline will teach you how to contribute if you want to add a new blog, 
or modify existing blog contents.
+
+If you find an issue on current documents, please feel free to [file an 
issue](https://github.com/apache/apisix-website/issues/new) and let the 
community know about it, or you can [sumbit a pull 
request](https://github.com/apache/apisix-website/pulls) to fix or update. Both 
actions are welcome and recommended.
+
+The blogs are written in two languages: English and Chinese. We encourage 
contributors to add blogs in their preferred language. It is completely up to 
you. We can handle translations and ask you to do a pull request review later.
+
+English blogs are located in the `website/blog` directory, in which they are 
categorized by year, month and date. For example, 
`website/blog/2021/11/22/develop-apisix-ingress-with-nocalhost-in-kubernetes.md`
 means that a blog named 
`develop-apisix-ingress-with-nocalhost-in-kubernetes.md` was published on 
November 22nd, 2021, and it is located in the `website/blog/2021/11/22 
directory`.
+
+Similarly, Chinese blogs are located in 
`website/i18n/zh/docusaurus-plugin-content-blog` directory and follow the same 
rules described above.
+
+## What you can contribute
+
+We encourge contributors and users to write blogs about Apache APISIX and 
publish them on the website. As long as blogs fit in the catogories listed 
below:

Review comment:
   `As long as` is a little limitation IMHO, could we receive other kinds 
of blog contents?

##
File path: website/docs/general/blog-contributing-guide.md
##
@@ -0,0 +1,353 @@
+---
+id: blog
+title: Blog Contributing Guide
+keywords:
+- API gateway
+- APISIX
+- Apache APISIX
+- blog guide

Review comment:
   How about using a keyword more like `how to write blog`?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-ingress-controller] tao12345666333 commented on pull request #774: fix: delete the cluster object when give up the leadership

2021-11-29 Thread GitBox


tao12345666333 commented on pull request #774:
URL: 
https://github.com/apache/apisix-ingress-controller/pull/774#issuecomment-982212833


   Maybe we can introduce chaos test later.
   
   If you want to add tests here,
   We can first set the number of replicas of apisix to 0 to ensure that all ep 
are cleaned up.
   
   We may also need to rely on 
https://github.com/apache/apisix-ingress-controller/pull/770 to confirm that 
the current cluster is not available
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] juzhiyuan commented on a change in pull request #5594: feat(plugins): aws lambda serverless

2021-11-29 Thread GitBox


juzhiyuan commented on a change in pull request #5594:
URL: https://github.com/apache/apisix/pull/5594#discussion_r758873866



##
File path: docs/en/latest/plugins/aws-lambda.md
##
@@ -0,0 +1,156 @@
+---
+title: aws-lambda
+---
+
+
+
+## Summary
+
+- [Summary](#summary)
+- [Name](#name)
+- [Attributes](#attributes)
+  - [IAM Authorization Schema](#iam-authorization-schema)
+- [How To Enable](#how-to-enable)
+- [Disable Plugin](#disable-plugin)
+
+## Name
+
+`aws-lambda` is a serverless plugin built into Apache APISIX for seamless 
integration with [AWS Lambda](https://aws.amazon.com/lambda/), a widely used 
serverless solution, as a dynamic upstream to proxy all requests for a 
particular URI to the AWS cloud - one of the highly used public cloud platforms 
for production environment. If enabled, this plugin terminates the ongoing 
request to that particular URI and initiates a new request to the aws lambda 
gateway uri (the new upstream) on behalf of the client with the suitable 
authorization details set by the users, request headers, request body, params ( 
all these three components are passed from the original request ) and returns 
the response body, status code and the headers back to the original client that 
has invoked the request to the APISIX agent.
+At present, the plugin supports authorization via aws api key and aws IAM 
Secrets.
+
+## Attributes
+
+| Name | Type   | Requirement  | Default  | Valid   | 
Description 
   |
+| ---  | -- | ---  | ---  | -   | 

   |
+| function_uri  | string | required|  |   | The aws api 
gateway endpoint which triggers the lambda serverless function code.   |
+| authorization   | object | optional| | |  Authorization 
credentials to access the cloud function.   
  |
+| authorization.apikey | string | optional| | | Field 
inside _authorization_. The generate API Key to authorize requests to that 
endpoint of the aws gateway. | |
+| authorization.iam | object | optional| | | Field inside 
_authorization_. AWS IAM role based authorization, performed via aws v4 request 
signing. See schema details below ([here](#iam-authorization-schema)). |
 |
+| timeout  | integer | optional| 3000   | [100,...] | Proxy 
request timeout in milliseconds.   |
+| ssl_verify  | boolean | optional| true   | true/false | If 
enabled performs SSL verification of the server. |
+| keepalive  | boolean | optional| true   | true/false | To 
reuse the same proxy connection in near future. Set to false to disable 
keepalives and immediately close the connection.|
+| keepalive_pool  | integer | optional| 5  | [1,...] | The 
maximum number of connections in the pool.  |
+| keepalive_timeout  | integer | optional| 6   | [1000,...]
 |  The maximal idle timeout (ms). |
+
+### IAM Authorization Schema
+
+| Name | Type   | Requirement  | Default| Valid   | 
Description 
   |
+| ---  | -- | ---  | ---| -   | 

   |
+| accesskey| string | required || | 
Genereated  access key ID from aws IAM console. 
   |
+| secret_key   | string | required || | 
Genereated access key secret from aws IAM console.  
   |
+| aws_region   | string | optional | "us-east-1"| | 
The aws region where the request is being sent. 
   |
+| service  | string | optional | "execute-api"  | | 
The service that is receiving the request (In case of Http Trigger it is 
"execute-api").   |
+
+## How To Enable
+
+The following is an example of how to enable the aws-lambda faas plugin for a 
specific route URI. Calling the APISIX route uri will make an invocation to the 
lambda function uri (the new upstream).  We are assuming your cloud function is 
already up and running.
+
+```shell
+# enable aws lambda for a route via api key authorization
+curl http://127.0.0.1:9080/apisix/admin/routes/1 -H 'X-API-KEY: 
edd1c9f034335f136f87ad84b625c8f1' -X PUT -d '
+{
+"plugins": {
+"aws-lambda": {
+"function_uri": 
"https://x9w6z07gb9.execute-api.us-east-1.amazonaws.com/default/test-apisix";,
+

[GitHub] [apisix-ingress-controller] tao12345666333 commented on a change in pull request #774: fix: delete the cluster object when give up the leadership

2021-11-29 Thread GitBox


tao12345666333 commented on a change in pull request #774:
URL: 
https://github.com/apache/apisix-ingress-controller/pull/774#discussion_r758872053



##
File path: tools.go
##
@@ -1,3 +1,4 @@
+//go:build tools

Review comment:
   You haven't pushed the latest code yet?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-ingress-controller] tokers commented on pull request #731: feat: Grafana Dashboard Configuration

2021-11-29 Thread GitBox


tokers commented on pull request #731:
URL: 
https://github.com/apache/apisix-ingress-controller/pull/731#issuecomment-982207316


   > > @Sindweller What does the `cluster health check` value mean?
   > 
   > It increases when 
[checkClusterHealth](https://github.com/apache/apisix-ingress-controller/blob/f4708675c6304ad019881ad7e0ac7a0affd3e6bd/pkg/ingress/controller.go#L642)
 is called to record a successful health check for default cluster.
   
   OK, so what about APISIX Health Check Calls, so that we know the usage of 
this metrics.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-ingress-controller] tokers commented on a change in pull request #774: fix: delete the cluster object when give up the leadership

2021-11-29 Thread GitBox


tokers commented on a change in pull request #774:
URL: 
https://github.com/apache/apisix-ingress-controller/pull/774#discussion_r758871044



##
File path: tools.go
##
@@ -1,3 +1,4 @@
+//go:build tools

Review comment:
   Removed.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-ingress-controller] tokers commented on pull request #774: fix: delete the cluster object when give up the leadership

2021-11-29 Thread GitBox


tokers commented on pull request #774:
URL: 
https://github.com/apache/apisix-ingress-controller/pull/774#issuecomment-982206376


   > better to add e2e for this feature.
   
   First of all, this is not a feature, indeed it's a bugfix, also, it's tough 
to add cases for it.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-dashboard] juzhiyuan merged pull request #2228: fix: migrate testcase CI crash

2021-11-29 Thread GitBox


juzhiyuan merged pull request #2228:
URL: https://github.com/apache/apisix-dashboard/pull/2228


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-dashboard] juzhiyuan closed issue #2227: bug: migrate E2E test in CI fails randomly

2021-11-29 Thread GitBox


juzhiyuan closed issue #2227:
URL: https://github.com/apache/apisix-dashboard/issues/2227


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] tokers commented on a change in pull request #5640: feat: report error when use etcd client cert auth

2021-11-29 Thread GitBox


tokers commented on a change in pull request #5640:
URL: https://github.com/apache/apisix/pull/5640#discussion_r758867173



##
File path: apisix/cli/etcd.lua
##
@@ -347,6 +347,11 @@ function _M.init(env, args)
 util.die(errmsg)
 end
 
+if res_put:find("CommonName of client sending a request against 
gateway", 1, true) then
+errmsg = str_format("etcd client cert auth cannot be used with 
gRPC-gateway\n")

Review comment:
   Also tell users the solution, such as "Please configure the usernamd and 
password in configuration file".




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] tokers commented on issue #5608: request help: apisix cannot connect to etcd when etcd auth enabled

2021-11-29 Thread GitBox


tokers commented on issue #5608:
URL: https://github.com/apache/apisix/issues/5608#issuecomment-982197676


   > > > Note that this feature cannot be used with gRPC-proxy and 
gRPC-gateway. This is because gRPC-proxy terminates TLS from its client so all 
the clients share a cert of the proxy. gRPC-gateway uses a TLS connection 
internally for transforming HTTP request to gRPC request so it shares the same 
limitation
   > > 
   > > 
   > > APISIX uses the gRPC gateway to communicate with ETCD.
   > 
   > OK, this is a limitation of the etcd itself. I will add username and 
password fields in the config file to workaround.
   > 
   > > CommonName of client sending a request against gateway will be ignored 
and not used as expected
   > 
   > I think this error message should be recognized during init_etcd. I spent 
a lot of time analyzing the failure, because the script did not report any 
errors.
   
   PR's welcome! We can enhance from two aspects.
   
   1) Add some comments for the ETCD section configuration;
   2) Optimize the output from ETCD.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] starsz commented on issue #5634: request help: support get the key from function in limit-* plugins

2021-11-29 Thread GitBox


starsz commented on issue #5634:
URL: https://github.com/apache/apisix/issues/5634#issuecomment-982195527


   > What about allowing user to register their var in
   > 
   > 
https://github.com/apache/apisix/blob/8f0b066c86257ad6af19f9b3b7e209ece95d17c9/apisix/core/ctx.lua#L147
   > 
   > ?
   
   I think support function would be more flexible. 
   We can write the function like this: 
   ```
   function generate_key(ctx)
 if ctx.var.http_x_consumer == "a" then
  return "a"
 end
   
 return "default"
   end
   ```
   
   Then we can limit the specific request with a special header.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-docker] spacewander merged pull request #250: feat: upgrade APISIX to 2.11.0

2021-11-29 Thread GitBox


spacewander merged pull request #250:
URL: https://github.com/apache/apisix-docker/pull/250


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-dashboard] bzp2010 commented on pull request #2228: fix: migrate testcase CI crash

2021-11-29 Thread GitBox


bzp2010 commented on pull request #2228:
URL: https://github.com/apache/apisix-dashboard/pull/2228#issuecomment-982187870


   ping @nic-chen  @starsz


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] spacewander commented on a change in pull request #5594: feat(plugins): aws lambda serverless

2021-11-29 Thread GitBox


spacewander commented on a change in pull request #5594:
URL: https://github.com/apache/apisix/pull/5594#discussion_r758852167



##
File path: docs/en/latest/plugins/aws-lambda.md
##
@@ -0,0 +1,156 @@
+---
+title: aws-lambda
+---
+
+
+
+## Summary
+
+- [Summary](#summary)
+- [Name](#name)
+- [Attributes](#attributes)
+  - [IAM Authorization Schema](#iam-authorization-schema)
+- [How To Enable](#how-to-enable)
+- [Disable Plugin](#disable-plugin)
+
+## Name
+
+`aws-lambda` is a serverless plugin built into Apache APISIX for seamless 
integration with [AWS Lambda](https://aws.amazon.com/lambda/), a widely used 
serverless solution, as a dynamic upstream to proxy all requests for a 
particular URI to the AWS cloud - one of the highly used public cloud platforms 
for production environment. If enabled, this plugin terminates the ongoing 
request to that particular URI and initiates a new request to the aws lambda 
gateway uri (the new upstream) on behalf of the client with the suitable 
authorization details set by the users, request headers, request body, params ( 
all these three components are passed from the original request ) and returns 
the response body, status code and the headers back to the original client that 
has invoked the request to the APISIX agent.
+At present, the plugin supports authorization via aws api key and aws IAM 
Secrets.
+
+## Attributes
+
+| Name | Type   | Requirement  | Default  | Valid   | 
Description 
   |
+| ---  | -- | ---  | ---  | -   | 

   |
+| function_uri  | string | required|  |   | The aws api 
gateway endpoint which triggers the lambda serverless function code.   |
+| authorization   | object | optional| | |  Authorization 
credentials to access the cloud function.   
  |
+| authorization.apikey | string | optional| | | Field 
inside _authorization_. The generate API Key to authorize requests to that 
endpoint of the aws gateway. | |
+| authorization.iam | object | optional| | | Field inside 
_authorization_. AWS IAM role based authorization, performed via aws v4 request 
signing. See schema details below ([here](#iam-authorization-schema)). |
 |
+| timeout  | integer | optional| 3000   | [100,...] | Proxy 
request timeout in milliseconds.   |
+| ssl_verify  | boolean | optional| true   | true/false | If 
enabled performs SSL verification of the server. |
+| keepalive  | boolean | optional| true   | true/false | To 
reuse the same proxy connection in near future. Set to false to disable 
keepalives and immediately close the connection.|
+| keepalive_pool  | integer | optional| 5  | [1,...] | The 
maximum number of connections in the pool.  |
+| keepalive_timeout  | integer | optional| 6   | [1000,...]
 |  The maximal idle timeout (ms). |
+
+### IAM Authorization Schema
+
+| Name | Type   | Requirement  | Default| Valid   | 
Description 
   |
+| ---  | -- | ---  | ---| -   | 

   |
+| accesskey| string | required || | 
Genereated  access key ID from aws IAM console. 
   |
+| secret_key   | string | required || | 
Genereated access key secret from aws IAM console.  
   |
+| aws_region   | string | optional | "us-east-1"| | 
The aws region where the request is being sent. 
   |
+| service  | string | optional | "execute-api"  | | 
The service that is receiving the request (In case of Http Trigger it is 
"execute-api").   |
+
+## How To Enable
+
+The following is an example of how to enable the aws-lambda faas plugin for a 
specific route URI. Calling the APISIX route uri will make an invocation to the 
lambda function uri (the new upstream).  We are assuming your cloud function is 
already up and running.

Review comment:
   ```suggestion
   The following is an example of how to enable the aws-lambda faas plugin for 
a specific route URI. Calling the APISIX route uri will make an invocation to 
the lambda function uri (the new upstream). We are assuming your cloud function 
is already up and running.
   ```

##
File path: docs/e

[GitHub] [apisix] spacewander commented on a change in pull request #5641: docs: minor update in azure faas http2 documentation

2021-11-29 Thread GitBox


spacewander commented on a change in pull request #5641:
URL: https://github.com/apache/apisix/pull/5641#discussion_r758849099



##
File path: docs/en/latest/plugins/azure-functions.md
##
@@ -104,20 +104,20 @@ Request-Context: 
appId=cid-v1:38aae829-293b-43c2-82c6-fa94aec0a071
 Date: Wed, 17 Nov 2021 14:46:55 GMT
 Server: APISIX/2.10.2
 
-Hello, apisix
+Hello, APISIX
 ```
 
-For requests where the mode of communication between the client and the Apache 
APISIX gateway is HTTP/2, the example looks like ( make sure you are running 
APISIX agent with `enable_http2: true` for a port in conf.yaml or uncomment 
port 9081 of `node_listen` field inside 
[config-default.yaml](../../../../conf/config-default.yaml) ) :
+For requests where the mode of communication between the client and the Apache 
APISIX gateway is HTTP/2, the example looks like ( make sure you are running 
APISIX agent with `enable_http2: true` for a port in 
[config-default.yaml](../../../../conf/config-default.yaml). You can do it by 
uncommenting the port 9081 from `apisix.node_listen` field ) :

Review comment:
   Please don't use a link to the `config-default.yaml`. Here is what the 
link looks like in the doc site:
   http://apisix.apache.org/docs/apisix/plugins/azure-functions
   http://apisix.apache.org/conf/config-default.yaml




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-dashboard] codecov-commenter edited a comment on pull request #2224: ci: fix stream route failed frequent

2021-11-29 Thread GitBox


codecov-commenter edited a comment on pull request #2224:
URL: https://github.com/apache/apisix-dashboard/pull/2224#issuecomment-979757962


   # 
[Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 Report
   > Merging 
[#2224](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (7f3b047) into 
[master](https://codecov.io/gh/apache/apisix-dashboard/commit/a55568408cec5eb2628971d2098a9bef992ff548?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (a555684) will **increase** coverage by `0.10%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@Coverage Diff @@
   ##   master#2224  +/-   ##
   ==
   + Coverage   62.43%   62.53%   +0.10% 
   ==
 Files  57   57  
 Lines3905 3905  
   ==
   + Hits 2438 2442   +4 
   + Misses   1185 1180   -5 
   - Partials  282  283   +1 
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | backend-e2e-test | `44.37% <ø> (+0.07%)` | :arrow_up: |
   | backend-unit-test | `49.16% <ø> (+0.03%)` | :arrow_up: |
   
   Flags with carried forward coverage won't be shown. [Click 
here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment)
 to find out more.
   
   | [Impacted 
Files](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 | Coverage Δ | |
   |---|---|---|
   | 
[api/internal/core/storage/etcd.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmFnZS9ldGNkLmdv)
 | `46.45% <0.00%> (-0.79%)` | :arrow_down: |
   | 
[api/internal/core/store/store.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvc3RvcmUuZ28=)
 | `85.41% <0.00%> (+0.52%)` | :arrow_up: |
   | 
[api/internal/core/server/server.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc2VydmVyL3NlcnZlci5nbw==)
 | `61.70% <0.00%> (+8.51%)` | :arrow_up: |
   
   --
   
   [Continue to review full report at 
Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   > **Legend** - [Click here to learn 
more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   > `Δ = absolute  (impact)`, `ø = not affected`, `? = missing data`
   > Powered by 
[Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
 Last update 
[a555684...7f3b047](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
 Read the [comment 
docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub 

[GitHub] [apisix-dashboard] codecov-commenter edited a comment on pull request #2224: ci: fix stream route failed frequent

2021-11-29 Thread GitBox


codecov-commenter edited a comment on pull request #2224:
URL: https://github.com/apache/apisix-dashboard/pull/2224#issuecomment-979757962


   # 
[Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 Report
   > Merging 
[#2224](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (7f3b047) into 
[master](https://codecov.io/gh/apache/apisix-dashboard/commit/a55568408cec5eb2628971d2098a9bef992ff548?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (a555684) will **decrease** coverage by `13.26%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@ Coverage Diff @@
   ##   master#2224   +/-   ##
   ===
   - Coverage   62.43%   49.16%   -13.27% 
   ===
 Files  57   41   -16 
 Lines3905 3171  -734 
   ===
   - Hits 2438 1559  -879 
   - Misses   1185 1412  +227 
   + Partials  282  200   -82 
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | backend-e2e-test | `?` | |
   | backend-unit-test | `49.16% <ø> (+0.03%)` | :arrow_up: |
   
   Flags with carried forward coverage won't be shown. [Click 
here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment)
 to find out more.
   
   | [Impacted 
Files](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 | Coverage Δ | |
   |---|---|---|
   | 
[api/main.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL21haW4uZ28=)
 | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | 
[api/internal/utils/version.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL3V0aWxzL3ZlcnNpb24uZ28=)
 | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | 
[api/internal/filter/request\_id.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2ZpbHRlci9yZXF1ZXN0X2lkLmdv)
 | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | 
[api/internal/filter/cors.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2ZpbHRlci9jb3JzLmdv)
 | `0.00% <0.00%> (-70.00%)` | :arrow_down: |
   | 
[api/internal/core/entity/entity.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L2VudGl0eS5nbw==)
 | `0.00% <0.00%> (-68.19%)` | :arrow_down: |
   | 
[api/internal/utils/closer.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL3V0aWxzL2Nsb3Nlci5nbw==)
 | `0.00% <0.00%> (-66.67%)` | :arrow_down: |
   | 
[api/internal/core/store/storehub.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvc3RvcmVodWIuZ28=)
 | `0.00% <0.00%> (-55.56%)` | :arrow_down: |
   | 
[api/internal/utils/consts/api\_error.go](https://codecov

[GitHub] [apisix-dashboard] codecov-commenter edited a comment on pull request #2224: ci: fix stream route failed frequent

2021-11-29 Thread GitBox


codecov-commenter edited a comment on pull request #2224:
URL: https://github.com/apache/apisix-dashboard/pull/2224#issuecomment-979757962


   # 
[Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 Report
   > Merging 
[#2224](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (5d9ee69) into 
[master](https://codecov.io/gh/apache/apisix-dashboard/commit/a55568408cec5eb2628971d2098a9bef992ff548?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (a555684) will **decrease** coverage by `0.30%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@Coverage Diff @@
   ##   master#2224  +/-   ##
   ==
   - Coverage   62.43%   62.12%   -0.31% 
   ==
 Files  57   57  
 Lines3905 3905  
   ==
   - Hits 2438 2426  -12 
   - Misses   1185 1200  +15 
   + Partials  282  279   -3 
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | backend-e2e-test | `43.96% <ø> (-0.34%)` | :arrow_down: |
   | backend-unit-test | `49.13% <ø> (ø)` | |
   
   Flags with carried forward coverage won't be shown. [Click 
here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment)
 to find out more.
   
   | [Impacted 
Files](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 | Coverage Δ | |
   |---|---|---|
   | 
[api/internal/utils/closer.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL3V0aWxzL2Nsb3Nlci5nbw==)
 | `33.33% <0.00%> (-33.34%)` | :arrow_down: |
   | 
[api/cmd/root.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2NtZC9yb290Lmdv)
 | `62.50% <0.00%> (-15.63%)` | :arrow_down: |
   | 
[api/internal/core/server/server.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc2VydmVyL3NlcnZlci5nbw==)
 | `44.68% <0.00%> (-8.52%)` | :arrow_down: |
   | 
[api/internal/core/store/store.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvc3RvcmUuZ28=)
 | `83.33% <0.00%> (-1.57%)` | :arrow_down: |
   | 
[api/internal/core/storage/etcd.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmFnZS9ldGNkLmdv)
 | `48.81% <0.00%> (+1.57%)` | :arrow_up: |
   
   --
   
   [Continue to review full report at 
Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   > **Legend** - [Click here to learn 
more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   > `Δ = absolute  (impact)`, `ø = not affected`, `? = missing data`
   > Powered by 
[Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campai

[GitHub] [apisix-dashboard] codecov-commenter edited a comment on pull request #2224: ci: fix stream route failed frequent

2021-11-29 Thread GitBox


codecov-commenter edited a comment on pull request #2224:
URL: https://github.com/apache/apisix-dashboard/pull/2224#issuecomment-979757962


   # 
[Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 Report
   > Merging 
[#2224](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (5d9ee69) into 
[master](https://codecov.io/gh/apache/apisix-dashboard/commit/a55568408cec5eb2628971d2098a9bef992ff548?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (a555684) will **decrease** coverage by `13.30%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@ Coverage Diff @@
   ##   master#2224   +/-   ##
   ===
   - Coverage   62.43%   49.13%   -13.31% 
   ===
 Files  57   41   -16 
 Lines3905 3171  -734 
   ===
   - Hits 2438 1558  -880 
   - Misses   1185 1413  +228 
   + Partials  282  200   -82 
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | backend-e2e-test | `?` | |
   | backend-unit-test | `49.13% <ø> (ø)` | |
   
   Flags with carried forward coverage won't be shown. [Click 
here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment)
 to find out more.
   
   | [Impacted 
Files](https://codecov.io/gh/apache/apisix-dashboard/pull/2224?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 | Coverage Δ | |
   |---|---|---|
   | 
[api/main.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL21haW4uZ28=)
 | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | 
[api/internal/utils/version.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL3V0aWxzL3ZlcnNpb24uZ28=)
 | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | 
[api/internal/filter/request\_id.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2ZpbHRlci9yZXF1ZXN0X2lkLmdv)
 | `0.00% <0.00%> (-100.00%)` | :arrow_down: |
   | 
[api/internal/filter/cors.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2ZpbHRlci9jb3JzLmdv)
 | `0.00% <0.00%> (-70.00%)` | :arrow_down: |
   | 
[api/internal/core/entity/entity.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvZW50aXR5L2VudGl0eS5nbw==)
 | `0.00% <0.00%> (-68.19%)` | :arrow_down: |
   | 
[api/internal/utils/closer.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL3V0aWxzL2Nsb3Nlci5nbw==)
 | `0.00% <0.00%> (-66.67%)` | :arrow_down: |
   | 
[api/internal/core/store/storehub.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2224/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2NvcmUvc3RvcmUvc3RvcmVodWIuZ28=)
 | `0.00% <0.00%> (-55.56%)` | :arrow_down: |
   | 
[api/internal/utils/consts/api\_error.go](https://codecov.io/gh/apache/ap

[GitHub] [apisix-dashboard] codecov-commenter edited a comment on pull request #2228: fix: migrate testcase CI crash

2021-11-29 Thread GitBox


codecov-commenter edited a comment on pull request #2228:
URL: https://github.com/apache/apisix-dashboard/pull/2228#issuecomment-981692905


   # 
[Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2228?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 Report
   > Merging 
[#2228](https://codecov.io/gh/apache/apisix-dashboard/pull/2228?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (b96036b) into 
[master](https://codecov.io/gh/apache/apisix-dashboard/commit/ebf381d213a85343a321defd138f51d7f0f74a14?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (ebf381d) will **decrease** coverage by `2.11%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/apisix-dashboard/pull/2228/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/apisix-dashboard/pull/2228?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@Coverage Diff @@
   ##   master#2228  +/-   ##
   ==
   - Coverage   68.13%   66.01%   -2.12% 
   ==
 Files 127  184  +57 
 Lines3352 7257+3905 
 Branches  824  824  
   ==
   + Hits 2284 4791+2507 
   - Misses   1068 2109+1041 
   - Partials0  357 +357 
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | backend-e2e-test | `44.53% <ø> (?)` | |
   | backend-e2e-test-ginkgo | `51.26% <ø> (?)` | |
   | frontend-e2e-test | `68.13% <ø> (ø)` | |
   
   Flags with carried forward coverage won't be shown. [Click 
here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment)
 to find out more.
   
   | [Impacted 
Files](https://codecov.io/gh/apache/apisix-dashboard/pull/2228?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 | Coverage Δ | |
   |---|---|---|
   | 
[api/internal/handler/data\_loader/route\_import.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2228/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvZGF0YV9sb2FkZXIvcm91dGVfaW1wb3J0Lmdv)
 | `60.58% <0.00%> (ø)` | |
   | 
[api/internal/filter/logging.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2228/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2ZpbHRlci9sb2dnaW5nLmdv)
 | `92.30% <0.00%> (ø)` | |
   | 
[api/internal/filter/recover.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2228/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2ZpbHRlci9yZWNvdmVyLmdv)
 | `7.69% <0.00%> (ø)` | |
   | 
[api/internal/handler/global\_rule/global\_rule.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2228/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvZ2xvYmFsX3J1bGUvZ2xvYmFsX3J1bGUuZ28=)
 | `68.11% <0.00%> (ø)` | |
   | 
[api/internal/handler/server\_info/server\_info.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2228/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvc2VydmVyX2luZm8vc2VydmVyX2luZm8uZ28=)
 | `84.00% <0.00%> (ø)` | |
   | 
[api/internal/handler/healthz/healthz.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2228/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBpL2ludGVybmFsL2hhbmRsZXIvaGVhbHRoei9oZWFsdGh6Lmdv)
 | `100.00% <0.00%> (ø)` | |
   | 
[api/internal/core/server/server.go](https://codecov.io/gh/apache/apisix-dashboard/pull/2228/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-YXBp

[GitHub] [apisix] bisakhmondal commented on a change in pull request #5594: feat(plugins): aws lambda serverless

2021-11-29 Thread GitBox


bisakhmondal commented on a change in pull request #5594:
URL: https://github.com/apache/apisix/pull/5594#discussion_r758502099



##
File path: t/admin/plugins.t
##
@@ -40,7 +40,7 @@ __DATA__
 --- request
 GET /apisix/admin/plugins/list
 --- response_body_like eval
-qr/\["real-ip","client-control","ext-plugin-pre-req","zipkin","request-id","fault-injection","serverless-pre-function","batch-requests","cors","ip-restriction","ua-restriction","referer-restriction","uri-blocker","request-validation","openid-connect","authz-casbin","wolf-rbac","ldap-auth","hmac-auth","basic-auth","jwt-auth","key-auth","consumer-restriction","authz-keycloak","proxy-mirror","proxy-cache","proxy-rewrite","api-breaker","limit-conn","limit-count","limit-req","gzip","server-info","traffic-split","redirect","response-rewrite","grpc-transcode","prometheus","datadog","echo","http-logger","skywalking-logger","google-cloud-logging","sls-logger","tcp-logger","kafka-logger","syslog","udp-logger","example-plugin","azure-functions","openwhisk","serverless-post-function","ext-plugin-post-req"\]/
+qr/\["real-ip","client-control","ext-plugin-pre-req","zipkin","request-id","fault-injection","serverless-pre-function","batch-requests","cors","ip-restriction","ua-restriction","referer-restriction","uri-blocker","request-validation","openid-connect","authz-casbin","wolf-rbac","ldap-auth","hmac-auth","basic-auth","jwt-auth","key-auth","consumer-restriction","authz-keycloak","proxy-mirror","proxy-cache","proxy-rewrite","api-breaker","limit-conn","limit-count","limit-req","gzip","server-info","traffic-split","redirect","response-rewrite","grpc-transcode","prometheus","datadog","echo","http-logger","skywalking-logger","google-cloud-logging","sls-logger","tcp-logger","kafka-logger","syslog","udp-logger","example-plugin","aws-lambda","azure-functions","openwhisk","serverless-post-function","ext-plugin-post-req"\]/

Review comment:
   Guys, here's it: https://github.com/apache/apisix/pull/5642




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] bisakhmondal opened a new pull request #5642: refactor: plugins list test representation

2021-11-29 Thread GitBox


bisakhmondal opened a new pull request #5642:
URL: https://github.com/apache/apisix/pull/5642


   ### What this PR does / why we need it:
   
   
   Suggestion from: 
https://github.com/apache/apisix/pull/5594#discussion_r758167136
   ### Pre-submission checklist:
   
   
   
   * [x] Did you explain what problem does this PR solve? Or what new features 
have been added?
   * [x] Have you added corresponding test cases?
   * [ ] Have you modified the corresponding document?
   * [x] Is this PR backward compatible? **If it is not backward compatible, 
please discuss on the [mailing 
list](https://github.com/apache/apisix/tree/master#community) first**
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix-dashboard] codecov-commenter edited a comment on pull request #2228: fix: migrate testcase CI crash

2021-11-29 Thread GitBox


codecov-commenter edited a comment on pull request #2228:
URL: https://github.com/apache/apisix-dashboard/pull/2228#issuecomment-981692905


   # 
[Codecov](https://codecov.io/gh/apache/apisix-dashboard/pull/2228?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 Report
   > Merging 
[#2228](https://codecov.io/gh/apache/apisix-dashboard/pull/2228?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (8527561) into 
[master](https://codecov.io/gh/apache/apisix-dashboard/commit/ebf381d213a85343a321defd138f51d7f0f74a14?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 (ebf381d) will **decrease** coverage by `18.97%`.
   > The diff coverage is `n/a`.
   
   > :exclamation: Current head 8527561 differs from pull request most recent 
head b96036b. Consider uploading reports for the commit b96036b to get more 
accurate results
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/apisix-dashboard/pull/2228/graphs/tree.svg?width=650&height=150&src=pr&token=Q1HERXN96P&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/apisix-dashboard/pull/2228?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@ Coverage Diff @@
   ##   master#2228   +/-   ##
   ===
   - Coverage   68.13%   49.16%   -18.98% 
   ===
 Files 127   41   -86 
 Lines3352 3171  -181 
 Branches  8240  -824 
   ===
   - Hits 2284 1559  -725 
   - Misses   1068 1412  +344 
   - Partials0  200  +200 
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | backend-unit-test | `49.16% <ø> (?)` | |
   | frontend-e2e-test | `?` | |
   
   Flags with carried forward coverage won't be shown. [Click 
here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment)
 to find out more.
   
   | [Impacted 
Files](https://codecov.io/gh/apache/apisix-dashboard/pull/2228?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
 | Coverage Δ | |
   |---|---|---|
   | 
[.../components/active-check/Unhealthy/TCPFailures.tsx](https://codecov.io/gh/apache/apisix-dashboard/pull/2228/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-d2ViL3NyYy9jb21wb25lbnRzL1Vwc3RyZWFtL2NvbXBvbmVudHMvYWN0aXZlLWNoZWNrL1VuaGVhbHRoeS9UQ1BGYWlsdXJlcy50c3g=)
 | | |
   | 
[...s/Upstream/components/active-check/Concurrency.tsx](https://codecov.io/gh/apache/apisix-dashboard/pull/2228/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-d2ViL3NyYy9jb21wb25lbnRzL1Vwc3RyZWFtL2NvbXBvbmVudHMvYWN0aXZlLWNoZWNrL0NvbmN1cnJlbmN5LnRzeA==)
 | | |
   | 
[...pages/Route/components/CreateStep4/CreateStep4.tsx](https://codecov.io/gh/apache/apisix-dashboard/pull/2228/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-d2ViL3NyYy9wYWdlcy9Sb3V0ZS9jb21wb25lbnRzL0NyZWF0ZVN0ZXA0L0NyZWF0ZVN0ZXA0LnRzeA==)
 | | |
   | 
[web/src/pages/SSL/service.ts](https://codecov.io/gh/apache/apisix-dashboard/pull/2228/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-d2ViL3NyYy9wYWdlcy9TU0wvc2VydmljZS50cw==)
 | | |
   | 
[web/src/pages/Upstream/Create.tsx](https://codecov.io/gh/apache/apisix-dashboard/pull/2228/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-d2ViL3NyYy9wYWdlcy9VcHN0cmVhbS9DcmVhdGUudHN4)
 | | |
   | 
[web/src/components/Upstream/components/Retries.tsx](https://codecov.io/gh/apache/apisix-dashboard/pull/2228/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-d2ViL3NyYy9jb21wb25lbnRzL1Vwc3RyZWFtL2NvbXBvbmVudHMvUmV0cmllcy50c3g=)
 | | |
   | 
[web/src/constants.ts](https://codecov.io/gh/apache/apisix-dashboard/pull/2228/diff?src=pr&el=tree&utm_medium=referral&utm

[GitHub] [apisix] bisakhmondal opened a new pull request #5641: docs: minor update in azure faas http2 documentation

2021-11-29 Thread GitBox


bisakhmondal opened a new pull request #5641:
URL: https://github.com/apache/apisix/pull/5641


   ### What this PR does / why we need it:
   
   
   Suggestion from: 
https://github.com/apache/apisix/pull/5594#discussion_r758179470
   ### Pre-submission checklist:
   
   
   
   * [x] Did you explain what problem does this PR solve? Or what new features 
have been added?
   * [ ] Have you added corresponding test cases?
   * [x] Have you modified the corresponding document?
   * [x] Is this PR backward compatible? **If it is not backward compatible, 
please discuss on the [mailing 
list](https://github.com/apache/apisix/tree/master#community) first**
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] bisakhmondal commented on a change in pull request #5594: feat(plugins): aws lambda serverless

2021-11-29 Thread GitBox


bisakhmondal commented on a change in pull request #5594:
URL: https://github.com/apache/apisix/pull/5594#discussion_r758463163



##
File path: apisix/plugins/aws-lambda.lua
##
@@ -0,0 +1,185 @@
+--
+-- Licensed to the Apache Software Foundation (ASF) under one or more
+-- contributor license agreements.  See the NOTICE file distributed with
+-- this work for additional information regarding copyright ownership.
+-- The ASF licenses this file to You under the Apache License, Version 2.0
+-- (the "License"); you may not use this file except in compliance with
+-- the License.  You may obtain a copy of the License at
+--
+-- http://www.apache.org/licenses/LICENSE-2.0
+--
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+
+local ngx = ngx
+local pairs = pairs
+local tab_concat = table.concat
+local tab_sort = table.sort
+local os = os
+local hmac = require("resty.hmac")
+local hexencode = require("resty.string").to_hex
+local resty_sha256 = require("resty.sha256")
+
+
+local plugin_name = "aws-lambda"
+local plugin_version = 0.1
+local priority = -1899
+
+local ALGO = "AWS4-HMAC-SHA256"
+
+local function hmac256(key, msg)
+return hmac:new(key, hmac.ALGOS.SHA256):final(msg)
+end
+
+local function sha256(msg)
+local hash = resty_sha256:new()
+hash:update(msg)
+local digest = hash:final()
+return hexencode(digest)
+end
+
+local function getSignatureKey(key, datestamp, region, service)
+local kDate = hmac256("AWS4" .. key, datestamp)
+local kRegion = hmac256(kDate, region)
+local kService = hmac256(kRegion, service)
+local kSigning = hmac256(kService, "aws4_request")
+return kSigning
+end
+
+local aws_authz_schema = {
+type = "object",
+properties = {
+-- API Key based authorization
+apikey = {type = "string"},
+-- IAM role based authorization, works via aws v4 request signing
+-- more at 
https://docs.aws.amazon.com/general/latest/gr/sigv4_signing.html
+iam = {
+type = "object",
+properties = {
+accesskey = {
+type = "string",
+description = "access key id from from aws iam console"
+},
+secretkey = {
+type = "string",
+description = "secret access key from from aws iam console"
+},
+aws_region = {
+type = "string",
+default = "us-east-1",
+description = "the aws region that is receiving the 
request"
+},
+service = {
+type = "string",
+default = "execute-api",
+description = "the service that is receiving the request"
+}
+},
+required = {"accesskey", "secretkey"}
+}
+}
+}
+
+local function request_processor(conf, ctx, params)
+local headers = params.headers
+-- set authorization headers if not already set by the client
+-- we are following not to overwrite the authz keys
+if not headers["x-api-key"] then
+if conf.authorization and conf.authorization.apikey then
+headers["x-api-key"] = conf.authorization.apikey
+return
+end
+end
+
+-- performing aws v4 request signing for IAM authorization
+-- visit 
https://docs.aws.amazon.com/general/latest/gr/sigv4-signed-request-examples.html
+-- to look at the pseudocode in python.
+if headers["authorization"] or not conf.authorization or not 
conf.authorization.iam then
+return
+end
+
+-- create a date for headers and the credential string
+local t = ngx.time()
+local amzdate =  os.date("!%Y%m%dT%H%M%SZ", t)
+local datestamp = os.date("!%Y%m%d", t) -- Date w/o time, used in 
credential scope
+headers["X-Amz-Date"] = amzdate
+
+-- computing canonical uri
+local canonical_uri = params.path:gsub("//", "/")

Review comment:
   Done




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [apisix] bisakhmondal commented on a change in pull request #5594: feat(plugins): aws lambda serverless

2021-11-29 Thread GitBox


bisakhmondal commented on a change in pull request #5594:
URL: https://github.com/apache/apisix/pull/5594#discussion_r758461816



##
File path: apisix/plugins/aws-lambda.lua
##
@@ -0,0 +1,185 @@
+--
+-- Licensed to the Apache Software Foundation (ASF) under one or more
+-- contributor license agreements.  See the NOTICE file distributed with
+-- this work for additional information regarding copyright ownership.
+-- The ASF licenses this file to You under the Apache License, Version 2.0
+-- (the "License"); you may not use this file except in compliance with
+-- the License.  You may obtain a copy of the License at
+--
+-- http://www.apache.org/licenses/LICENSE-2.0
+--
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+
+local ngx = ngx
+local pairs = pairs
+local tab_concat = table.concat
+local tab_sort = table.sort
+local os = os
+local hmac = require("resty.hmac")
+local hexencode = require("resty.string").to_hex
+local resty_sha256 = require("resty.sha256")
+
+
+local plugin_name = "aws-lambda"
+local plugin_version = 0.1
+local priority = -1899
+
+local ALGO = "AWS4-HMAC-SHA256"
+
+local function hmac256(key, msg)
+return hmac:new(key, hmac.ALGOS.SHA256):final(msg)
+end
+
+local function sha256(msg)
+local hash = resty_sha256:new()
+hash:update(msg)
+local digest = hash:final()
+return hexencode(digest)
+end
+
+local function getSignatureKey(key, datestamp, region, service)
+local kDate = hmac256("AWS4" .. key, datestamp)
+local kRegion = hmac256(kDate, region)
+local kService = hmac256(kRegion, service)
+local kSigning = hmac256(kService, "aws4_request")
+return kSigning
+end
+
+local aws_authz_schema = {
+type = "object",
+properties = {
+-- API Key based authorization
+apikey = {type = "string"},
+-- IAM role based authorization, works via aws v4 request signing
+-- more at 
https://docs.aws.amazon.com/general/latest/gr/sigv4_signing.html
+iam = {
+type = "object",
+properties = {
+accesskey = {
+type = "string",
+description = "access key id from from aws iam console"
+},
+secretkey = {
+type = "string",
+description = "secret access key from from aws iam console"
+},
+aws_region = {
+type = "string",
+default = "us-east-1",
+description = "the aws region that is receiving the 
request"
+},
+service = {
+type = "string",
+default = "execute-api",
+description = "the service that is receiving the request"
+}
+},
+required = {"accesskey", "secretkey"}
+}
+}
+}
+
+local function request_processor(conf, ctx, params)
+local headers = params.headers
+-- set authorization headers if not already set by the client
+-- we are following not to overwrite the authz keys
+if not headers["x-api-key"] then
+if conf.authorization and conf.authorization.apikey then
+headers["x-api-key"] = conf.authorization.apikey
+return
+end
+end
+
+-- performing aws v4 request signing for IAM authorization
+-- visit 
https://docs.aws.amazon.com/general/latest/gr/sigv4-signed-request-examples.html
+-- to look at the pseudocode in python.
+if headers["authorization"] or not conf.authorization or not 
conf.authorization.iam then
+return
+end
+
+-- create a date for headers and the credential string
+local t = ngx.time()
+local amzdate =  os.date("!%Y%m%dT%H%M%SZ", t)
+local datestamp = os.date("!%Y%m%d", t) -- Date w/o time, used in 
credential scope
+headers["X-Amz-Date"] = amzdate
+
+-- computing canonical uri
+local canonical_uri = params.path:gsub("//", "/")
+if canonical_uri ~= "/" then
+if canonical_uri:sub(-1, -1) == "/" then
+canonical_uri = canonical_uri:sub(1, -2)
+end
+if canonical_uri:sub(1, 1) ~= "/" then
+canonical_uri = "/" .. canonical_uri
+end
+end
+
+-- computing canonical query string
+local canonical_qs = {}
+for k, v in pairs(params.query) do
+canonical_qs[#canonical_qs+1] = ngx.unescape_uri(k) .. "=" .. 
ngx.unescape_uri(v)
+end
+
+tab_sort(canonical_qs)
+canonical_qs = tab_concat(canonical_qs, "&")
+
+-- computing canonical and signed headers
+
+local canonical_headers, signed_headers = {}, {}
+for k, v in pairs(headers) do
+   

[GitHub] [apisix] bisakhmondal commented on a change in pull request #5594: feat(plugins): aws lambda serverless

2021-11-29 Thread GitBox


bisakhmondal commented on a change in pull request #5594:
URL: https://github.com/apache/apisix/pull/5594#discussion_r758461565



##
File path: apisix/plugins/aws-lambda.lua
##
@@ -0,0 +1,185 @@
+--
+-- Licensed to the Apache Software Foundation (ASF) under one or more
+-- contributor license agreements.  See the NOTICE file distributed with
+-- this work for additional information regarding copyright ownership.
+-- The ASF licenses this file to You under the Apache License, Version 2.0
+-- (the "License"); you may not use this file except in compliance with
+-- the License.  You may obtain a copy of the License at
+--
+-- http://www.apache.org/licenses/LICENSE-2.0
+--
+-- Unless required by applicable law or agreed to in writing, software
+-- distributed under the License is distributed on an "AS IS" BASIS,
+-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+-- See the License for the specific language governing permissions and
+-- limitations under the License.
+
+local ngx = ngx
+local pairs = pairs
+local tab_concat = table.concat
+local tab_sort = table.sort
+local os = os
+local hmac = require("resty.hmac")
+local hexencode = require("resty.string").to_hex
+local resty_sha256 = require("resty.sha256")
+
+
+local plugin_name = "aws-lambda"
+local plugin_version = 0.1
+local priority = -1899
+
+local ALGO = "AWS4-HMAC-SHA256"
+
+local function hmac256(key, msg)
+return hmac:new(key, hmac.ALGOS.SHA256):final(msg)
+end
+
+local function sha256(msg)
+local hash = resty_sha256:new()
+hash:update(msg)
+local digest = hash:final()
+return hexencode(digest)
+end
+
+local function getSignatureKey(key, datestamp, region, service)
+local kDate = hmac256("AWS4" .. key, datestamp)
+local kRegion = hmac256(kDate, region)
+local kService = hmac256(kRegion, service)
+local kSigning = hmac256(kService, "aws4_request")
+return kSigning
+end
+
+local aws_authz_schema = {
+type = "object",
+properties = {
+-- API Key based authorization
+apikey = {type = "string"},
+-- IAM role based authorization, works via aws v4 request signing
+-- more at 
https://docs.aws.amazon.com/general/latest/gr/sigv4_signing.html
+iam = {
+type = "object",
+properties = {
+accesskey = {
+type = "string",
+description = "access key id from from aws iam console"
+},
+secretkey = {
+type = "string",
+description = "secret access key from from aws iam console"
+},
+aws_region = {
+type = "string",
+default = "us-east-1",
+description = "the aws region that is receiving the 
request"
+},
+service = {
+type = "string",
+default = "execute-api",
+description = "the service that is receiving the request"
+}
+},
+required = {"accesskey", "secretkey"}
+}
+}
+}
+
+local function request_processor(conf, ctx, params)
+local headers = params.headers
+-- set authorization headers if not already set by the client
+-- we are following not to overwrite the authz keys
+if not headers["x-api-key"] then
+if conf.authorization and conf.authorization.apikey then
+headers["x-api-key"] = conf.authorization.apikey
+return
+end
+end
+
+-- performing aws v4 request signing for IAM authorization
+-- visit 
https://docs.aws.amazon.com/general/latest/gr/sigv4-signed-request-examples.html
+-- to look at the pseudocode in python.
+if headers["authorization"] or not conf.authorization or not 
conf.authorization.iam then
+return
+end
+
+-- create a date for headers and the credential string
+local t = ngx.time()
+local amzdate =  os.date("!%Y%m%dT%H%M%SZ", t)
+local datestamp = os.date("!%Y%m%d", t) -- Date w/o time, used in 
credential scope
+headers["X-Amz-Date"] = amzdate
+
+-- computing canonical uri
+local canonical_uri = params.path:gsub("//", "/")
+if canonical_uri ~= "/" then
+if canonical_uri:sub(-1, -1) == "/" then
+canonical_uri = canonical_uri:sub(1, -2)
+end
+if canonical_uri:sub(1, 1) ~= "/" then
+canonical_uri = "/" .. canonical_uri
+end
+end
+
+-- computing canonical query string
+local canonical_qs = {}
+for k, v in pairs(params.query) do
+canonical_qs[#canonical_qs+1] = ngx.unescape_uri(k) .. "=" .. 
ngx.unescape_uri(v)
+end
+
+tab_sort(canonical_qs)
+canonical_qs = tab_concat(canonical_qs, "&")
+
+-- computing canonical and signed headers
+
+local canonical_headers, signed_headers = {}, {}
+for k, v in pairs(headers) do
+   

  1   2   >