[Bug] [Alarm instance management] Edit alarm instance-select http alarm-test sending failed
jssngz opened this issue · comments
Search before asking
- I had searched in the issues and found no similar issues.
What happened
我尝试创建一个http告警,使用了httppost的方式
查看浏览器控制台:调用了http://192.168.164.128:12345/dolphinscheduler/alert-plugin-instances/test-send这个接口
请求入参:
pluginDefineId: 9
pluginDefineId:[{"props":{"disabled":null,"type":null,"maxlength":null,"minlength":null,"clearable":null,"prefixIcon":null,"suffixIcon":null,"rows":null,"autosize":null,"autocomplete":null,"name":null,"readonly":null,"max":null,"min":null,"step":null,"resize":null,"autofocus":null,"form":null,"label":null,"tabindex":null,"validateEvent":null,"showPassword":null,"placeholder":"input request URL","size":"small"},"field":"url","name":"URL","type":"input","title":"$t('url')","value":"http://192.168.153.1:8080/alert/common","validate":[{"required":true,"type":"string","trigger":"blur","min":null,"max":null}],"emit":null},{"props":{"disabled":null,"type":null,"maxlength":null,"minlength":null,"clearable":null,"prefixIcon":null,"suffixIcon":null,"rows":null,"autosize":null,"autocomplete":null,"name":null,"readonly":null,"max":null,"min":null,"step":null,"resize":null,"autofocus":null,"form":null,"label":null,"tabindex":null,"validateEvent":null,"showPassword":null,"placeholder":"input request type POST or GET","size":"small"},"field":"requestType","name":"请求方式","type":"input","title":"$t('requestType')","value":"POST","validate":[{"required":true,"type":"string","trigger":"blur","min":null,"max":null}],"emit":null},{"props":{"disabled":null,"type":null,"maxlength":null,"minlength":null,"clearable":null,"prefixIcon":null,"suffixIcon":null,"rows":null,"autosize":null,"autocomplete":null,"name":null,"readonly":null,"max":null,"min":null,"step":null,"resize":null,"autofocus":null,"form":null,"label":null,"tabindex":null,"validateEvent":null,"showPassword":null,"placeholder":"input request headers as JSON format","size":"small"},"field":"headerParams","name":"请求头","type":"input","title":"$t('headerParams')","value":"{"Content-Type":"application/json;charset=UTF-8","Authorization":"Bearer eyJhbGciOiJIUzUxMiJ9.eyJsb2dpbl91c2VyX2tleSI6ImEzYWE3M2E2LWU5ZWUtNGRlYi04ZmVkLTYyNDg3YmMwN2Y5YyJ9.ateM4ki2qeqW2W31MYPkwQe16jZvG-MM-04czAP90u4P2qsENvwabFlLvMNSORyLJ0TRGG2QSUmmdRsJtdwzVg"}","validate":[{"required":true,"type":"string","trigger":"blur","min":null,"max":null}],"emit":null},{"props":{"disabled":null,"type":null,"maxlength":null,"minlength":null,"clearable":null,"prefixIcon":null,"suffixIcon":null,"rows":null,"autosize":null,"autocomplete":null,"name":null,"readonly":null,"max":null,"min":null,"step":null,"resize":null,"autofocus":null,"form":null,"label":null,"tabindex":null,"validateEvent":null,"showPassword":null,"placeholder":"input request body as JSON format","size":"small"},"field":"bodyParams","name":"请求体","type":"input","title":"$t('bodyParams')","value":"{"name": "zhangsan","value": "not ok" }","validate":[{"required":false,"type":"string","trigger":"blur","min":null,"max":null}],"emit":null},{"props":{"disabled":null,"type":null,"maxlength":null,"minlength":null,"clearable":null,"prefixIcon":null,"suffixIcon":null,"rows":null,"autosize":null,"autocomplete":null,"name":null,"readonly":null,"max":null,"min":null,"step":null,"resize":null,"autofocus":null,"form":null,"label":null,"tabindex":null,"validateEvent":null,"showPassword":null,"placeholder":"input alert msg field name","size":"small"},"field":"contentField","name":"内容字段","type":"input","title":"$t('contentField')","value":"zhangsan-TEST","validate":[{"required":true,"type":"string","trigger":"blur","min":null,"max":null}],"emit":null},{"props":null,"field":"timeout","name":"超时时间(秒)","type":"input-number","title":"$t('timeout')","value":60,"validate":[{"required":false,"type":"number","trigger":"blur","min":null,"max":null}],"emit":null}]
配置截图:
响应截图:
我使用apipost请求的信息的截图:
我的接口方法&日志截图:
dolphinscheduler的版本3.2.1
是在虚拟机上部署docker版本
What you expected to happen
测试接口发送应该是从api服务器端发送的请求到我的服务器地址。但是好像对结果的处理没有处理好。因此才报错。
How to reproduce
处理好接口返回值。定义好什么是正确的返回值,并写在文档中。目前文档只有截图两张。
Anything else
No response
Version
3.2.x
Are you willing to submit PR?
- Yes I am willing to submit a PR!
Code of Conduct
- I agree to follow this project's Code of Conduct
Search before asking
- I had searched in the issues and found no similar issues.
What happened
I tried to create an http alert, using the httppost method
Check the browser console: the http://192.168.164.128:12345/dolphinscheduler/alert-plugin-instances/test-send interface is called
Request input parameters:
pluginDefineId: 9
pluginDefineId: [{"props":{"disabled":null,"type":null,"maxlength":null,"minlength":null,"clearable":null,"prefixIcon":null,"suffixIcon":null ,"rows":null,"autosize":null,"autocomplete":null,"name":null,"readonly":null,"max":null,"min":null,"step":null," resize":null,"autofocus":null,"form":null,"label":null,"tabindex":null,"validateEvent":null,"showPassword":null,"placeholder":"input request URL" ,"size":"small"},"field":"url","name":"URL","type":"input","title":"$t('url')","value ":"http://192.168.153.1:8080/alert/common","validate":[{"required":true,"type":"string","trigger":"blur","min": null,"max":null}],"emit":null},{"props":{"disabled":null,"type":null,"maxlength":null,"minlength":null,"clearable" :null,"prefixIcon":null,"suffixIcon":null,"rows":null,"autosize":null,"autocomplete":null,"name":null,"readonly":null,"max":null ,"min":null,"step":null,"resize":null,"autofocus":null,"form":null,"label":null,"tabindex":null,"validateEvent":null," showPassword":null,"placeholder":"input request type POST or GET","size":"small"},"field":"requestType","name":"request method","type":"input ","title":"$t('requestType')","value":"POST","validate":[{"required":true,"type":"string","trigger":"blur ","min":null,"max":null}],"emit":null},{"props":{"disabled":null,"type":null,"maxlength":null,"minlength" :null,"clearable":null,"prefixIcon":null,"suffixIcon":null,"rows":null,"autosize":null,"autocomplete":null,"name":null,"readonly":null ,"max":null,"min":null,"step":null,"resize":null,"autofocus":null,"form":null,"label":null,"tabindex":null," validateEvent":null,"showPassword":null,"placeholder":"input request headers as JSON format","size":"small"},"field":"headerParams","name":"request header", "type":"input","title":"$t('headerParams')","value":"{"Content-Type":"application/json;charset=UTF-8", "Authorization":"Bearer ZvG-MM-04czAP90u4P2qsENvwabFlLvMNSORyLJ0TRGG2QSUmmdRsJtdwzVg"}","validate":[{"required":true,"type":"string","trigger":"blur" ,"min":null,"max":null}],"emit":null},{"props":{"disabled":null,"type":null,"maxlength":null,"minlength": null,"clearable":null,"prefixIcon":null,"suffixIcon":null,"rows":null,"autosize":null,"autocomplete":null,"name":null,"readonly":null, "max":null,"min":null,"step":null,"resize":null,"autofocus":null,"form":null,"label":null,"tabindex":null,"validateEvent ":null,"showPassword":null,"placeholder":"input request body as JSON format","size":"small"},"field":"bodyParams","name":"request body"," type":"input","title":"$t('bodyParams')","value":"{"name": "zhangsan","value": "not ok\ " }","validate":[{"required":false,"type":"string","trigger":"blur","min":null,"max":null}],"emit": null},{"props":{"disabled":null,"type":null,"maxlength":null,"minlength":null,"clearable":null,"prefixIcon":null,"suffixIcon":null ,"rows":null,"autosize":null,"autocomplete":null,"name":null,"readonly":null,"max":null,"min":null,"step":null," resize":null,"autofocus":null,"form":null,"label":null,"tabindex":null,"validateEvent":null,"showPassword":null,"placeholder":"input alert msg field name","size":"small"},"field":"contentField","name":"content field","type":"input","title":"$t('contentField')" ,"value":"zhangsan-TEST","validate":[{"required":true,"type":"string","trigger":"blur","min":null,"max":null }],"emit":null},{"props":null,"field":"timeout","name":"Timeout (seconds)","type":"input-number","title" :"$t('timeout')","value":60,"validate":[{"required":false,"type":"number","trigger":"blur","min":null ,"max":null}],"emit":null}]
Configuration screenshot:
Response screenshot:
Screenshot of the information I request using apipost:
My interface methods & log screenshots:
Version 3.2.1 of dolphinscheduler
Deploy the docker version on the virtual machine
What you expected to happen
The test interface sends the request that should be sent from the api server to my server address. But it seems that the results are not handled well. That's why the error was reported.
How to reproduce
Handle the interface return value. Define what the correct return value is and document it. Currently the document only has two screenshots.
Anything else
No response
Version
3.2.x
Are you willing to submit PR?
- Yes I am willing to submit a PR!
Code of Conduct
- I agree to follow this project's Code of Conduct