邮政后,Spring数据休息流关闭

时间:2017-07-15 03:01:00

标签: spring angular spring-boot

我使用Spring Data Rest进行后端操作,将Angular 2用于我的前端。

当我使用post方法保存数据时,它设法保存数据,但由于以下错误,它无法以JSON格式返回

"Could not read JSON document: Stream closed; nested exception is java.io.IOException: Stream closed"

这是返回主体

{
    "created" : "2017-07-15T02:55:06.080+0000",
    "updated" : "2017-07-15T02:55:06.080+0000",
    "deleted" : null,
    "view_count" : 0,
    "status" : "active",
    "name" : "Howdy",
    "email" : "example@gmail.com",
    "phone" : null,
    "uid" : "JKHLJK78587JK6S",
    "last_login" : "2017-07-15T02:55:06.080+0000",
    "_links" : {
        "self" : {
            "href" : "http://localhost:8080/api/v1/users/11"
        },
        "user" : {
            "href" : "http://localhost:8080/api/v1/users/11"
        },
        "things" : {
        "href" : "http://localhost:8080/api/v1/users/11/things"
        }
    }
}, {
    "cause":{
        "cause":null,
        "message":"Stream closed"
    },
    "message":"Could not read JSON document: Stream closed; nested exception is java.io.IOException: Stream closed"
}

0 个答案:

没有答案