You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by "xubinthor (via GitHub)" <gi...@apache.org> on 2023/03/28 07:47:02 UTC

[GitHub] [apisix] xubinthor opened a new issue, #9183: The priority of the custom plug-in is invalid

xubinthor opened a new issue, #9183:
URL: https://github.com/apache/apisix/issues/9183

   ### Description
   
   I set the plug-in execution priority, base-auth and ip-restriction according to the documents, but the Settings are invalid and the base-auth plug-in is executed first
   
   the route config is :
   {
       "id": "453027477904687809",
       "create_time": 1679555018,
       "update_time": 1679989160,
       "uri": "/xubin/*",
       "name": "检查测试",
       "priority": 1,
       "methods": [
           "GET",
           "POST",
           "PUT",
           "DELETE",
           "PATCH",
           "HEAD",
           "OPTIONS",
           "CONNECT",
           "TRACE"
       ],
       "plugins": {
           "basic-auth": {
               "_meta": {
                   "priority": -2000
               },
               "disable": false
           },
           "ip-restriction": {
               "_meta": {
                   "priority": 10000
               },
               "disable": false,
               "whitelist": [
                   "113.74.26.106/24"
               ]
           },
           "proxy-rewrite": {
               "regex_uri": [
                   "^/xubin(/|$)(.*)",
                   "/$2"
               ]
           }
       },
       "upstream": {
           "nodes": [
               {
                   "host": "192.168.88.66",
                   "port": 9001,
                   "weight": 1
               }
           ],
           "retries": 15,
           "timeout": {
               "connect": 1,
               "send": 1,
               "read": 9
           },
           "type": "roundrobin",
           "scheme": "http",
           "pass_host": "pass",
           "keepalive_pool": {
               "idle_timeout": 60,
               "requests": 1000,
               "size": 320
           },
           "retry_timeout": 10
       },
       "labels": {
           "1": "1"
       },
       "status": 1
   }
   
   ### Environment
   
   - APISIX version (run `apisix 2.15-alpine`):
   - Operating system (run `uname -a`):
   - OpenResty / Nginx version (run `openresty -V` or `nginx -V`):
   - etcd version, if relevant (run `curl http://127.0.0.1:9090/v1/server_info`):
   - APISIX Dashboard version, if relevant:
   - Plugin runner version, for issues related to plugin runners:
   - LuaRocks version, for installation issues (run `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-unsubscribe@apisix.apache.org.apache.org

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


[GitHub] [apisix] xubinthor commented on issue #9183: The priority of the custom plug-in is invalid

Posted by "xubinthor (via GitHub)" <gi...@apache.org>.
xubinthor commented on issue #9183:
URL: https://github.com/apache/apisix/issues/9183#issuecomment-1486478871

    i try the jwt-auth and basic-auth with:"_meta": {"priority": 30000 } is ok ,but ip-restriction is invalid 
   


-- 
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-unsubscribe@apisix.apache.org

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


[GitHub] [apisix] xubinthor commented on issue #9183: The priority of the custom plug-in is invalid

Posted by "xubinthor (via GitHub)" <gi...@apache.org>.
xubinthor commented on issue #9183:
URL: https://github.com/apache/apisix/issues/9183#issuecomment-1486375950

   the doc is [https://apisix.apache.org/zh/docs/apisix/2.15/terminology/plugin/](url)
   But it doesn't work
   
   


-- 
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-unsubscribe@apisix.apache.org

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


[GitHub] [apisix] thor533 closed issue #9183: The priority of the custom plug-in is invalid

Posted by "thor533 (via GitHub)" <gi...@apache.org>.
thor533 closed issue #9183: The priority of the custom plug-in is invalid
URL: https://github.com/apache/apisix/issues/9183


-- 
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-unsubscribe@apisix.apache.org

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


[GitHub] [apisix] thor533 commented on issue #9183: The priority of the custom plug-in is invalid

Posted by "thor533 (via GitHub)" <gi...@apache.org>.
thor533 commented on issue #9183:
URL: https://github.com/apache/apisix/issues/9183#issuecomment-1487829995

   > How did you determine that the ip-restriction plugin wasn't executed first? Could it be that the ip-restriction plugin was executed, but it was not intercepted successfully?
   
   I've only configured the basic-auth and ip-restriction plug-ins, and they both work, but I want ip-restriction to work first. I've configured the parameters according to the documentation, "_meta": {"priority": 100}, but the basic-auth is executed first,
   My route configuration is as follows:
   
   {
   "id": "453027477904687809",
   "create_time": 1679555018,
   "update_time": 1679999874,
   "uri": "/xubin/",
   "name": "测试测试22",
   "priority": 1,
   "methods": [
   "GET",
   "POST",
   "PUT",
   "DELETE",
   "PATCH",
   "HEAD",
   "OPTIONS",
   "CONNECT",
   "TRACE"
   ],
   "plugins": {
   "basic-auth": {
   "_meta": {
   "priority": 2
   },
   "disable": true
   },
   "ip-restriction": {
   "_meta": {
   "priority": 100
   },
   "disable": false,
   "whitelist": [
   "192.168.88.61"
   ]
   },
   "proxy-rewrite": {
   "regex_uri": [
   "^/xubin(/|$)(.)",
   "/$2"
   ]
   }
   },
   "upstream": {
   "nodes": [
   {
   "host": "192.168.88.66",
   "port": 9001,
   "weight": 1
   }
   ],
   "retries": 15,
   "timeout": {
   "connect": 1,
   "send": 1,
   "read": 9
   },
   "type": "roundrobin",
   "scheme": "http",
   "pass_host": "pass",
   "keepalive_pool": {
   "idle_timeout": 60,
   "requests": 1000,
   "size": 320
   },
   "retry_timeout": 10
   },
   "labels": {
   "1": "1"
   },
   "status": 1
   }


-- 
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-unsubscribe@apisix.apache.org

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


[GitHub] [apisix] soulbird commented on issue #9183: The priority of the custom plug-in is invalid

Posted by "soulbird (via GitHub)" <gi...@apache.org>.
soulbird commented on issue #9183:
URL: https://github.com/apache/apisix/issues/9183#issuecomment-1486540982

   How did you determine that the ip-restriction plugin wasn't executed first? Could it be that the ip-restriction plugin was executed, but it was not intercepted successfully?


-- 
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-unsubscribe@apisix.apache.org

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


[GitHub] [apisix] githubxubin commented on issue #9183: The priority of the custom plug-in is invalid

Posted by "githubxubin (via GitHub)" <gi...@apache.org>.
githubxubin commented on issue #9183:
URL: https://github.com/apache/apisix/issues/9183#issuecomment-1486622078

   > How did you determine that the ip-restriction plugin wasn't executed first? Could it be that the ip-restriction plugin was executed, but it was not intercepted successfully?
   
   I've only configured the basic-auth and ip-restriction plug-ins, and they both work, but I want ip-restriction to work first. I've configured the parameters according to the documentation, "_meta": {"priority": 100}, but the basic-auth is executed first,
   My route configuration is as follows:
   
   {
       "id": "453027477904687809",
       "create_time": 1679555018,
       "update_time": 1679999874,
       "uri": "/xubin/*",
       "name": "测试测试22",
       "priority": 1,
       "methods": [
           "GET",
           "POST",
           "PUT",
           "DELETE",
           "PATCH",
           "HEAD",
           "OPTIONS",
           "CONNECT",
           "TRACE"
       ],
       "plugins": {
           "basic-auth": {
               "_meta": {
                   "priority": 2
               },
               "disable": true
           },
           "ip-restriction": {
               "_meta": {
                   "priority": 100
               },
               "disable": false,
               "whitelist": [
                   "192.168.88.61"
               ]
           },
           "proxy-rewrite": {
               "regex_uri": [
                   "^/xubin(/|$)(.*)",
                   "/$2"
               ]
           }
       },
       "upstream": {
           "nodes": [
               {
                   "host": "192.168.88.66",
                   "port": 9001,
                   "weight": 1
               }
           ],
           "retries": 15,
           "timeout": {
               "connect": 1,
               "send": 1,
               "read": 9
           },
           "type": "roundrobin",
           "scheme": "http",
           "pass_host": "pass",
           "keepalive_pool": {
               "idle_timeout": 60,
               "requests": 1000,
               "size": 320
           },
           "retry_timeout": 10
       },
       "labels": {
           "1": "1"
       },
       "status": 1
   }
    
   
   > How did you determine that the ip-restriction plugin wasn't executed first? Could it be that the ip-restriction plugin was executed, but it was not intercepted successfully?
   
   > How did you determine that the ip-restriction plugin wasn't executed first? Could it be that the ip-restriction plugin was executed, but it was not intercepted successfully?
   
   I've only configured the basic-auth and ip-restriction plug-ins, and they both work, but I want ip-restriction to work first. I've configured the parameters according to the documentation, "_meta": {"priority": 100}, but the basic-auth is executed first,
   My route configuration is as follows:
   
   {
       "id": "453027477904687809",
       "create_time": 1679555018,
       "update_time": 1679999874,
       "uri": "/xubin/*",
       "name": "测试测试22",
       "priority": 1,
       "methods": [
           "GET",
           "POST",
           "PUT",
           "DELETE",
           "PATCH",
           "HEAD",
           "OPTIONS",
           "CONNECT",
           "TRACE"
       ],
       "plugins": {
           "basic-auth": {
               "_meta": {
                   "priority": 2
               },
               "disable": true
           },
           "ip-restriction": {
               "_meta": {
                   "priority": 100
               },
               "disable": false,
               "whitelist": [
                   "192.168.88.61"
               ]
           },
           "proxy-rewrite": {
               "regex_uri": [
                   "^/xubin(/|$)(.*)",
                   "/$2"
               ]
           }
       },
       "upstream": {
           "nodes": [
               {
                   "host": "192.168.88.66",
                   "port": 9001,
                   "weight": 1
               }
           ],
           "retries": 15,
           "timeout": {
               "connect": 1,
               "send": 1,
               "read": 9
           },
           "type": "roundrobin",
           "scheme": "http",
           "pass_host": "pass",
           "keepalive_pool": {
               "idle_timeout": 60,
               "requests": 1000,
               "size": 320
           },
           "retry_timeout": 10
       },
       "labels": {
           "1": "1"
       },
       "status": 1
   }
    


-- 
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-unsubscribe@apisix.apache.org

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