I'm trying to create a script that removes inactive users from a project role.
First I run an SQL query that gives me the inactive users still in a role. Then I try to execute this function for each entry in the SQL result:
projectRoleService.removeAllRoleActorsByNameAndType (it.user_name, it.NAME, errorCollection)
But I get the following error for each entry:
WARN [ofbiz.ConnectionPoolHealthSqlInterceptor]: Dangerous use of multiple connections: taken => count=2; marks=[1-0]; pool=29/20
WARN [ofbiz.ConnectionPoolHealthSqlInterceptor]: Dangerous use of multiple connections: replaced => count=1; marks=[0-0]; pool=28/20
Does anyone have an idea on how to avoid this issue?
I would not recommend manually modifying the database. Unless you have a really good understanding of the schema, you're asking for trouble. This is also not a supported modification.
It's easy to do this sort of thing using the Jira CLI. Check the examples page in their docs and search for "role" on the page to see example syntax.
I'm not manually modifying the database. I just use an SQL statement to get a list of inactive users in a role. The modification is done through the API:
projectRoleService.removeAllRoleActorsByNameAndType (it.user_name, it.NAME, errorCollection)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.