java.io.IOException:从Jackson解析JSON时关闭流

时间:2014-07-11 06:12:01

标签: jackson java-io

我试图在通过perl转储后解析一个看起来像这样的JSON对象

{
  "customerID":"random",
  "sessionID":"192-3105199-8486749"
}

当我尝试反序列化时,我得到以下异常 -

[tomcat:launch] java.io.IOException: Stream closed
[tomcat:launch] at org.apache.catalina.connector.InputBuffer.read (InputBuffer.java:413
[tomcat:launch] at org.apache.catalina.connector.CoyoteReader.read (CoyoteReader.java:108
[tomcat:launch] at com.fasterxml.jackson.core.json.ReaderBasedJsonParser.loadMore (ReaderBasedJsonParser.java:127)
[tomcat:launch] at com.fasterxml.jackson.core.json.ReaderBasedJsonParser._skipWSOrEnd (ReaderBasedJsonParser.java:1659)
[tomcat:launch] at com.fasterxml.jackson.core.json.ReaderBasedJsonParser.nextToken (ReaderBasedJsonParser.java:561)
[tomcat:launch] at com.fasterxml.jackson.databind.ObjectMapper._initForReading (ObjectMapper.java:2834)
[tomcat:launch] at com.fasterxml.jackson.databind.ObjectMapper._readMapAndClose (ObjectMapper.java:2781)
[tomcat:launch] at com.fasterxml.jackson.databind.ObjectMapper.readValue (ObjectMapper.java:1965)

我对JSON相当陌生,并且不知道出了什么问题。

0 个答案:

没有答案