[JBoss-user] [JBoss jBPM] - Re: Spring is in the air

2006-03-08 Thread etr480
"icyjamie" wrote : Of course. There was some glitches in the configuration for 
the session factory. It must depend on jbpmConfiguration, so:
  | 
  |   | - depends-on="jbpmConfiguration" for the sessionFactory (believe me, it 
is necessary :-))
  |   | - The addition of my favorite 
directories:-)/hibernate.queries.hbm.xml (the original has still errors 
(maybe other hibernate version), so I've made some changes)
  |   | 
  | Maybe this could be a starting point of a subproject (or module). I have no 
"template" or the like.
  | 
  | ObjectFactoryBeanFactoryAware
  | 
  |   | package myFavoritePackage;
  |   | import java.util.Map;
  |   | import org.jbpm.configuration.ObjectFactory;
  |   | import org.springframework.beans.BeansException;
  |   | import org.springframework.beans.factory.BeanFactory;
  |   | import org.springframework.beans.factory.BeanFactoryAware;
  |   | 
  |   | public class ObjectFactoryBeanFactoryAware implements ObjectFactory, 
BeanFactoryAware {
  |   | 
  |   | private BeanFactory beanFactory = null;
  |   | 
  |   | private Map resources = null;
  |   | 
  |   | public void setResources(Map resources) {
  |   | this.resources = resources;
  |   | }
  |   | 
  |   | private Object getResource(String name) {
  |   | return resources.get(name);
  |   | }
  |   | 
  |   | private boolean hasResource(String name) {
  |   | return resources.containsKey(name);
  |   | }
  |   | 
  |   | public Object createObject(String name) {
  |   | Object bean = getResource(name);
  |   | if (bean == null) {
  |   | bean = beanFactory.getBean(name);
  |   | }
  |   | return bean;
  |   | }
  |   | 
  |   | public boolean hasObject(String name) {
  |   | boolean found = hasResource(name);
  |   | if (!found) {
  |   | found = beanFactory.containsBean(name);
  |   | }
  |   | return found;
  |   | }
  |   | 
  |   | public void setBeanFactory(BeanFactory beanFactory) throws 
BeansException {
  |   | this.beanFactory = beanFactory;
  |   | 
  |   | }
  |   | 
  |   | }
  |   | 
  | SpringDbPersistenceService
  | We did not care about transaction management in the close method, because 
we use transaction demarcation on another level
  | If you really want to do this, it is easily extended
  | 
  |   | package myFavoritePackage;
  |   | 
  |   | import java.lang.reflect.Constructor;
  |   | 
  |   | import org.hibernate.Session;
  |   | import org.jbpm.db.ContextSession;
  |   | import org.jbpm.db.GraphSession;
  |   | import org.jbpm.db.LoggingSession;
  |   | import org.jbpm.db.MessagingSession;
  |   | import org.jbpm.db.SchedulerSession;
  |   | import org.jbpm.db.TaskMgmtSession;
  |   | import org.jbpm.persistence.db.DbPersistenceService;
  |   | import org.jbpm.persistence.db.DbPersistenceServiceFactory;
  |   | import org.springframework.orm.hibernate3.SessionFactoryUtils;
  |   | 
  |   | public class SpringDbPersistenceService extends DbPersistenceService {
  |   | 
  |   | private boolean isClosed = false;
  |   | private Class graphSessionClass = null;
  |   | private Class contextSessionClass = null;
  |   | private Class loggingSessionClass = null;
  |   | private Class messagingSessionClass = null;
  |   | private Class schedulerSessionClass = null;
  |   | private Class taskMgmtSessionClass = null;
  |   | 
  |   | public void setContextSessionClass(String contextSessionClass) 
throws Exception {
  |   | this.contextSessionClass = 
Class.forName(contextSessionClass);
  |   | }
  |   | 
  |   | public void setLoggingSessionClass(String loggingSessionClass) 
throws Exception {
  |   | this.loggingSessionClass = 
Class.forName(loggingSessionClass);
  |   | }
  |   | public void setMessagingSessionClass(String 
messagingSessionClass) throws Exception {
  |   | this.messagingSessionClass = 
Class.forName(messagingSessionClass);
  |   | }
  |   | public void setSchedulerSessionClass(String 
schedulerSessionClass) throws Exception {
  |   | this.schedulerSessionClass = 
Class.forName(schedulerSessionClass);
  |   | }
  |   | public void setTaskMgmtSessionClass(String 
taskMgmtSessionClass) throws Exception {
  |   | this.taskMgmtSessionClass = 
Class.forName(taskMgmtSessionClass);
  |   | }
  |   | public void setGraphSessionClass(String graphSessionClass) 
throws Exception {
  |   | this.graphSessionClass = 
Class.forName(graphSessionClass);
  |   | }
  |   | 
  |   | 
  |   | 
  |   |   

[JBoss-user] [JBoss jBPM] - Re: Spring is in the air

2006-03-07 Thread rosenjiang
integration with Spring, we need it!

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3928676#3928676

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3928676


---
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [JBoss jBPM] - Re: Spring is in the air

2006-02-28 Thread jbpmndc
You can view the latest Spring code in CVS
http://cvs.sourceforge.net/viewcvs.py/springframework/spring-projects/spring-jbpm/

There is a JBPMTemplate class that seems similar to HibernateTemplate

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3926919#3926919

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3926919


---
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [JBoss jBPM] - Re: Spring is in the air

2006-02-28 Thread admin
in case you didn't see it yet, there is a opportunity for the jbpm spring 
integration with the expressions.

jBPM 3.1 introduced the expressions.  actions, assignment handler and decision 
handlers can be referenced via a JSF/JSP-like EL expression language.   The 
VariableResolver is customizable.  So in a spring environment, the 
VariableResolver could be extended to search for the variables in the spring 
beans xml.  So you could define your delegation classes in spring instead of in 
the process...

regards, tom.

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3926904#3926904

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3926904


---
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [JBoss jBPM] - Re: Spring is in the air

2006-02-28 Thread Costin
anonymous wrote : I have looked jbpm 3.0 code ,please show some code for 
jbpm3.1 integration ?
  | Thank you
I'll commit the code in Spring Modules repository in the upcoming days (today 
dev.java.net CVS is down for maintainance).

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3926819#3926819

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3926819


---
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [JBoss jBPM] - Re: Spring is in the air

2006-02-28 Thread yuanhc
"icyjamie" wrote : Springify JpbmContext (singleton = FALSE !!). Inject 
services in it.
  | 
  | I want to know why you set JbpmContext not singleton ?
  | 
  | And I run a test, But in the method popThisContextFromTheStack of 
JpbmContext , it throw exception
  | 
  | Could you give me some advice?
  | 
  | Thank you!

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3926724#3926724

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3926724


---
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [JBoss jBPM] - Re: Spring is in the air

2006-02-27 Thread yuanhc
"Costin" wrote : Not sure if you are aware but there is already jbpm 
integration code available as part of Spring Modules 
(springmodules.dev.java.net).
  | Jbpm 3.1 has been already integrated but needs more tests - the code will 
be committed in the upcoming days.
  | See the forums for more information : 
http://forum.springframework.org/forumdisplay.php?f=37
  | 
  | The current code allows actions to be declared and injected from Spring 
application context. It is possible to use either a Spring application context 
or a configuration file for your jbpm configuration.
  | 
  | One nice feature is that it integrates with Spring transaction support.
  | You can find the current jbpm 3.0 code here: 
http://cvs.sourceforge.net/viewcvs.py/springframework/spring-projects/spring-jbpm/
  | 
  | In the upcoming days the jbpm 3.0 and 3.1 integration code will be moved to 
Spring Modules.

I have looked jbpm 3.0 code ,please show some code for jbpm3.1 integration ?
Thank you

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3926709#3926709

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3926709


---
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [JBoss jBPM] - Re: Spring is in the air

2006-02-27 Thread edgarpoce
good work costin!!!

br,
edgar

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3926552#3926552

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3926552


---
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [JBoss jBPM] - Re: Spring is in the air

2006-02-27 Thread Costin
Not sure if you are aware but there is already jbpm integration code available 
as part of Spring Modules (springmodules.dev.java.net).
Jbpm 3.1 has been already integrated but needs more tests - the code will be 
committed in the upcoming days.
See the forums for more information : 
http://forum.springframework.org/forumdisplay.php?f=37

The current code allows actions to be declared and injected from Spring 
application context. It is possible to use either a Spring application context 
or a configuration file for your jbpm configuration.

One nice feature is that it integrates with Spring transaction support.
You can find the current jbpm 3.0 code here: 
http://cvs.sourceforge.net/viewcvs.py/springframework/spring-projects/spring-jbpm/

In the upcoming days the jbpm 3.0 and 3.1 integration code will be moved to 
Spring Modules.

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3926543#3926543

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3926543


---
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user


[JBoss-user] [JBoss jBPM] - Re: Spring is in the air

2006-02-01 Thread icyjamie
Of course. There was some glitches in the configuration for the session 
factory. It must depend on jbpmConfiguration, so:

  | - depends-on="jbpmConfiguration" for the sessionFactory (believe me, it is 
necessary :-))
  | - The addition of my favorite 
