If you are using 5.2.0.Final you need to set
System.setProperty("jbpm.usergroup.callback", "org.jbpm.task.service.DefaultUserGroupCallbackImpl");
otherwise you need to insert the users and groups into TaskServiceSession which you are using into process.