Use case which currently does not work: @Converts( { @Convert(attributeName = "key", converter = AccountIdConverter.class), @Convert(attributeName = "value", converter = CampaignIdConverter.class) }
) @ElementCollection @CollectionTable(name="campaigns", joinColumns=@JoinColumn(name="portal_id")) @MapKeyColumn(name = "account_id") @Column(name = "campaign_id") private Map<AccountId, CampaignId> campaigns;
In this case hibernate tries to serialize the map keys and values, because it ignores the @Converts annotation. The pull request fixes that.
|