I am getting Null Pointer Exception while trying to retreving the history identityLinks in the following way.
HistoricIdentityLinkEntityManager historicIdentityLinkEntityManager=new HistoricIdentityLinkEntityManager();
List<HistoricIdentityLinkEntity> identityLinks=historicIdentityLinkEntityManager.
findHistoricIdentityLinksByTaskId(taskId);//Getting NullPointer Exception
for (HistoricIdentityLinkEntity identityLink: identityLinks)
{
if(identityLink.getType().equals(IdentityLinkType.CANDIDATE))
{
List<Group> groups = identityService.createGroupQuery().groupId(identityLink.getGroupId()).list();
for(Group group : groups)
{
System.out.println("group==>"+group.getId());
}
}
}
Whatever i am passing taskId that is present in table.I checked that one also.If anything mistake in my code tell me where did i mistaken.
Thanks &Regards
Sai Kumar R