apisix-dashboard
apisix-dashboard copied to clipboard
bug: echo plugin can not set headers
- Why do you submit this issue?
- [ ] Question or discussion
- [x] Bug
- [ ] Requirements
- [ ] Feature or performance improvement
- [ ] Other
The headers option will automatically refresh as Opthion3 when setting the other option,
and the headers option can not be set.

There are two errors here:
-
headersschema should be transformed just likeproxy-rewriteandresponse-rewritein fe plugin component -
echoschema still uses Draft5, that why we will see select elementOption1in page. so It also needs to change the echo shema to Draft7.
{
"additionalProperties": false,
"required": ["before_body","body","after_body"],
"minProperties": 1,
"properties": {
"after_body": {
"description": "body after the modification of filter phase.",
"type": "string"
},
"auth_value": {
"description": "auth value",
"type": "string"
},
"before_body": {
"description": "body before the filter phase.",
"type": "string"
},
"body": {
"description": "body to replace upstream response.",
"type": "string"
},
"headers": {
"description": "new headers for response",
"minProperties":1,
"type": "object"
}
},
"type": "object"
}
fixed by code-mirror
closed by https://github.com/apache/apisix-dashboard/pull/898