79684996

Date: 2025-06-30 15:28:18
Score: 1.5
Natty:
Report link

Thanks Michael Peacock!

In InteliJ I had issue of getting null @RequestBody. I changed LOMBOK version to latest it doesn't work. Then I changed to Annotation processor path ="C:\Users\choks\.m2\repository\org\projectlombok\lombok\1.18.38\lombok-1.18.38.jar" still it was not working.

After putting

@JsonCreator as you suggested it is working fine.

@JsonCreator
    public Book( @JsonProperty("title") String title, @JsonProperty("author") String author, @JsonProperty("genre") String genre) {
        this.title = title;
        this.author = author;
        this.genre = genre;
    }
Reasons:
  • Blacklisted phrase (0.5): Thanks
  • Long answer (-0.5):
  • Has code block (-0.5):
  • User mentioned (1): @RequestBody
  • Low reputation (1):
Posted by: javaseeker