0 Replies Latest reply on Nov 2, 2007 7:50 AM by Marcus Schmidke

    May I references ProcessInstances from my own entities?

    Marcus Schmidke Newbie

      Hello!

      I have a JBPM installation which integrates with my own Hibernate entities in a EJB3 container managed environment (with JbpmContext.setSession() and so on).

      It is no problem to store my own entities as process variables, for example.

      Is the inverse way even allowed?

      May I have a "ProcessInstance" reference in my entity?

      I've tried it. Of course, Hibernate does not complain about it. It simply loads the ProcessInstance entity if needed as it would load any other referenced entity. It seems to work.

      But are there pitfalls? What if I work with a ProcessInstance loaded this way? Will JBPM crash earlier or later if the ProcessInstance isn't load by JbpmContext.getProcessInstance()?

      Or is it legal to have JBPM's objects load directly from hibernate?


      Regards,

      Marcus.