FionJHYang opened a new issue, #2957:
URL: https://github.com/apache/apisix-dashboard/issues/2957

   ### Issue description
   
   Enable plugin to global_rules in 'Plugin List', dashboard will removed the 
_meta.filter setting when insert the plugin to ETCD.
   
   if I want insert the request-validation plugin like below setting: 
   `{
     "_meta": {
       "disable": true,
       "filter": [
             [
                 "host",
                 "~=",
                 "test.com.tw"
               ]
           ]
     },
     "header_schema": {
       "properties": {
         "Origin": {
           "type": "string"
         }
       },
       "required": [
         "Origin"
       ],
       "type": "object"
     }
   }`
   
   After click submit button, the data in ETCD will remove filter section like 
below:
   `{
     "_meta": {
       "disable": true
     },
     "header_schema": {
       "properties": {
         "Origin": {
           "type": "string"
         }
       },
       "required": [
         "Origin"
       ],
       "type": "object"
     }
   }`
   
   ### Expected behavior
   
   Do not remove _meta.filter section when insert into ETCD:
   `{
     "_meta": {
       "disable": true,
       "filter": [
             [
                 "host",
                 "~=",
                 "test.com.tw"
               ]
           ]
     },
     "header_schema": {
       "properties": {
         "Origin": {
           "type": "string"
         }
       },
       "required": [
         "Origin"
       ],
       "type": "object"
     }
   }`
   
   ### How to Reproduce
   
   1. Login Apisix Dashboard
   2. Click side menu 'Plugin'
   3. Click 'Enable' button to enable a plugin
   4. Select one plugin to enable and set _meta.filter config
   5. Click submit to finish enable
   
   ### Screenshots
   
   _No response_
   
   ### Environment
   
   - apisix version (cmd: `apisix version`): 3.8.0
   - OS (cmd: `uname -a`):
   - OpenResty / Nginx version (cmd: `nginx -V` or `openresty -V`):
   - etcd version, if have (cmd: run `etcd --version`):
   - apisix-dashboard version, if have:
   - Browser version, if have:
   
   
   ### Additional context
   
   _No response_


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to