来自kie服务器的故障答案(使用kie服务器展示和业务中心工作台展示)



我正在测试业务中心,kie服务器都在docker中运行,两者都是"陈列柜";版本。我在商业中心做了一个项目;奶牛;模型和决策表;部署成功。

发送带有请求体的json后

{
"commands:": [
{
"insert": {
"object": {
"Cow": {
"name": "cow1",
"age": 11
}
},
"out-identifier": "Cow",
"return-object": true
}
},
{
"fire-all-rules": {}
}
]
}

到端点http://localhost:8180/kie-server/services/rest/server/containers/instances/Cow

接收错误:

{
"type": "FAILURE",
"msg": "Bad request, no commands to be executed - either wrong format or no data",
"result": null
}

我做错了什么吗?为什么我的请求没有继续?

我认为在您的请求中,您需要规范类名com.axaukraine.Cow,但您只使用了简单的名称Cow

{
"commands:": [
{
"insert": {
"object": {
"com.axaukraine.Cow": {
"name": "cow1",
"age": 11
}
},
"out-identifier": "Cow",
"return-object": true
}
},
{
"fire-all-rules": {}
}
]
}

最新更新