[jboss-user] [jBPM] - jBPM for web

nt2005 do-not-reply at jboss.com
Thu Feb 16 13:56:51 EST 2012


nt2005 [https://community.jboss.org/people/nt2005] created the discussion

"jBPM for web"

To view the discussion, visit: https://community.jboss.org/message/717282#717282

--------------------------------------------------------------
Hey Guys,

English:
I am working on a web page where a user can start his own processes.

I use an stateful (ScopeType.Session) bean (Seam 2.2.2).

When the user open the site his ksession gets loaded:
@Create
public void initSession() {
 
EntityManagerFactory emf = entityManager.getEntityManagerFactory();
....
KnowledgeBuilder kbuilder = KnowledgeBuilderFactory.newKnowledgeBuilder();
....
ksession = JPAKnowledgeService.loadStatefulKnowledgeSession(usersession.getSessionid(), kbase, null, env);     
     
}


Than the user starts a process. When the process needs more time for calculation, my bean is not responding to my jsf-page. Because the thread is in the methode of startProcess().

My question is now: How I can run a process but also can interact with my jsf-page?
What seam components/types would be better or should I add? (ScopeType.Application maybe?) Anyone any idea?
I am not very firm in Seam.

I hope you understand my questions.  If not, please ask! Thank you.

Deutsch:
Ich arbeite an einer Webseite, in der Benutzer eigene Prozesse starten können.

Wenn ein Benutzer die Seite das erste Mal öffnet, wird seine eigene ksession geladen.
@Create
public void initSession() {

EntityManagerFactory emf = entityManager.getEntityManagerFactory();
....
KnowledgeBuilder kbuilder = KnowledgeBuilderFactory.newKnowledgeBuilder();
....
ksession = JPAKnowledgeService.loadStatefulKnowledgeSession(usersession.getSessionid(), kbase, null, env);     

}

Wenn ein Benutzer einen Prozess startet, der mehr Berechnungszeit braucht, antwortet logischerweise auch mein Bean nicht auf die Jsf-Anfragen meiner Seite. Da ja mein Bean zurzeit im startProcess() hängt.
Meine Frage ist nun, wie ich einen Prozess starten kann und mit den Bean dennoch normal weiter arbeiten kann.

Ich kenn mich mit Seam nicht wirklich gut aus aber muss ich da eventuell noch andere Seam Bean Komponenten mit einfügen (ScopeType.Application)?

Habt ihr eine Idee? Wenn noch fragen sind, bitte fragen.
Danke!
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/717282#717282]

Start a new discussion in jBPM at Community
[https://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/20120216/41a977da/attachment.html 


More information about the jboss-user mailing list