SpringMVC-装配-post-请求-某个对象成员为null

我在写一个博客项目,有文章实体类(Post)和评论实体类(Comment),Comment里有Post对象,多对一关系。我从,前端发过来的JSON为

// comment:
{
  id: null,
  text: 'xxxxxxx',
  post: {
    id: 'xxx-xxx',
    ...
  }
}

后台装配成的Comment对象中 text成员变量正常,但是post成员变量为null。反复检查无果,看到这篇博客https://blog.csdn.net/qq_41170102/article/details/105905761里提到一个@JsonProperty注解,加在实体类Comment中的post成员上,果然可以了,一度以为是post这个词出了什么问题。然后又是一通找,发现**忘记给成员post添加getter、setter方法了...**

另外,注解@JsonIgnore也会在装配时忽略该属性。