Can not deserialize instance of java.lang.String out of START_OBJECT token

前端 未结 5 717
野的像风
野的像风 2020-12-08 12:42

I\'m running into an issue where my deployable jar hits an exception that doesn\'t happen when I run this locally in IntelliJ.

Exception:

5条回答
  •  北海茫月
    2020-12-08 13:15

    If you do not want to define a separate class for nested json , Defining nested json object as JsonNode should work ,for example :

    {"id":2,"socket":"0c317829-69bf-43d6-b598-7c0c550635bb","type":"getDashboard","data":{"workstationUuid":"ddec1caa-a97f-4922-833f-632da07ffc11"},"reply":true}
    
    @JsonProperty("data")
        private JsonNode data;
    

提交回复
热议问题