Questions tagged [jackson2]

Use this tag only for questions specifically related to version 2 of the Jackson library

Jackson version 2 is a Java serialization and deserialization API typically used for reading and writing JSON, although other data formats such as Avro, CBOR, CSV, Java Properties, Protobuf, Smile, XML, and YAML are also supported.

464 questions
-1
votes
1 answer

With all configurations DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES not working

I tried all the solutions provided on these below SO threads: Jackson FAIL_ON_UNKNOWN_PROPERTIES to false not working jackson Unrecognized field Spring Boot Web- Set FAIL_ON_UNKNOWN_PROPERTIES to false in Jackson And around 10 more similar SO…
Ajay Kumar
  • 2,906
  • 3
  • 23
  • 46
-1
votes
1 answer

Using own jackson versions in Flink causes VerifyError

I'm using Apache Flink (v1.11) with Scala and added an own DeserializationSchema for Kafka connector. Therefore i would like to use my own packages and versions of jackson (v2.12.0). But i got the following error: Exception in thread "main"…
-1
votes
1 answer

convert json string to Java source code not working

I have a dynamic JSON schema that I need to convert to Java source code at run-time I found this Jackson example that seems very common The code is running fine, no exceptions but not generating anything. When I break the json structure (just to…
JavaSheriff
  • 7,074
  • 20
  • 89
  • 159
-1
votes
1 answer

Complex Java Object to Json

I have a java class like : public class Sclass { private Student student; private Teacher teacher; public Student getStudent() { return student; } public void setStudent(Student student) { this.student =…
Saurabh Jhunjhunwala
  • 2,832
  • 3
  • 29
  • 57
-1
votes
2 answers

Java spring boot JSON timestamp convert issue between two Java applications

I'm developing two java application which communicate with each other("backend1" and "backend2"). And I got this error: [{ "status": "BAD_REQUEST", "timestamp": "2018-07-11 02:54:28", "message": "Malformed JSON request", …
-1
votes
1 answer

How to make POJO and parse recursive objects using jackson?

I have a below JSON response that I am getting back from a rest service. Now I need to deserialize below JSON response into a POJO. I am working with Jackson. { "pagination": { "number": 1, "entriesPerPage": 200, "total":…
user1950349
  • 4,738
  • 19
  • 67
  • 119
-1
votes
1 answer

Realm Update Table Ignore Field

Following is Pojo are extended by realm , at first time getting all fields from api and i am using insertOrUpdate() operation of realm to dump data in realm. ServiceModel.java @JsonProperty("id") private String id; @JsonProperty("title") private…
Harshad07
  • 608
  • 7
  • 23
-1
votes
1 answer

deserialize a json array into a java object holding list

I'm getting a json array holding objects looking like this: [ { "id": "1", "name": "some name", "url": "some url", "active": true }, { "id": "2", "name": "some other name", "url": "some…
SwissArmyKnife
  • 200
  • 1
  • 12
-2
votes
1 answer

Read JSON property in Java

I am getting below output when I am calling postAPI from java. I want to store access_token in a variable but I am not able to do it. in javascript I can do it easily but in Java it is becoming difficult for me. Can anybody help me on the same. { …
Shruti sharma
  • 199
  • 6
  • 21
  • 67
-2
votes
1 answer

Jackson's json parsing

I'm a graduate student that is trying to learn how to parse json to objects using Jackson. I'm currently trying to parse this { "EmptyMessage":"", "EmptyMessageType":0, "Result":[ { "HasEducationPlan":false, …
-3
votes
2 answers

How can I break JSON in simplest form using Jackson

{ "first":"element", "second":"Integral", "isThird":false, "fourth":{ "ONE":[ { "100":"Cars" }, { "200":"Truck" } ], "TWO":[ { …
Tatkal
  • 568
  • 4
  • 9
  • 29
-3
votes
1 answer

Compare 2 Random Json String and return the difference as map

How Can i compare 2 random json strings and return the difference between them in java. I want to see the difference even when the order of the json object is different.
-3
votes
1 answer

Java Jackson JSON without property name

I have this JSON example { "name": "custom_text" } My Object look like public class NameObj { private String name; } And with readValue() method from Jackson can deserialized my json into NameObj. The real problem is when i don't have…
KunLun
  • 3,109
  • 3
  • 18
  • 65
-4
votes
1 answer

Jackson deserialize an object that implements an interface and ignore the interface properties

I have an annotated class that implements an interface with a read-only property named .id() that is generic so I can pull different types of ids in other parts of the program. This entire interface should be ignored by Jackson. But instead I get…
user177800
1 2 3
30
31