If I encounter a system user account during round robin assignment this method is called in an extension helper class:
function assignToNonSystemUser_Ext(group : Group) : void {
group.Users = group.MembersNoSystemUsers.where(\user -> user.User.Credential.Active and user.User.VacationStatus == VacationStatusType.TC_ATWORK)
this.assignUserByRoundRobin(false, group)
}
The issue is this is saving the filtered list of users to the DB which removes my system user from my group altogether.
I was expecting it would only operate on the group temporarily and not save the filtered list of users to my database.
If your extension function is called from an assignment rule, then any changes to the entity objects will be persisted in the database. The persistence of the Users in the group would also occur if called from a PCF which already had an implicit bundle created.
What Guidewire product/version are you working on? What entity is this function an extension of? If you post some more details I will update my answer.