Use distinct java type to implement entity primary keys