cancel
Showing results for 
Search instead for 
Did you mean: 

Activiti JPA support (activiti-spring-boot-starter-jpa) unable to detect generic primary key type

skpatel20
Champ in-the-making
Champ in-the-making
I've detailed my issue here: http://stackoverflow.com/questions/40765287/activiti-jpa-support-activiti-spring-boot-starter-jpa-un...

the question basically is, is it possible to use JPA support when the ID is a generic one?
1 REPLY 1

gdharley
Elite Collaborator
Elite Collaborator

Looking at the source, the only supported ID types are primitives. There is a comment in the code that goes:

Class<?> type = metaData.getIdType();
// According to JPA-spec all primitive types (and wrappers) are supported, String, util.Date, sql.Date, BigDecimal and BigInteger

By using a generic, the code is passing through a serializable that is not properly matched. Seems this would be a relatively easy override in the JPAEntityMappings class.