JBoss JBPM SVN: r4279 - projects/jsf-console/tags/jsf-console-3.2.6.SP2/soa/src/main/webapp/WEB-INF.
by do-not-reply@jboss.org
Author: alex.guizar(a)jboss.com
Date: 2009-03-18 09:35:40 -0400 (Wed, 18 Mar 2009)
New Revision: 4279
Removed:
projects/jsf-console/tags/jsf-console-3.2.6.SP2/soa/src/main/webapp/WEB-INF/jboss-web.xml
Log:
take out bad jboss-web descriptor
Deleted: projects/jsf-console/tags/jsf-console-3.2.6.SP2/soa/src/main/webapp/WEB-INF/jboss-web.xml
===================================================================
--- projects/jsf-console/tags/jsf-console-3.2.6.SP2/soa/src/main/webapp/WEB-INF/jboss-web.xml 2009-03-18 13:32:09 UTC (rev 4278)
+++ projects/jsf-console/tags/jsf-console-3.2.6.SP2/soa/src/main/webapp/WEB-INF/jboss-web.xml 2009-03-18 13:35:40 UTC (rev 4279)
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE jboss-web PUBLIC
- "-//JBoss//DTD Web Application 2.4//EN"
- "http://www.jboss.org/j2ee/dtd/jboss-web_4_0.dtd">
-
-<jboss-web>
- <!--
- Specify the security domain to use. This will be java:/jaas/<name> where
- <name> is one of the names configured in your login-config.xml.
- -->
- <security-domain>java:/jaas/soa</security-domain>
- <context-root>jbpm-console</context-root>
-
- <resource-ref>
- <res-ref-name>jdbc/JbpmDataSource</res-ref-name>
- <jndi-name>java:JbpmDS</jndi-name>
- </resource-ref>
-
- <resource-ref>
- <res-ref-name>jms/JbpmConnectionFactory</res-ref-name>
- <jndi-name>java:JmsXA</jndi-name>
- </resource-ref>
-
- <ejb-local-ref>
- <ejb-ref-name>ejb/TimerEntityBean</ejb-ref-name>
- <jndi-name>java:jbpm/TimerEntityBean</jndi-name>
- </ejb-local-ref>
-
- <message-destination-ref>
- <message-destination-ref-name>jms/JobQueue</message-destination-ref-name>
- <jndi-name>queue/JbpmJobQueue</jndi-name>
- </message-destination-ref>
-
-</jboss-web>
17 years, 1 month
JBoss JBPM SVN: r4278 - projects/jsf-console/branches/jsf-console-3.2.6.SP/soa/src/main/webapp/WEB-INF.
by do-not-reply@jboss.org
Author: alex.guizar(a)jboss.com
Date: 2009-03-18 09:32:09 -0400 (Wed, 18 Mar 2009)
New Revision: 4278
Modified:
projects/jsf-console/branches/jsf-console-3.2.6.SP/soa/src/main/webapp/WEB-INF/jboss-web.xml
Log:
JBPM-1446: correct bad tag name in jboss-web descriptor
Modified: projects/jsf-console/branches/jsf-console-3.2.6.SP/soa/src/main/webapp/WEB-INF/jboss-web.xml
===================================================================
--- projects/jsf-console/branches/jsf-console-3.2.6.SP/soa/src/main/webapp/WEB-INF/jboss-web.xml 2009-03-18 13:24:51 UTC (rev 4277)
+++ projects/jsf-console/branches/jsf-console-3.2.6.SP/soa/src/main/webapp/WEB-INF/jboss-web.xml 2009-03-18 13:32:09 UTC (rev 4278)
@@ -23,7 +23,7 @@
<ejb-local-ref>
<ejb-ref-name>ejb/TimerEntityBean</ejb-ref-name>
- <jndi-name>java:jbpm/TimerEntityBean</jndi-name>
+ <local-jndi-name>java:jbpm/TimerEntityBean</local-jndi-name>
</ejb-local-ref>
<message-destination-ref>
17 years, 1 month
JBoss JBPM SVN: r4277 - in jbpm3/branches/jbpm-3.2.5.SP: hudson/hudson-home and 1 other directories.
by do-not-reply@jboss.org
Author: alex.guizar(a)jboss.com
Date: 2009-03-18 09:24:51 -0400 (Wed, 18 Mar 2009)
New Revision: 4277
Modified:
jbpm3/branches/jbpm-3.2.5.SP/hudson/hudson-home/command.sh
jbpm3/branches/jbpm-3.2.5.SP/modules/enterprise/src/main/resources/META-INF/jboss.xml
jbpm3/branches/jbpm-3.2.5.SP/pom.xml
Log:
JBPM-1446: upgrade jsf-console dependency to 3.2.6.SP2
Modified: jbpm3/branches/jbpm-3.2.5.SP/hudson/hudson-home/command.sh
===================================================================
--- jbpm3/branches/jbpm-3.2.5.SP/hudson/hudson-home/command.sh 2009-03-18 10:53:23 UTC (rev 4276)
+++ jbpm3/branches/jbpm-3.2.5.SP/hudson/hudson-home/command.sh 2009-03-18 13:24:51 UTC (rev 4277)
@@ -36,7 +36,7 @@
# Build distro
#
cd $JBPMDIR
-MVN_CMD="mvn -U $ENVIRONMENT -Pdistro clean install"
+MVN_CMD="mvn -U $ENVIRONMENT -Pdistro,soa clean install"
echo $MVN_CMD; $MVN_CMD; MVN_STATUS=$?
if [ $MVN_STATUS -ne 0 ]; then
echo maven exit status $MVN_STATUS
Modified: jbpm3/branches/jbpm-3.2.5.SP/modules/enterprise/src/main/resources/META-INF/jboss.xml
===================================================================
--- jbpm3/branches/jbpm-3.2.5.SP/modules/enterprise/src/main/resources/META-INF/jboss.xml 2009-03-18 10:53:23 UTC (rev 4276)
+++ jbpm3/branches/jbpm-3.2.5.SP/modules/enterprise/src/main/resources/META-INF/jboss.xml 2009-03-18 13:24:51 UTC (rev 4277)
@@ -47,8 +47,8 @@
<entity>
<ejb-name>TimerEntityBean</ejb-name>
- <jndi-name>ejb/TimerEntityBean</jndi-name>
- <local-jndi-name>java:ejb/TimerEntityBean</local-jndi-name>
+ <jndi-name>jbpm/TimerEntityBean</jndi-name>
+ <local-jndi-name>java:jbpm/TimerEntityBean</local-jndi-name>
</entity>
</enterprise-beans>
Modified: jbpm3/branches/jbpm-3.2.5.SP/pom.xml
===================================================================
--- jbpm3/branches/jbpm-3.2.5.SP/pom.xml 2009-03-18 10:53:23 UTC (rev 4276)
+++ jbpm3/branches/jbpm-3.2.5.SP/pom.xml 2009-03-18 13:24:51 UTC (rev 4277)
@@ -69,8 +69,8 @@
<javax.persistence.version>1.0</javax.persistence.version>
<javax.jaxb.version>2.1</javax.jaxb.version>
<jaxen.version>1.1.1</jaxen.version>
- <jbpm.designer.version>3.1.6</jbpm.designer.version>
- <jbpm.jsf-console.version>3.3.1.GA</jbpm.jsf-console.version>
+ <jbpm.designer.version>3.1.7</jbpm.designer.version>
+ <jbpm.jsf-console.version>3.2.6.SP2</jbpm.jsf-console.version>
<jboss.client.version>4.2.2.GA</jboss.client.version>
<jboss.gravel.version>1.0.0.GA</jboss.gravel.version>
<jboss.seam.version>2.0.2.GA</jboss.seam.version>
17 years, 1 month
JBoss JBPM SVN: r4276 - jbpm4/trunk/modules/enterprise/src/main/java/org/jbpm/enterprise/internal/ejb.
by do-not-reply@jboss.org
Author: heiko.braun(a)jboss.com
Date: 2009-03-18 06:53:23 -0400 (Wed, 18 Mar 2009)
New Revision: 4276
Modified:
jbpm4/trunk/modules/enterprise/src/main/java/org/jbpm/enterprise/internal/ejb/CommandExecutorSLSB.java
Log:
CommandExecutorSLSB references java:/ProcessEngine
Modified: jbpm4/trunk/modules/enterprise/src/main/java/org/jbpm/enterprise/internal/ejb/CommandExecutorSLSB.java
===================================================================
--- jbpm4/trunk/modules/enterprise/src/main/java/org/jbpm/enterprise/internal/ejb/CommandExecutorSLSB.java 2009-03-18 10:52:14 UTC (rev 4275)
+++ jbpm4/trunk/modules/enterprise/src/main/java/org/jbpm/enterprise/internal/ejb/CommandExecutorSLSB.java 2009-03-18 10:53:23 UTC (rev 4276)
@@ -29,18 +29,22 @@
import javax.naming.InitialContext;
import javax.naming.NameNotFoundException;
import javax.naming.NamingException;
+import javax.transaction.UserTransaction;
+import javax.transaction.SystemException;
import org.jbpm.Configuration;
+import org.jbpm.ProcessEngine;
import org.jbpm.cmd.Command;
+import org.jbpm.cmd.CommandService;
import org.jbpm.env.Environment;
import org.jbpm.env.EnvironmentFactory;
import org.jbpm.internal.log.Log;
/**
* Stateless session command executor.
- *
+ *
* <h3>Configuration</h3>
- *
+ *
* <p>
* In order to provide commands an environment in which to run, the command
* executor builds an environment factory from a configuration file loaded as a
@@ -48,9 +52,9 @@
* specifies the name of the resource to access; the default is
* <code>jbpm.cfg.xml</code>.
* </p>
- *
+ *
* <h3>JNDI-bound environment factory</h3>
- *
+ *
* <p>
* To avoid parsing the configuration file multiple times, the command executor
* attempts to bind the environment factory to the name specified in the
@@ -59,7 +63,7 @@
* command executor will still work; however, each instance will build its own
* environment factory from the configuration.
* </p>
- *
+ *
* @author Jim Rigsbee
* @author Tom Baeyens
* @author Alejandro Guizar
@@ -73,7 +77,9 @@
private static final Log log = Log.getLog(CommandExecutorSLSB.class.getName());
- public <T> T execute(Command<T> command) {
+ private ProcessEngine processEngine = null;
+
+ /*public <T> T execute(Command<T> command) {
Environment environment = environmentFactory.openEnvironment();
try {
log.debug("executing command " + command);
@@ -88,6 +94,12 @@
finally {
environment.close();
}
+ } */
+
+ public <T> T execute(Command<T> command) {
+ log.info("Execute " + command);
+ CommandService cmd = processEngine.get(CommandService.class);
+ return cmd.execute(command);
}
public void setSessionContext(SessionContext sessionContext) {
@@ -99,7 +111,18 @@
* are passed in the execute method.
*/
public void ejbCreate() throws CreateException {
- String envFactoryName = "java:jbpm/EnvironmentFactory";
+
+ try
+ {
+ InitialContext ctx = new InitialContext();
+ this.processEngine = (ProcessEngine)ctx.lookup("java:/ProcessEngine");
+ }
+ catch (Exception e)
+ {
+ throw new RuntimeException("Failed to lookup process engine");
+ }
+
+ /*String envFactoryName = "java:jbpm/EnvironmentFactory";
try {
Context initial = new InitialContext();
@@ -119,12 +142,7 @@
environmentFactory = (EnvironmentFactory) namedObject;
}
else {
- /*
- * the bound object could be an instance of an environment factory
- * loaded in another (older?) deployment; because each deployment sets
- * up its own class loader, the existing instance could be perceived
- * as not being an environment factory
- */
+
if (namedObject == null || isInstance(EnvironmentFactory.class.getName(), namedObject)) {
log.debug("object bound to "
+ envFactoryName
@@ -153,6 +171,9 @@
log.error("could not create command executor", e);
throw new CreateException("jndi access failed");
}
+
+ */
+
}
private static boolean isInstance(String className, Object object) {
@@ -190,6 +211,7 @@
}
public void ejbRemove() {
+ processEngine = null;
environmentFactory = null;
sessionContext = null;
}
17 years, 1 month
JBoss JBPM SVN: r4275 - in jbpm4/trunk: modules/distro/src/main/resources/config-tool and 1 other directory.
by do-not-reply@jboss.org
Author: tom.baeyens(a)jboss.com
Date: 2009-03-18 06:52:14 -0400 (Wed, 18 Mar 2009)
New Revision: 4275
Modified:
jbpm4/trunk/bin/test.distro.bat
jbpm4/trunk/modules/distro/src/main/resources/config-tool/build.xml
jbpm4/trunk/modules/distro/src/main/resources/config-tool/jdbc.properties
Log:
fixed jdbc property resolution
Modified: jbpm4/trunk/bin/test.distro.bat
===================================================================
--- jbpm4/trunk/bin/test.distro.bat 2009-03-18 10:28:53 UTC (rev 4274)
+++ jbpm4/trunk/bin/test.distro.bat 2009-03-18 10:52:14 UTC (rev 4275)
@@ -10,8 +10,12 @@
set JBOSS_HOME=C:\Software\jboss-%JBOSS_VERSION%
cd %JBPM4_ROOT%
+set ERRORLEVEL=0
cmd /C mvn -DskipTests -Pdistro -Ddatabase=%DATABASE% -Djbpm.target.container=%CONTAINER% -Djboss.home=%JBOSS_HOME% clean install
+if ERRORLEVEL 1 goto end
rmdir /S /Q %JBOSS_HOME%
unzip -q %JBOSS_DISTRO_FILE% -d c:\Software
java -DTRACE -jar modules\distro\target\jbpm-installer-%JBPM_VERSION%.jar modules\distro\target\resources\auto-install-template.xml
start "JBoss" %JBOSS_HOME%\bin\run.bat
+
+:end
Modified: jbpm4/trunk/modules/distro/src/main/resources/config-tool/build.xml
===================================================================
--- jbpm4/trunk/modules/distro/src/main/resources/config-tool/build.xml 2009-03-18 10:28:53 UTC (rev 4274)
+++ jbpm4/trunk/modules/distro/src/main/resources/config-tool/build.xml 2009-03-18 10:52:14 UTC (rev 4275)
@@ -251,9 +251,17 @@
<delete dir="${tmp.dir}" />
<mkdir dir="${config.files.dir}" />
<mkdir dir="${resolved.dir}" />
+ <copy todir="${tmp.dir}"
+ file="jdbc.properties"
+ failonerror="false"
+ overwrite="true" />
+ <copy todir="${tmp.dir}"
+ file="${user.home}/.jbpm4/jdbc.properties"
+ failonerror="false"
+ overwrite="true" />
<copy todir="${resolved.dir}" filtering="true">
<fileset dir="." />
- <filterset filtersfile="jdbc.properties">
+ <filterset filtersfile="${tmp.dir}/jdbc.properties">
<filter token="jboss.bind.address" value="${jboss.bind.address}"/>
<filter token="jdbc.hsqldb.url" value="${jdbc.hsqldb.url}" />
</filterset>
Modified: jbpm4/trunk/modules/distro/src/main/resources/config-tool/jdbc.properties
===================================================================
--- jbpm4/trunk/modules/distro/src/main/resources/config-tool/jdbc.properties 2009-03-18 10:28:53 UTC (rev 4274)
+++ jbpm4/trunk/modules/distro/src/main/resources/config-tool/jdbc.properties 2009-03-18 10:52:14 UTC (rev 4275)
@@ -1,29 +1,29 @@
jdbc.mysql.server=localhost
jdbc.mysql.port=3306
-jdbc.mysql.database=jbpm
-jdbc.mysql.url=jdbc:mysql://localhost:3306/jbpm
-jdbc.mysql.username=jbpm
-jdbc.mysql.password=jbpm
+jdbc.mysql.database=jbpm4
+jdbc.mysql.url=jdbc:mysql://${jdbc.mysql.server}:${jdbc.mysql.port}/${jdbc.mysql.database}
+jdbc.mysql.username=jbpmtest
+jdbc.mysql.password=
jdbc.postgresql.server=localhost
jdbc.postgresql.port=5432
-jdbc.postgresql.database=jbpm
-jdbc.postgresql.url=jdbc:postgresql://localhost:5432/jbpm
-jdbc.postgresql.username=jbpm
-jdbc.postgresql.password=jbpm
+jdbc.postgresql.database=jbpm4
+jdbc.postgresql.url=jdbc:postgresql://${jdbc.postgresql.server}:${jdbc.postgresql.port}/${jdbc.postgresql.database}
+jdbc.postgresql.username=jbpmtest
+jdbc.postgresql.password=
jdbc.sybase.server=localhost
jdbc.sybase.port=5000
-jdbc.sybase.database=jbpm
-jdbc.sybase.url=jdbc:sybase:Tds:localhost:5000/jbpm
-jdbc.sybase.username=jbpm
-jdbc.sybase.password=jbpm
+jdbc.sybase.database=jbpm4
+jdbc.sybase.url=jdbc:sybase:Tds:${jdbc.sybase.server}:${jdbc.sybase.port}/${jdbc.sybase.database}
+jdbc.sybase.username=jbpmtest
+jdbc.sybase.password=jbpmtest
jdbc.sybase.driver=com.sybase.jdbc3.jdbc.SybDriver
jdbc.sybase.datasource=com.sybase.jdbc3.jdbc.SybXADataSource
jdbc.oracle.server=localhost
jdbc.oracle.port=1521
jdbc.oracle.database=XE
-jdbc.oracle.username=jbpm
-jdbc.oracle.password=jbpm
-jdbc.oracle.url=jdbc:oracle:thin:@localhost:1521:XE
+jdbc.oracle.username=jbpmtest
+jdbc.oracle.password=jbpmtest
+jdbc.oracle.url=jdbc:oracle:thin:${jdbc.oracle.username}/${jdbc.oracle.password}@${jdbc.oracle.server}:${jdbc.oracle.port}:${jdbc.oracle.database}
17 years, 1 month
JBoss JBPM SVN: r4274 - in jbpm4/trunk/modules: integration/jboss4/src/main/resources/jbpm.beans/META-INF and 1 other directory.
by do-not-reply@jboss.org
Author: heiko.braun(a)jboss.com
Date: 2009-03-18 06:28:53 -0400 (Wed, 18 Mar 2009)
New Revision: 4274
Modified:
jbpm4/trunk/modules/distro/src/main/resources/installer/install-definition.xml
jbpm4/trunk/modules/integration/jboss4/src/main/resources/jbpm.beans/META-INF/jboss-beans.xml
Log:
Fix as installtion
Modified: jbpm4/trunk/modules/distro/src/main/resources/installer/install-definition.xml
===================================================================
--- jbpm4/trunk/modules/distro/src/main/resources/installer/install-definition.xml 2009-03-18 09:20:51 UTC (rev 4273)
+++ jbpm4/trunk/modules/distro/src/main/resources/installer/install-definition.xml 2009-03-18 10:28:53 UTC (rev 4274)
@@ -152,27 +152,18 @@
<description>The Install jBPM in JBoss</description>
- <!-- jbpm/jbpm-service.sar
- <fileset dir="@{deploy.artifacts.dir}/resources/jbpm-jpdl-config" targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-service.sar" override="true">
- <include name="logging.properties"/>
- </fileset>
- -->
-
- <!-- jbpm/jbpm-service.sar , enterprise config-->
+ <!-- jbpm/jbpm-service.sar , spi config-->
<fileset dir="@{deploy.artifacts.dir}/resources/jbpm-spi-config" targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-service.sar" override="true">
<include name="jbpm-users.properties"/>
<include name="jbpm-roles.properties"/>
</fileset>
- <!-- jbpm/jbpm-service.sar/META-INF , enterprise config-->
- <fileset dir="@{deploy.artifacts.dir}/resources/jbpm-enterprise-config" targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-service.sar/META-INF" override="true">
+ <fileset dir="@{deploy.artifacts.dir}/resources/jbpm-spi-config" targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-service.sar/META-INF" override="true">
<include name="jboss-service.xml"/>
</fileset>
<fileset dir="@{deploy.artifacts.dir}/lib" targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-service.sar" override="true">
- <include name="jbpm-log.jar" />
<include name="jbpm-pvm.jar" />
- <include name="jbpm-jpdl.jar" />
- <include name="jbpm-task.jar" />
+ <include name="jbpm-jpdl.jar" />
<include name="jbpm-console-integration.jar" />
<include name="idm*.jar" />
<include name="livetribe-jsr223.jar" />
@@ -203,7 +194,28 @@
<include name="jbpm-log.jar" />
</fileset>
+ <!-- deployer -->
+ <fileset dir="@{deploy.artifacts.dir}/lib/"
+ targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm.deployer"
+ override="true"
+ condition="isJBoss422">
+ <include name="jbpm-jboss4.jar"/>
+ </fileset>
+ <fileset dir="@{deploy.artifacts.dir}/resources/jbpm-jboss4-config/jbpm.deployer/META-INF"
+ targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm.deployer/META-INF"
+ override="true"
+ condition="isJBoss422">
+ <include name="jboss-service.xml"/>
+ </fileset>
+ <!-- service -->
+ <fileset dir="@{deploy.artifacts.dir}/resources/jbpm-jboss4-config/jbpm.beans/META-INF"
+ targetdir="${jbossInstallPath}/server/${jbossTargetServer}/deploy/jbpm/jbpm-service.sar/jbpm.beans/META-INF"
+ override="true"
+ condition="isJBoss422">
+ <include name="jboss-beans.xml"/>
+ </fileset>
+
<!--
==============================
JBoss 423
Modified: jbpm4/trunk/modules/integration/jboss4/src/main/resources/jbpm.beans/META-INF/jboss-beans.xml
===================================================================
--- jbpm4/trunk/modules/integration/jboss4/src/main/resources/jbpm.beans/META-INF/jboss-beans.xml 2009-03-18 09:20:51 UTC (rev 4273)
+++ jbpm4/trunk/modules/integration/jboss4/src/main/resources/jbpm.beans/META-INF/jboss-beans.xml 2009-03-18 10:28:53 UTC (rev 4274)
@@ -24,7 +24,7 @@
ServerConfig
-->
<bean name="org.jbpm:service=ServerConfig"
- class="org.jbpm.integration.jboss5.mgmt.ServerConfig">
+ class="org.jbpm.integration.jboss4.mgmt.ServerConfig">
</bean>
</deployment>
\ No newline at end of file
17 years, 1 month
JBoss JBPM SVN: r4273 - jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi.
by do-not-reply@jboss.org
Author: heiko.braun(a)jboss.com
Date: 2009-03-18 05:20:51 -0400 (Wed, 18 Mar 2009)
New Revision: 4273
Added:
jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/JBPMService.java
Log:
fix missing JBPMService.java
Added: jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/JBPMService.java
===================================================================
--- jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/JBPMService.java (rev 0)
+++ jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/JBPMService.java 2009-03-18 09:20:51 UTC (rev 4273)
@@ -0,0 +1,90 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.integration.spi;
+
+import org.jbpm.Configuration;
+import org.jbpm.ProcessEngine;
+import org.jbpm.integration.spi.mgmt.ServerConfig;
+import org.jbpm.internal.log.Log;
+
+import javax.naming.InitialContext;
+
+/**
+ * @author Heiko.Braun <heiko.braun(a)jboss.com>
+ */
+public class JBPMService
+{
+ private static final Log log = Log.getLog(JBPMService.class.getName());
+
+ private final static String DEFAULT_JNDI_NAME = "java:/ProcessEngine";
+
+ private ProcessEngine processEngine;
+
+ // MC injected
+ private ServerConfig serverConfig;
+
+ // can be MC injected
+ private String jndiName = DEFAULT_JNDI_NAME;
+
+ public void start()
+ {
+ this.processEngine = new Configuration().buildProcessEngine();
+
+ try
+ {
+ InitialContext ctx = new InitialContext();
+ ctx.bind(DEFAULT_JNDI_NAME, new ProcessEngineReference("default", this.processEngine));
+
+ // debug out
+ log.info(serverConfig.getImplementationTitle());
+ log.info(serverConfig.getImplementationVersion());
+ log.info("ProcessEngine bound to: " + this.jndiName);
+ }
+
+ catch (Exception e)
+ {
+ throw new RuntimeException("Failed to create JBPMService", e);
+ }
+
+ }
+
+ public void stop()
+ {
+ this.processEngine = null;
+ log.info("JBPMService stopped");
+ }
+
+ public ProcessEngine getProcessEngine()
+ {
+ return this.processEngine;
+ }
+
+ public void setServerConfig(ServerConfig serverConfig)
+ {
+ this.serverConfig = serverConfig;
+ }
+
+ public void setJndiName(String jndiName)
+ {
+ this.jndiName = jndiName;
+ }
+}
17 years, 1 month
JBoss JBPM SVN: r4272 - jbpm4/trunk/modules/jpdl.
by do-not-reply@jboss.org
Author: heiko.braun(a)jboss.com
Date: 2009-03-18 05:01:48 -0400 (Wed, 18 Mar 2009)
New Revision: 4272
Modified:
jbpm4/trunk/modules/jpdl/pom.xml
Log:
Exclude DbGenTest for now
Modified: jbpm4/trunk/modules/jpdl/pom.xml
===================================================================
--- jbpm4/trunk/modules/jpdl/pom.xml 2009-03-18 08:27:46 UTC (rev 4271)
+++ jbpm4/trunk/modules/jpdl/pom.xml 2009-03-18 09:01:48 UTC (rev 4272)
@@ -67,6 +67,16 @@
<!-- Plugins -->
<build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <configuration>
+ <excludes>
+ <exclude>org/jbpm/test/xml/DbGenTest.java</exclude>
+ </excludes>
+ </configuration>
+ </plugin>
+ </plugins>
</build>
<!-- Profiles -->
17 years, 1 month
JBoss JBPM SVN: r4271 - in jbpm4/trunk/modules: enterprise/src/test/java/org/jbpm/test and 16 other directories.
by do-not-reply@jboss.org
Author: heiko.braun(a)jboss.com
Date: 2009-03-18 04:27:46 -0400 (Wed, 18 Mar 2009)
New Revision: 4271
Added:
jbpm4/trunk/modules/enterprise/src/test/java/org/jbpm/test/classloading/
jbpm4/trunk/modules/enterprise/src/test/java/org/jbpm/test/classloading/CustomClass.java
jbpm4/trunk/modules/enterprise/src/test/resources/classloading/
jbpm4/trunk/modules/enterprise/src/test/resources/classloading/META-INF/
jbpm4/trunk/modules/enterprise/src/test/resources/classloading/META-INF/process.jpdl.xml
jbpm4/trunk/modules/integration/jboss4/src/main/java/org/jbpm/integration/jboss4/mgmt/
jbpm4/trunk/modules/integration/jboss4/src/main/java/org/jbpm/integration/jboss4/mgmt/ServerConfig.java
jbpm4/trunk/modules/integration/jboss5/src/main/java/org/jbpm/integration/jboss5/mgmt/
jbpm4/trunk/modules/integration/jboss5/src/main/java/org/jbpm/integration/jboss5/mgmt/ServerConfig.java
jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/mgmt/
jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/mgmt/AbstractServerConfig.java
jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/mgmt/AbstractServerConfigMBean.java
jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/mgmt/ServerConfig.java
jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/mgmt/ServerConfigFactory.java
jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/util/ObjectNameFactory.java
Removed:
jbpm4/trunk/modules/integration/jboss5/src/main/resources/META-INF/jbpm.deployer.cfg.xml
jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/JBPMService.java
Modified:
jbpm4/trunk/modules/enterprise/scripts/antrun-test-jars.xml
jbpm4/trunk/modules/enterprise/src/test/java/org/jbpm/test/deployer/DeployerTestCase.java
jbpm4/trunk/modules/integration/console/src/main/java/org/jbpm/integration/console/ProcessManagementImpl.java
jbpm4/trunk/modules/integration/jboss4/src/main/java/org/jbpm/integration/jboss4/JBPMDeployer.java
jbpm4/trunk/modules/integration/jboss4/src/main/resources/jbpm.beans/META-INF/jboss-beans.xml
jbpm4/trunk/modules/integration/jboss5/src/main/resources/META-INF/jbpm-service-jboss-beans.xml
jbpm4/trunk/modules/integration/spi/src/main/resources/jboss-service.xml
Log:
Deployer exception handling. Classloading test stub. ServerConfig added
Modified: jbpm4/trunk/modules/enterprise/scripts/antrun-test-jars.xml
===================================================================
--- jbpm4/trunk/modules/enterprise/scripts/antrun-test-jars.xml 2009-03-18 08:26:36 UTC (rev 4270)
+++ jbpm4/trunk/modules/enterprise/scripts/antrun-test-jars.xml 2009-03-18 08:27:46 UTC (rev 4271)
@@ -10,64 +10,76 @@
<project>
- <description>PVM test archive</description>
+ <description>PVM test archive</description>
- <target name="build-jars" description="Build the test modules.">
+ <target name="build-jars" description="Build the test modules.">
- <mkdir dir="${build.dir}/test-libs"/>
+ <mkdir dir="${build.dir}/test-libs"/>
- <war destfile="${build.dir}/test-libs/jbpm-enterprise-test.war"
+ <war destfile="${build.dir}/test-libs/jbpm-enterprise-test.war"
webxml="${test.resources.dir}/command/WEB-INF/web.xml">
- <webinf dir="${test.resources.dir}/command/WEB-INF">
- <exclude name="web.xml" />
- </webinf>
+ <webinf dir="${test.resources.dir}/command/WEB-INF">
+ <exclude name="web.xml" />
+ </webinf>
<lib dir="${build.dir}/test-dependencies">
<include name="aspectjrt*.jar"/>
<include name="cactus*.jar"/>
<include name="junit*.jar"/>
</lib>
- <classes dir="${build.dir}/test-classes">
- <include name="org/jbpm/test/enterprise/*" />
- <include name="org/jbpm/enterprise/internal/ejb/*" />
- </classes>
- </war>
+ <classes dir="${build.dir}/test-classes">
+ <include name="org/jbpm/test/enterprise/*" />
+ <include name="org/jbpm/enterprise/internal/ejb/*" />
+ </classes>
+ </war>
- <jar destfile="${build.dir}/test-libs/jbpm-enterprise-test.jar">
- <fileset dir="${build.dir}/test-classes">
- <include name="org/jbpm/enterprise/internal/custom/*" />
- </fileset>
- </jar>
+ <jar destfile="${build.dir}/test-libs/jbpm-enterprise-test.jar">
+ <fileset dir="${build.dir}/test-classes">
+ <include name="org/jbpm/enterprise/internal/custom/*" />
+ </fileset>
+ </jar>
- <ear destfile="${build.dir}/test-libs/jbpm-enterprise-test.ear"
+ <ear destfile="${build.dir}/test-libs/jbpm-enterprise-test.ear"
appxml="${test.resources.dir}/command/META-INF/application.xml">
- <!-- build artifact -->
- <fileset dir="${build.dir}" includes="${build.finalName}.jar" />
- <!-- test modules -->
- <fileset dir="${build.dir}/test-libs" includes="jbpm-enterprise-test.war" />
- <zipfileset dir="${build.dir}/test-libs" includes="jbpm-enterprise-test.jar" prefix="lib" />
-
- </ear>
+ <!-- build artifact -->
+ <fileset dir="${build.dir}" includes="${build.finalName}.jar" />
+ <!-- test modules -->
+ <fileset dir="${build.dir}/test-libs" includes="jbpm-enterprise-test.war" />
+ <zipfileset dir="${build.dir}/test-libs" includes="jbpm-enterprise-test.jar" prefix="lib" />
- <!-- Please add alphabetically -->
+ </ear>
+ <!-- Please add alphabetically -->
+
+ <!-- jbpm-classloading-test-->
+ <jar destfile="${build.dir}/test-libs/jbpm-classloading-test.jar">
+ <fileset dir="${build.dir}/test-classes">
+ <include name="org/jbpm/test/classloading/*" />
+ </fileset>
+ <fileset dir="${build.dir}/test-classes/classloading">
+ <include name="META-INF/*" />
+ </fileset>
+ </jar>
+
+
+ <!-- jbpm-deployer-test -->
<jar destfile="${build.dir}/test-libs/jbpm-deployer-test.jar">
- <fileset dir="${build.dir}/test-classes">
- <include name="org/jbpm/test/deployer/*" />
- </fileset>
+ <fileset dir="${build.dir}/test-classes">
+ <include name="org/jbpm/test/deployer/*" />
+ </fileset>
<fileset dir="${build.dir}/test-classes/deployer">
- <include name="META-INF/*" />
- </fileset>
+ <include name="META-INF/*" />
+ </fileset>
</jar>
<war destfile="${build.dir}/test-libs/jbpm-deployer-test.war"
webxml="${test.resources.dir}/deployer/WEB-INF/web.xml">
- <webinf dir="${test.resources.dir}/deployer/WEB-INF">
- <exclude name="web.xml" />
- </webinf>
- <classes dir="${build.dir}/test-classes">
- <include name="org/jbpm/test/deployer/DeployerTestServlet.class" />
- </classes>
- </war>
+ <webinf dir="${test.resources.dir}/deployer/WEB-INF">
+ <exclude name="web.xml" />
+ </webinf>
+ <classes dir="${build.dir}/test-classes">
+ <include name="org/jbpm/test/deployer/DeployerTestServlet.class" />
+ </classes>
+ </war>
</target>
Added: jbpm4/trunk/modules/enterprise/src/test/java/org/jbpm/test/classloading/CustomClass.java
===================================================================
--- jbpm4/trunk/modules/enterprise/src/test/java/org/jbpm/test/classloading/CustomClass.java (rev 0)
+++ jbpm4/trunk/modules/enterprise/src/test/java/org/jbpm/test/classloading/CustomClass.java 2009-03-18 08:27:46 UTC (rev 4271)
@@ -0,0 +1,36 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.test.classloading;
+
+/**
+ * @author Heiko.Braun <heiko.braun(a)jboss.com>
+ */
+public class CustomClass
+{
+ private String val = "World";
+
+ public String hello()
+ {
+ System.out.println("*** CustomClass: Hello " + val);
+ return val;
+ }
+}
Modified: jbpm4/trunk/modules/enterprise/src/test/java/org/jbpm/test/deployer/DeployerTestCase.java
===================================================================
--- jbpm4/trunk/modules/enterprise/src/test/java/org/jbpm/test/deployer/DeployerTestCase.java 2009-03-18 08:26:36 UTC (rev 4270)
+++ jbpm4/trunk/modules/enterprise/src/test/java/org/jbpm/test/deployer/DeployerTestCase.java 2009-03-18 08:27:46 UTC (rev 4271)
@@ -49,6 +49,12 @@
public void testDeploymentExists()
{
+ if(testHelper.isTargetJBoss500() == false)
+ {
+ System.out.println("FIXME JBPM-2111: DeployerTestCase on AS 4.2.x");
+ return;
+ }
+
String response =
HTTP.get("http://"+System.getProperty("jboss.bind.address")+":8080/jbpm-deployer-test", null);
Added: jbpm4/trunk/modules/enterprise/src/test/resources/classloading/META-INF/process.jpdl.xml
===================================================================
--- jbpm4/trunk/modules/enterprise/src/test/resources/classloading/META-INF/process.jpdl.xml (rev 0)
+++ jbpm4/trunk/modules/enterprise/src/test/resources/classloading/META-INF/process.jpdl.xml 2009-03-18 08:27:46 UTC (rev 4271)
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<process name="Classloading" xmlns="http://jbpm.org/4/jpdl">
+ <start name="start1" g="105,71,48,48">
+ <transition name="to invoke class" to="invoke class" g="-84,-18"/>
+ </start>
+
+ <java name="invoke class"
+ g="88,167,92,52"
+ class="org.jbpm.test.classloading.CustomClass"
+ method="hello"
+ var="answer">
+
+ <transition name="to state1" to="state1" g="-46,-18"/>
+ </java>
+
+ <state g="227,203,92,52" name="state1">
+ <transition g="-46,-18" name="first transition" to="end1"/>
+ </state>
+
+ <end name="end1" g="104,271,48,48"/>
+</process>
\ No newline at end of file
Modified: jbpm4/trunk/modules/integration/console/src/main/java/org/jbpm/integration/console/ProcessManagementImpl.java
===================================================================
--- jbpm4/trunk/modules/integration/console/src/main/java/org/jbpm/integration/console/ProcessManagementImpl.java 2009-03-18 08:26:36 UTC (rev 4270)
+++ jbpm4/trunk/modules/integration/console/src/main/java/org/jbpm/integration/console/ProcessManagementImpl.java 2009-03-18 08:27:46 UTC (rev 4271)
@@ -147,7 +147,7 @@
{
if(ProcessInstanceRef.STATE.ENDED==nextState)
{
- // TODO: It's actually a delte call. Once we got the 'cancel' notion this should be changed
+ // TODO: It's actually a delete call. Once we got the 'cancel' notion this should be changed
ExecutionService execService = this.processEngine.getExecutionService();
Execution exec = execService.findExecution(executionId);
if(null==exec)
Modified: jbpm4/trunk/modules/integration/jboss4/src/main/java/org/jbpm/integration/jboss4/JBPMDeployer.java
===================================================================
--- jbpm4/trunk/modules/integration/jboss4/src/main/java/org/jbpm/integration/jboss4/JBPMDeployer.java 2009-03-18 08:26:36 UTC (rev 4270)
+++ jbpm4/trunk/modules/integration/jboss4/src/main/java/org/jbpm/integration/jboss4/JBPMDeployer.java 2009-03-18 08:27:46 UTC (rev 4271)
@@ -62,9 +62,7 @@
public JBPMDeployer()
{
initializeMainDeployer();
- this.adaptor = new DeploymentAdaptor();
-
- System.out.println("Started JBPMDeployer");
+ this.adaptor = new DeploymentAdaptor();
}
/**
Added: jbpm4/trunk/modules/integration/jboss4/src/main/java/org/jbpm/integration/jboss4/mgmt/ServerConfig.java
===================================================================
--- jbpm4/trunk/modules/integration/jboss4/src/main/java/org/jbpm/integration/jboss4/mgmt/ServerConfig.java (rev 0)
+++ jbpm4/trunk/modules/integration/jboss4/src/main/java/org/jbpm/integration/jboss4/mgmt/ServerConfig.java 2009-03-18 08:27:46 UTC (rev 4271)
@@ -0,0 +1,53 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.integration.jboss4.mgmt;
+
+import org.jbpm.integration.spi.mgmt.AbstractServerConfig;
+import org.jbpm.integration.util.MBeanServerLocator;
+
+import javax.management.MBeanServer;
+
+/**
+ * @author Heiko.Braun <heiko.braun(a)jboss.com>
+ */
+public class ServerConfig extends AbstractServerConfig
+{
+
+ public String getImplementationTitle()
+ {
+ return getClass().getPackage().getImplementationTitle();
+ }
+
+ public String getImplementationVersion()
+ {
+ return getClass().getPackage().getImplementationVersion();
+ }
+
+ /**
+ * In AS 4 it's not provided by MC, hence we do the lookup
+ * @return
+ */
+ public MBeanServer getMbeanServer()
+ {
+ return new MBeanServerLocator().getMbeanServer();
+ }
+}
\ No newline at end of file
Modified: jbpm4/trunk/modules/integration/jboss4/src/main/resources/jbpm.beans/META-INF/jboss-beans.xml
===================================================================
--- jbpm4/trunk/modules/integration/jboss4/src/main/resources/jbpm.beans/META-INF/jboss-beans.xml 2009-03-18 08:26:36 UTC (rev 4270)
+++ jbpm4/trunk/modules/integration/jboss4/src/main/resources/jbpm.beans/META-INF/jboss-beans.xml 2009-03-18 08:27:46 UTC (rev 4271)
@@ -12,7 +12,19 @@
</property>
</bean>
+ <!--
+ JBPMService
+ -->
<bean name="org.jbpm:service=ProcessEngine"
- class="org.jbpm.integration.spi.JBPMServiceImpl"/>
+ class="org.jbpm.integration.spi.JBPMService">
+ <property name="serverConfig"><inject bean="org.jbpm:service=ServerConfig"/></property>
+ </bean>
+ <!--
+ ServerConfig
+ -->
+ <bean name="org.jbpm:service=ServerConfig"
+ class="org.jbpm.integration.jboss5.mgmt.ServerConfig">
+ </bean>
+
</deployment>
\ No newline at end of file
Added: jbpm4/trunk/modules/integration/jboss5/src/main/java/org/jbpm/integration/jboss5/mgmt/ServerConfig.java
===================================================================
--- jbpm4/trunk/modules/integration/jboss5/src/main/java/org/jbpm/integration/jboss5/mgmt/ServerConfig.java (rev 0)
+++ jbpm4/trunk/modules/integration/jboss5/src/main/java/org/jbpm/integration/jboss5/mgmt/ServerConfig.java 2009-03-18 08:27:46 UTC (rev 4271)
@@ -0,0 +1,41 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.integration.jboss5.mgmt;
+
+import org.jbpm.integration.spi.mgmt.AbstractServerConfig;
+
+/**
+ * @author Heiko.Braun <heiko.braun(a)jboss.com>
+ */
+public class ServerConfig extends AbstractServerConfig
+{
+
+ public String getImplementationTitle()
+ {
+ return getClass().getPackage().getImplementationTitle();
+ }
+
+ public String getImplementationVersion()
+ {
+ return getClass().getPackage().getImplementationVersion();
+ }
+}
Modified: jbpm4/trunk/modules/integration/jboss5/src/main/resources/META-INF/jbpm-service-jboss-beans.xml
===================================================================
--- jbpm4/trunk/modules/integration/jboss5/src/main/resources/META-INF/jbpm-service-jboss-beans.xml 2009-03-18 08:26:36 UTC (rev 4270)
+++ jbpm4/trunk/modules/integration/jboss5/src/main/resources/META-INF/jbpm-service-jboss-beans.xml 2009-03-18 08:27:46 UTC (rev 4271)
@@ -1,11 +1,22 @@
<?xml version="1.0" encoding="UTF-8"?>
<deployment xmlns="urn:jboss:bean-deployer:2.0">
-
+
<!--
JBPM Service
-->
<bean name="org.jbpm:service=ProcessEngine"
- class="org.jbpm.integration.spi.JBPMServiceImpl"/>
-
+ class="org.jbpm.integration.spi.JBPMService">
+ <property name="serverConfig"><inject bean="org.jbpm:service=ServerConfig"/></property>
+ </bean>
+
+ <!--
+ ServerConfig
+ -->
+ <bean name="org.jbpm:service=ServerConfig"
+ class="org.jbpm.integration.jboss4.mgmt.ServerConfig">
+ <property name="mbeanServer"><inject bean="JMXKernel" property="mbeanServer"/></property>
+ </bean>
+
+
</deployment>
\ No newline at end of file
Deleted: jbpm4/trunk/modules/integration/jboss5/src/main/resources/META-INF/jbpm.deployer.cfg.xml
===================================================================
--- jbpm4/trunk/modules/integration/jboss5/src/main/resources/META-INF/jbpm.deployer.cfg.xml 2009-03-18 08:26:36 UTC (rev 4270)
+++ jbpm4/trunk/modules/integration/jboss5/src/main/resources/META-INF/jbpm.deployer.cfg.xml 2009-03-18 08:27:46 UTC (rev 4271)
@@ -1,57 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!--
- jBPM4 deployer configuration.
- The deployer deals with the transaction management on it's own.
- (UserTransaction)
--->
-
-<jbpm-configuration xmlns="http://jbpm.org/xsd/cfg">
-
- <process-engine-context>
-
- <deployer-manager>
- <assign-file-type>
- <file extension=".jpdl.xml" type="jpdl" />
- </assign-file-type>
- <parse-jpdl />
- <check-process /> <!--Covered by VersionTimestampPolicy -->
- <check-problems />
- <save policy="org.jbpm.pvm.internal.wire.binding.VersionTimestampPolicy"/>
- </deployer-manager>
-
- <process-service />
- <execution-service />
- <management-service />
-
- <command-service>
- <retry-interceptor />
- <environment-interceptor />
- </command-service>
-
- <hibernate-configuration resource="hibernate.cfg.xml"/>
-
- <hibernate-session-factory />
-
- <id-generator />
- <types resource="jbpm.pvm.types.xml" />
-
- <business-calendar>
- <monday hours="9:00-12:00 and 12:30-17:00"/>
- <tuesday hours="9:00-12:00 and 12:30-17:00"/>
- <wednesday hours="9:00-12:00 and 12:30-17:00"/>
- <thursday hours="9:00-12:00 and 12:30-17:00"/>
- <friday hours="9:00-12:00 and 12:30-17:00"/>
- <holiday period="01/07/2008 - 31/08/2008"/>
- </business-calendar>
-
- </process-engine-context>
-
- <transaction-context>
- <hibernate-session current="true"/>
- <pvm-db-session />
- <job-db-session />
- <ejb-timer-session />
- </transaction-context>
-
-</jbpm-configuration>
Deleted: jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/JBPMService.java
===================================================================
--- jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/JBPMService.java 2009-03-18 08:26:36 UTC (rev 4270)
+++ jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/JBPMService.java 2009-03-18 08:27:46 UTC (rev 4271)
@@ -1,37 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags. See the copyright.txt file in the
- * distribution for a full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jbpm.integration.spi;
-
-import org.jbpm.ProcessEngine;
-
-/**
- * A JBPM service implementation that will be installed into the AS kernel.
- *
- * @author Heiko.Braun <heiko.braun(a)jboss.com>
- */
-public interface JBPMService
-{
- void start();
- void stop();
-
- ProcessEngine getProcessEngine();
-}
Added: jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/mgmt/AbstractServerConfig.java
===================================================================
--- jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/mgmt/AbstractServerConfig.java (rev 0)
+++ jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/mgmt/AbstractServerConfig.java 2009-03-18 08:27:46 UTC (rev 4271)
@@ -0,0 +1,114 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.integration.spi.mgmt;
+
+import org.jboss.logging.Logger;
+import org.jbpm.integration.util.ObjectNameFactory;
+
+import javax.management.JMException;
+import javax.management.MBeanServer;
+import javax.management.ObjectName;
+import java.io.File;
+
+/**
+ * Basic implementation of a ServerConfig.
+ * Concrete implementations reside with the container integration impl.
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @author darran.lofthouse(a)jboss.com
+ * @author Heiko.Braun(a)jboss.com
+ *
+ * @since 08-May-2006
+ */
+public abstract class AbstractServerConfig implements AbstractServerConfigMBean
+{
+ private static final Logger log = Logger.getLogger(AbstractServerConfig.class);
+
+ // The MBeanServer
+ private MBeanServer mbeanServer;
+
+ public MBeanServer getMbeanServer()
+ {
+ return mbeanServer;
+ }
+
+ public void setMbeanServer(MBeanServer mbeanServer)
+ {
+ this.mbeanServer = mbeanServer;
+ }
+
+ public abstract String getImplementationTitle();
+
+ public abstract String getImplementationVersion();
+
+ public File getServerTempDir()
+ {
+ try
+ {
+ ObjectName oname = ObjectNameFactory.create("jboss.system:type=ServerConfig");
+ File dir = (File)getMbeanServer().getAttribute(oname, "ServerTempDir");
+ return dir;
+ }
+ catch (JMException e)
+ {
+ return null;
+ }
+ }
+
+ public File getHomeDir()
+ {
+ try
+ {
+ ObjectName oname = ObjectNameFactory.create("jboss.system:type=ServerConfig");
+ File dir = (File)getMbeanServer().getAttribute(oname, "HomeDir");
+ return dir;
+ }
+ catch (JMException e)
+ {
+ return null;
+ }
+ }
+
+ public File getServerDataDir()
+ {
+ try
+ {
+ ObjectName oname = ObjectNameFactory.create("jboss.system:type=ServerConfig");
+ File dir = (File)getMbeanServer().getAttribute(oname, "ServerDataDir");
+ return dir;
+ }
+ catch (JMException e)
+ {
+ return null;
+ }
+ }
+
+ public void create() throws Exception
+ {
+ getMbeanServer().registerMBean(this, AbstractServerConfigMBean.OBJECT_NAME);
+ }
+
+ public void destroy() throws Exception
+ {
+ getMbeanServer().unregisterMBean(AbstractServerConfigMBean.OBJECT_NAME);
+ }
+}
\ No newline at end of file
Added: jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/mgmt/AbstractServerConfigMBean.java
===================================================================
--- jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/mgmt/AbstractServerConfigMBean.java (rev 0)
+++ jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/mgmt/AbstractServerConfigMBean.java 2009-03-18 08:27:46 UTC (rev 4271)
@@ -0,0 +1,32 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.integration.spi.mgmt;
+
+import javax.management.ObjectName;
+
+import org.jbpm.integration.util.ObjectNameFactory;
+
+public interface AbstractServerConfigMBean extends ServerConfig
+{
+ /** The object name in the MBean server */
+ ObjectName OBJECT_NAME = ObjectNameFactory.create("org.jbpm:service=ServerConfig");
+}
Added: jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/mgmt/ServerConfig.java
===================================================================
--- jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/mgmt/ServerConfig.java (rev 0)
+++ jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/mgmt/ServerConfig.java 2009-03-18 08:27:46 UTC (rev 4271)
@@ -0,0 +1,46 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.integration.spi.mgmt;
+
+import java.io.File;
+
+/**
+ * Interface to container independent config
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 08-May-2006
+ */
+public interface ServerConfig
+{
+ /** The default bean name */
+ String BEAN_NAME = "org.jbpm:service=ServerConfig";
+
+ String getImplementationTitle();
+
+ String getImplementationVersion();
+
+ File getHomeDir();
+
+ File getServerTempDir();
+
+ File getServerDataDir();
+}
\ No newline at end of file
Added: jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/mgmt/ServerConfigFactory.java
===================================================================
--- jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/mgmt/ServerConfigFactory.java (rev 0)
+++ jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/mgmt/ServerConfigFactory.java 2009-03-18 08:27:46 UTC (rev 4271)
@@ -0,0 +1,42 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.integration.spi.mgmt;
+
+import org.jbpm.integration.util.KernelAwareSPIFactory;
+
+/**
+ * Factory to container independent config
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @author Heiko.Braun(a)jboss.com
+ *
+ * @since 08-May-2006
+ */
+public class ServerConfigFactory
+{
+ public static ServerConfig getServerConfig()
+ {
+ return new KernelAwareSPIFactory().getKernelProvidedSPI(
+ ServerConfig.BEAN_NAME, ServerConfig.class
+ );
+ }
+}
\ No newline at end of file
Added: jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/util/ObjectNameFactory.java
===================================================================
--- jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/util/ObjectNameFactory.java (rev 0)
+++ jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/util/ObjectNameFactory.java 2009-03-18 08:27:46 UTC (rev 4271)
@@ -0,0 +1,72 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jbpm.integration.util;
+
+import java.util.Hashtable;
+
+import javax.management.MalformedObjectNameException;
+import javax.management.ObjectName;
+
+/**
+ * A simple factory for creating safe object names.
+ *
+ * @author Thomas.Diesler(a)jboss.org
+ * @since 08-May-2006
+ */
+public class ObjectNameFactory
+{
+ public static ObjectName create(String name)
+ {
+ try
+ {
+ return new ObjectName(name);
+ }
+ catch (MalformedObjectNameException e)
+ {
+ throw new Error("Invalid ObjectName: " + name + "; " + e);
+ }
+ }
+
+ public static ObjectName create(String domain, String key, String value)
+ {
+ try
+ {
+ return new ObjectName(domain, key, value);
+ }
+ catch (MalformedObjectNameException e)
+ {
+ throw new Error("Invalid ObjectName: " + domain + "," + key + "," + value + "; " + e);
+ }
+ }
+
+ public static ObjectName create(String domain, Hashtable table)
+ {
+ try
+ {
+ return new ObjectName(domain, table);
+ }
+ catch (MalformedObjectNameException e)
+ {
+ throw new Error("Invalid ObjectName: " + domain + "," + table + "; " + e);
+ }
+ }
+}
Modified: jbpm4/trunk/modules/integration/spi/src/main/resources/jboss-service.xml
===================================================================
--- jbpm4/trunk/modules/integration/spi/src/main/resources/jboss-service.xml 2009-03-18 08:26:36 UTC (rev 4270)
+++ jbpm4/trunk/modules/integration/spi/src/main/resources/jboss-service.xml 2009-03-18 08:27:46 UTC (rev 4271)
@@ -4,7 +4,7 @@
a Configuration capable of dynamically updating the
config settings
-->
- <mbean code="org.jboss.security.auth.login.DynamicLoginConfig" name="org.jboss.jbpm:service=LoginConfig">
+ <mbean code="org.jboss.security.auth.login.DynamicLoginConfig" name="org.jbpm:service=LoginConfig">
<attribute name="PolicyConfig" serialDataType="jbxb">
<jaas:policy xsi:schemaLocation="urn:jboss:security-config:4.1 resource:security-config_4_1.xsd" xmlns:jaas="urn:jboss:security-config:4.1"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
17 years, 1 month
JBoss JBPM SVN: r4270 - jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi.
by do-not-reply@jboss.org
Author: heiko.braun(a)jboss.com
Date: 2009-03-18 04:26:36 -0400 (Wed, 18 Mar 2009)
New Revision: 4270
Removed:
jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/JBPMServiceImpl.java
Log:
Remove legacy class from build
Deleted: jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/JBPMServiceImpl.java
===================================================================
--- jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/JBPMServiceImpl.java 2009-03-18 08:06:35 UTC (rev 4269)
+++ jbpm4/trunk/modules/integration/spi/src/main/java/org/jbpm/integration/spi/JBPMServiceImpl.java 2009-03-18 08:26:36 UTC (rev 4270)
@@ -1,68 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags. See the copyright.txt file in the
- * distribution for a full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jbpm.integration.spi;
-
-import org.jbpm.Configuration;
-import org.jbpm.ProcessEngine;
-import org.jbpm.internal.log.Log;
-
-import javax.naming.InitialContext;
-
-/**
- * @author Heiko.Braun <heiko.braun(a)jboss.com>
- */
-public class JBPMServiceImpl implements JBPMService
-{
- private static final Log log = Log.getLog(JBPMServiceImpl.class.getName());
-
- private final static String DEFAULT_JNDI_NAME = "java:/ProcessEngine";
-
- private ProcessEngine processEngine;
-
- public void start()
- {
- this.processEngine = new Configuration().buildProcessEngine();
-
- try
- {
- InitialContext ctx = new InitialContext();
- ctx.bind(DEFAULT_JNDI_NAME, new ProcessEngineReference("default", this.processEngine));
- log.info("ProcessEngine bound to: " + DEFAULT_JNDI_NAME);
- }
- catch (Exception e)
- {
- throw new RuntimeException("Failed to create JBPMService", e);
- }
-
- }
-
- public void stop()
- {
- this.processEngine = null;
- log.info("JBPMService stopped");
- }
-
- public ProcessEngine getProcessEngine()
- {
- return this.processEngine;
- }
-}
17 years, 1 month