[jboss-user] [jBPM] - Re: how to use our own datasource for organisational information in jbpm?
mani v
do-not-reply at jboss.com
Sun Sep 4 03:52:34 EDT 2011
mani v [http://community.jboss.org/people/maniv] created the discussion
"Re: how to use our own datasource for organisational information in jbpm?"
To view the discussion, visit: http://community.jboss.org/message/624630#624630
--------------------------------------------------------------
Apologies for late reply,
As depict below we could achieve redirecting org.jbpm.identity.hibernate.IdentitySession to our own datasource.
1. map customized datasource in hibernate_jbpm_identity.cfg.xml file.
2. configure hibernate_jbpm_identity.hbm.xml file using below entity w.r.t customized datasource table structure
org.jbpm.identity.User
org.jbpm.identity.Group
org.jbpm.identity.Membership
org.jbpm.identity.hibernate.PermissionUserType
3. public class IdentitySession extends
org.jbpm.identity.hibernate.IdentitySession
4. SessionFactory sessionFactory = new Configuration()
.configure("hibernate_jbpm_identity.cfg.xml")
.buildSessionFactory();
Session session = sessionFactory.openSession();
IdentitySession identitySession = new IdentitySession(session);
5. use now "session" reference in jbpm project which is having direction to customized ds... :)
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/624630#624630]
Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20110904/6dde44bb/attachment.html
More information about the jboss-user
mailing list