| Not sure I recall correctly. I did a quick test using simple and composite PK's. With a simple PK I get (using Redis JSON, see RedisJsonMappingTest.canStoreAndLoadEntitiesWithIdGeneratorAndAssociation):
27.0.0.1:6379> keys *
1) "Identifiers:myIds:Plant"
2) "Family:family-1"
3) "Plant:1"
127.0.0.1:6379> get "Family:family-1"
"{\"members\":[1],\"name\":\"Moraceae\"}"
127.0.0.1:6379> get "Plant:1"
"{\"height\":181}"
The reference to Plant is represented as
with a @OneToMany association. The ReferencedCompositeIdTest represents its data as
127.0.0.1:6379> keys *
1) "Tournament:{\"id.countryCode\":\"US\",\"id.sequenceNo\":\"456\"}"
2) "Director:bob"
3) "Tournament:{\"id.countryCode\":\"US\",\"id.sequenceNo\":\"123\"}"
127.0.0.1:6379> get "Director:bob"
"{\"directedTournament_id\":{\"sequenceNo\":\"456\",\"countryCode\":\"US\"},\"name\":\"Bob\"}"
the composite Id is a complex object in JSON
"directedTournament_id":{"sequenceNo":"456","countryCode":"US"}
Do you have a pointer to a test for me where I can see the non-simple Id storage? |