directories:-)/hibernate.queries.hbm.xml (the original has still errors 
(maybe other hibernate version), so I've made some changes)
  | 
Maybe this could be a starting point of a subproject (or module). I have no 
"template" or the like.

ObjectFactoryBeanFactoryAware

  | package myFavoritePackage;
  | import java.util.Map;
  | import org.jbpm.configuration.ObjectFactory;
  | import org.springframework.beans.BeansException;
  | import org.springframework.beans.factory.BeanFactory;
  | import org.springframework.beans.factory.BeanFactoryAware;
  | 
  | public class ObjectFactoryBeanFactoryAware implements ObjectFactory, 
BeanFactoryAware {
  | 
  | private BeanFactory beanFactory = null;
  | 
  | private Map resources = null;
  | 
  | public void setResources(Map resources) {
  | this.resources = resources;
  | }
  | 
  | private Object getResource(String name) {
  | return resources.get(name);
  | }
  | 
  | private boolean hasResource(String name) {
  | return resources.containsKey(name);
  | }
  | 
  | public Object createObject(String name) {
  | Object bean = getResource(name);
  | if (bean == null) {
  | bean = beanFactory.getBean(name);
  | }
  | return bean;
  | }
  | 
  | public boolean hasObject(String name) {
  | boolean found = hasResource(name);
  | if (!found) {
  | found = beanFactory.containsBean(name);
  | }
  | return found;
  | }
  | 
  | public void setBeanFactory(BeanFactory beanFactory) throws 
BeansException {
  | this.beanFactory = beanFactory;
  | 
  | }
  | 
  | }
  | 
SpringDbPersistenceService
We did not care about transaction management in the close method, because we 
use transaction demarcation on another level
If you really want to do this, it is easily extended

  | package myFavoritePackage;
  | 
  | import java.lang.reflect.Constructor;
  | 
  | import org.hibernate.Session;
  | import org.jbpm.db.ContextSession;
  | import org.jbpm.db.GraphSession;
  | import org.jbpm.db.LoggingSession;
  | import org.jbpm.db.MessagingSession;
  | import org.jbpm.db.SchedulerSession;
  | import org.jbpm.db.TaskMgmtSession;
  | import org.jbpm.persistence.db.DbPersistenceService;
  | import org.jbpm.persistence.db.DbPersistenceServiceFactory;
  | import org.springframework.orm.hibernate3.SessionFactoryUtils;
  | 
  | public class SpringDbPersistenceService extends DbPersistenceService {
  | 
  | private boolean isClosed = false;
  | private Class graphSessionClass = null;
  | private Class contextSessionClass = null;
  | private Class loggingSessionClass = null;
  | private Class messagingSessionClass = null;
  | private Class schedulerSessionClass = null;
  | private Class taskMgmtSessionClass = null;
  | 
  | public void setContextSessionClass(String contextSessionClass) throws 
Exception {
  | this.contextSessionClass = Class.forName(contextSessionClass);
  | }
  | 
  | public void setLoggingSessionClass(String loggingSessionClass) throws 
Exception {
  | this.loggingSessionClass = Class.forName(loggingSessionClass);
  | }
  | public void setMessagingSessionClass(String messagingSessionClass) 
throws Exception {
  | this.messagingSessionClass = 
Class.forName(messagingSessionClass);
  | }
  | public void setSchedulerSessionClass(String schedulerSessionClass) 
throws Exception {
  | this.schedulerSessionClass = 
Class.forName(schedulerSessionClass);
  | }
  | public void setTaskMgmtSessionClass(String taskMgmtSessionClass) throws 
Exception {
  | this.taskMgmtSessionClass = Class.forName(taskMgmtSessionClass);
  | }
  | public void setGraphSessionClass(String graphSessionClass) throws 
Exception {
  | this.graphSessionClass = Class.forName(graphSessionClass);
  | }
  | 
  | 
  | 
  | SpringDbPersistenceService(DbPersistenceServiceFactory 
dbPersistenceServiceFactory) {
  | super(dbPersistenceServiceFactory);
  | }
  | 
  | Object createDbSession(Class clazz) {
  | try {
  | Constructor constructor = clazz.getConstructor(new 
Class[] {Session.class});
  | return constructor.newInstance(new Object[] 
{this.getSession()});
  | } catch (Exception e) {
  | throw new RuntimeException(e);
  | }
  | }
  | 
  | public Object createDbSession(Class beanClass, Class defaultClass) {
  | if (beanClass != null) {
  | 

[JBoss-user] [JBoss jBPM] - Re: Spring is in the air

2006-02-01 Thread tsandor
Your integration TODO and beans xml seems to be great.

Can you post your subclassed implementations? (e.g. 
jbpmObjectFactoryBeanFactoryAware, dbPersistenceService, 
persistenceServiceFactory, JbpmConfigurationFactoryBean)

-- 
Thomas

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3920920#3920920

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3920920


---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
___
JBoss-user mailing list
JBoss-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-user