openjpa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Guillaume Chauvet (JIRA)" <>
Subject [jira] [Commented] (OPENJPA-2272) Unable to instantiate proxy for type "java.util.EnumMap"
Date Thu, 04 Oct 2012 08:47:07 GMT


Guillaume Chauvet commented on OPENJPA-2272:

Hello Rick,

Thank you for your quick answer. I will replace EnumMap by an HashMap, for the moment.
> Unable to instantiate proxy for type "java.util.EnumMap"
> --------------------------------------------------------
>                 Key: OPENJPA-2272
>                 URL:
>             Project: OpenJPA
>          Issue Type: Bug
>    Affects Versions: 2.2.0
>            Reporter: Guillaume Chauvet
> Dear OpenJPA team,
> I have defined a EnumMap collection field like this :
> @OneToMany(cascade = CascadeType.ALL, mappedBy = "settings")
> @MapKeyColumn(name = "ENUMKEY")
> @MapKeyEnumerated
> private Map<FilterType, Ponderation> ponderations = new EnumMap<FilterType,
> Generated tables are okay but when I launch my unit test I obtain this message :
> <openjpa-2.2.0-r422266:1244990 fatal store error> org.apache.openjpa.persistence.RollbackException:
Unable to instantiate proxy for type "java.util.EnumMap".  Make sure the class has a default
> I understand OpenJPA needs collections with default constructor, but EnumMap needs the
enum type as parameter. This means the EnumMap collection is not usable ?

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:

View raw message