Hello. I am a user of JIRA DATA CENTER product. I am currently using Active Directory server to retrieve only users as read-only, and I have applied logic to delete the corresponding data from cwd_membership of DB through SQL to exclude certain users from certain groups. However, even after removing the permission, the result is that the user is logged in and is still added to certain groups. I am curious about the logic that JIRA DATA CENTER uses to manage group permissions and licenses.
[reference img - DB]

[reference img - GUI]

In addition, my goal is to develop an automated system that regularly reclaims unused user licenses