-
1. Re: Jbpm 6 - users and groups from database
dosten Oct 15, 2014 1:08 PM (in response to zmor)1 of 1 people found this helpfulThere a few UserGroupCallback implementations in JBPM 6. You can find the DB one here:
-
2. Re: Jbpm 6 - users and groups from database
zmor Oct 16, 2014 3:50 AM (in response to dosten)Thanks for the answer.
I've include this file to my project, just to add some logging info.
Problem is that i cant see in log file any invocation of methods like existsUser, existsGroup, getGroupsForUser,
and every time i claim task, which is assigned to admin group, i get following error:
User '[UserImpl:'some_user']' does not have permissions to execution operation 'Claim' on task id
This user is assigned to admin group, so I don't know where is the problem.
Somebody can help me?
-
3. Re: Jbpm 6 - users and groups from database
dosten Oct 16, 2014 10:07 AM (in response to zmor)Forgot to mention you have to register the new callback class.
Depending on how your application is architected, This can be done when making the environment (see this example).
Or you can declare it in beans.xml.
<beans xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://docs.jboss.org/cdi/beans_1_0.xsd">
<alternatives>
<class>org.jbpm.services.task.identity.DBBUserGroupCallbackImpl</class>
</alternatives>
</beans>
-
4. Re: Jbpm 6 - users and groups from database
zmor Oct 17, 2014 2:53 AM (in response to dosten)Sure, I know that.
It was produced in my environment builder class.
Problem was something else - I had another class based on UserGroupCallback, and i thought it was unused.
After deleting this class and adding this code
@Produces
public UserInfo produceUserInfo() {
return new DefaultUserInfo(true);
}
users and groups works perfectly.
Thanks for help.
KM
-
5. Re: Jbpm 6 - users and groups from database
imphilippesimo May 17, 2016 2:28 AM (in response to zmor)Hello, i also want to use my own users and groups tables, for the purpose i'm using mysql... in the examples given they are using H2Database to set up the environment.
...
JBPMHelper.startH2Server();
JBPMHelper.setupDataSource();
...
How can i manage to use mysql database to make the environment
-
6. Re: Jbpm 6 - users and groups from database
zcc39r May 17, 2016 4:20 AM (in response to imphilippesimo)