I'm using spring-data Mongo (1.3.3) as a mechanism for accessing Mongo. My domain objects are written in Groovy and I use Jackson annotations to define properties and names:
@JsonProperty('is_author')
boolean author = false
@JsonProperty('author_info')
AuthorInfo authorInfo
When I persist one of my domain objects to Mongo, the JsonProperty annotation is ignored and the field is persisted using the standard object's field name.
By digging in the Spring Data Mongo documentation, I found out that the library expects a @Field annotation to modify the actual field's name in Mongo.
Is there a way to use only the Jackson annotations instead of using two annotations to achieve the same results. Maybe a "customized" version of MappingMongoConverter?