Steve Ebersole commented on Bug HHH-7645

Dmitry, your problem is completely unrelated to this. Your domain model is not defined correctly. At the very least it needs @MapKeyEnumerated on User.socialNetworkProfiles. It is also questionable to map the association this way. However, I pulled your domain model into our test suite to check MapKeyEnumerated handling. That worked for me:

@MapKeyEnumerated( EnumType.STRING )
	@MapKeyColumn(name = "social_network")
	@OneToMany(mappedBy = "user", fetch = FetchType.LAZY, cascade = CascadeType.ALL, orphanRemoval = true)
	private Map<SocialNetwork, SocialNetworkProfile> socialNetworkProfiles = new EnumMap<SocialNetwork, SocialNetworkProfile>(SocialNetwork.class);
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira