From c0604184b2aa8cff924ca783ec6b36f1f5988775 Mon Sep 17 00:00:00 2001 From: Zhaoxing Date: Tue, 8 Aug 2017 14:02:53 +0800 Subject: init code Change-Id: Icd0948118397b256da70dfbcbbec5520dc5eafd4 Signed-off-by: Zhaoxing --- .../standalone/src/main/assembly/initDB.sh | 53 ++ .../standalone/src/main/assembly/run.bat | 32 + .../standalone/src/main/assembly/run.sh | 32 + .../standalone/src/main/assembly/stop.bat | 28 + .../standalone/src/main/assembly/stop.sh | 30 + .../assembly/wso2bps-ext/bin/find_kill_process.bat | 24 + .../src/main/assembly/wso2bps-ext/bin/shutdown.bat | 34 + .../src/main/assembly/wso2bps-ext/bin/shutdown.sh | 61 ++ .../src/main/assembly/wso2bps-ext/bin/startup.bat | 42 ++ .../src/main/assembly/wso2bps-ext/bin/startup.sh | 36 ++ .../main/assembly/wso2bps-ext/conf/wso2bpel.yml | 73 +++ .../assembly/wso2bps/bin/find_kill_process.bat | 23 + .../src/main/assembly/wso2bps/bin/shutdown.bat | 34 + .../src/main/assembly/wso2bps/bin/shutdown.sh | 44 ++ .../wso2bps/dbscripts/bps/bpel/create/mysql.sql | 170 +++++ .../bps/bpel/create/wso-bpel-mysql-createdb.sql | 31 + .../main/assembly/wso2bps/repository/conf/bps.xml | 174 ++++++ .../wso2bps/repository/conf/carbon/bps.xml | 174 ++++++ .../wso2bps/repository/conf/carbon/carbon.xml | 683 +++++++++++++++++++++ .../conf/datasources/activiti-datasources.xml | 32 + .../conf/datasources/bps-datasources.xml | 32 + .../conf/datasources/master-datasources.xml | 68 ++ .../main/assembly/wso2bps/wso2bps-ext.properties | 1 + 23 files changed, 1911 insertions(+) create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/initDB.sh create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/run.bat create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/run.sh create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/stop.bat create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/stop.sh create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/find_kill_process.bat create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/shutdown.bat create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/shutdown.sh create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/startup.bat create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/startup.sh create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/conf/wso2bpel.yml create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/bin/find_kill_process.bat create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/bin/shutdown.bat create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/bin/shutdown.sh create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/dbscripts/bps/bpel/create/mysql.sql create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/dbscripts/bps/bpel/create/wso-bpel-mysql-createdb.sql create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/bps.xml create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/carbon/bps.xml create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/carbon/carbon.xml create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/datasources/activiti-datasources.xml create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/datasources/bps-datasources.xml create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/datasources/master-datasources.xml create mode 100644 wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/wso2bps-ext.properties (limited to 'wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src') diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/initDB.sh b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/initDB.sh new file mode 100644 index 0000000..eacbaf2 --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/initDB.sh @@ -0,0 +1,53 @@ +#!/bin/bash +# +# Copyright 2016 ZTE Corporation. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +DIRNAME=`dirname $0` +HOME=`cd $DIRNAME/; pwd` +user=$1 +password=$2 +port=$3 +host=$4 + + +echo "start to change db ip and port" +sed -i "s|localhost|$host|" wso2bps/repository/conf/datasources/bps-datasources.xml +sed -i "s|3306|$port|" wso2bps/repository/conf/datasources/bps-datasources.xml +cat wso2bps/repository/conf/datasources/bps-datasources.xml +echo "end of change db ip and port" +echo "" + +echo "start create wso2 bpel db" +mysql -u$user -p$password -P$port -h$host <$HOME/wso2bps/dbscripts/bps/bpel/create/wso-bpel-mysql-createdb.sql +sql_result=$? +if [ $sql_result != 0 ] ; then + echo "failed to create wso2 bpel database" + exit 1 +fi + + +echo "start create wso2 bpel table" +mysql -u$user -p$password -P$port -h$host -Dwso_bpel <$HOME/wso2bps/dbscripts/bps/bpel/create/mysql.sql +sql_result=$? +if [ $sql_result != 0 ] ; then + echo "failed to create wso2 bpel table" + exit 1 +fi + +echo "init wso2 bpel database success!" +exit 0 + + diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/run.bat b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/run.bat new file mode 100644 index 0000000..752c415 --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/run.bat @@ -0,0 +1,32 @@ +@REM +@REM Copyright 2016-2017 ZTE Corporation. +@REM +@REM Licensed under the Apache License, Version 2.0 (the "License"); +@REM you may not use this file except in compliance with the License. +@REM You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, software +@REM distributed under the License is distributed on an "AS IS" BASIS, +@REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +@REM See the License for the specific language governing permissions and +@REM limitations under the License. +@REM + +@echo off +title wso2 + +set RUNHOME=%~dp0 +echo ##RUNHOME %RUNHOME% + + +echo ### Starting wso2bps +start /D %RUNHOME%wso2bps bin\wso2server.bat +cd /D %RUNHOME%wso2bps-ext\bin + +echo ### Starting wso2bps-ext +start startup.bat + +cd /D %RUNHOME% + diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/run.sh b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/run.sh new file mode 100644 index 0000000..a57d017 --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/run.sh @@ -0,0 +1,32 @@ +# +# Copyright 2016-2017 ZTE Corporation. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + + +DIRNAME=`dirname $0` +RUNHOME=`cd $DIRNAME/; pwd` +echo @RUNHOME@ $RUNHOME + +echo "### Starting wso2bps"; +cd wso2bps +$RUNHOME/wso2bps/bin/wso2server.sh & +cd $RUNHOME + + +echo "\n\n### Starting wso2bps-ext" +cd wso2bps-ext +$RUNHOME/wso2bps-ext/bin/startup.sh & +echo "### Starting wso2 end..."; + diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/stop.bat b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/stop.bat new file mode 100644 index 0000000..60ebad4 --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/stop.bat @@ -0,0 +1,28 @@ +@REM +@REM Copyright 2016 ZTE Corporation. +@REM +@REM Licensed under the Apache License, Version 2.0 (the "License"); +@REM you may not use this file except in compliance with the License. +@REM You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, software +@REM distributed under the License is distributed on an "AS IS" BASIS, +@REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +@REM See the License for the specific language governing permissions and +@REM limitations under the License. +@REM + +@echo off +title wso2 + +set RUNHOME=%~dp0 +echo ##RUNHOME %RUNHOME% + + +echo ### Starting wso2bps +start /D %RUNHOME%wso2bps bin\shutdown.bat + +echo ### Starting wso2bps-ext +start /D %RUNHOME%wso2bps-ext bin\shutdown.bat diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/stop.sh b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/stop.sh new file mode 100644 index 0000000..29e23f5 --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/stop.sh @@ -0,0 +1,30 @@ +# +# Copyright 2016 ZTE Corporation. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +DIRNAME=`dirname $0` +RUNHOME=`cd $DIRNAME/; pwd` +echo @RUNHOME@ $RUNHOME + +echo "### Shutdown wso2bps"; +cd wso2bps +$RUNHOME/wso2bps/bin/shutdown.sh & +cd $RUNHOME + + +echo "\n\n### Shutdown wso2bps-ext" +cd wso2bps-ext +$RUNHOME/wso2bps-ext/bin/shutdown.sh & +echo "### Shutdown wso2 end..."; diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/find_kill_process.bat b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/find_kill_process.bat new file mode 100644 index 0000000..a4a2f06 --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/find_kill_process.bat @@ -0,0 +1,24 @@ +@REM +@REM Copyright 2016 ZTE Corporation. +@REM +@REM Licensed under the Apache License, Version 2.0 (the "License"); +@REM you may not use this file except in compliance with the License. +@REM You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, software +@REM distributed under the License is distributed on an "AS IS" BASIS, +@REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +@REM See the License for the specific language governing permissions and +@REM limitations under the License. +@REM + +echo %1 | findstr %2 >NUL +echo ERRORLEVEL=%ERRORLEVEL% +IF ERRORLEVEL 1 goto findend +for /f "tokens=1" %%a in (%1) do ( + echo kill %1 + taskkill /F /pid %%a +) +:findend \ No newline at end of file diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/shutdown.bat b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/shutdown.bat new file mode 100644 index 0000000..76b2f58 --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/shutdown.bat @@ -0,0 +1,34 @@ +@REM +@REM Copyright 2016 ZTE Corporation. +@REM +@REM Licensed under the Apache License, Version 2.0 (the "License"); +@REM you may not use this file except in compliance with the License. +@REM You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, software +@REM distributed under the License is distributed on an "AS IS" BASIS, +@REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +@REM See the License for the specific language governing permissions and +@REM limitations under the License. +@REM + +@echo off +title stopping wso2bpel-service + +set HOME=%~dp0 +set Main_Class="org.openo.carbon.bpel.Wso2BpelApplication" + +echo ================== wso2bpel-service info ============================================= +echo HOME=$HOME +echo Main_Class=%Main_Class% +echo =============================================================================== + +echo ### Stopping wso2bpel-service +cd /d %HOME% + +for /f "delims=" %%i in ('"%JAVA_HOME%\bin\jcmd"') do ( + call find_kill_process "%%i" %Main_Class% +) +exit \ No newline at end of file diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/shutdown.sh b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/shutdown.sh new file mode 100644 index 0000000..6d5d93f --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/shutdown.sh @@ -0,0 +1,61 @@ +# +# Copyright 2016 ZTE Corporation. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +#!/bin/bash +# +# +# Copyright 2016 [ZTE] and others. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +DIRNAME=`dirname $0` +HOME=`cd $DIRNAME/; pwd` +Main_Class="org.openo.carbon.bpel.Wso2BpelApplication" + +echo ================== wso2bpel-service info ============================================= +echo HOME=$HOME +echo Main_Class=$Main_Class +echo =============================================================================== +cd $HOME; pwd + +echo @WORK_DIR@ $HOME + +function save_service_pid(){ + service_pid=`ps -ef | grep $Main_Class | grep -v grep | awk '{print $2}'` + echo @service_pid@ $service_pid +} + +function kill_service_process(){ + ps -p $service_pid + if [ $? == 0 ]; then + kill -9 $service_pid + fi +} + +save_service_pid; +echo @C_CMD@ kill -9 $service_pid +kill_service_process; diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/startup.bat b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/startup.bat new file mode 100644 index 0000000..95c0b59 --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/startup.bat @@ -0,0 +1,42 @@ +@REM +@REM Copyright 2016 ZTE Corporation. +@REM +@REM Licensed under the Apache License, Version 2.0 (the "License"); +@REM you may not use this file except in compliance with the License. +@REM You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, software +@REM distributed under the License is distributed on an "AS IS" BASIS, +@REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +@REM See the License for the specific language governing permissions and +@REM limitations under the License. +@REM + +@echo off +title wso2bpel-service + +set RUNHOME=%~dp0 +echo ### RUNHOME: %RUNHOME% +echo ### Starting wso2bpel-service +set WSO2_EXT_HOME=%RUNHOME%\.. + +set JAVA="%JAVA_HOME%\bin\java.exe" +set port=8312 +set jvm_opts=-Xms50m -Xmx128m +rem set jvm_opts=%jvm_opts% -Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,address=%port%,server=y,suspend=n +set jvm_opts=%jvm_opts% -DWSO2_EXT_HOME=%WSO2_EXT_HOME% +set class_path=%RUNHOME%;%WSO2_EXT_HOME%\lib\*;%WSO2_EXT_HOME%\wso2bpel-service.jar +echo ### jvm_opts: %jvm_opts% +echo ### class_path: %class_path% + +%JAVA% -classpath %class_path% %jvm_opts% org.openo.carbon.bpel.Wso2BpelApplication server %WSO2_EXT_HOME%/conf/wso2bpel.yml + +IF ERRORLEVEL 1 goto showerror +exit +:showerror +echo WARNING: Error occurred during startup or Server abnormally stopped by way of killing the process,Please check! +echo After checking, press any key to close +pause +exit \ No newline at end of file diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/startup.sh b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/startup.sh new file mode 100644 index 0000000..c8ea31a --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/bin/startup.sh @@ -0,0 +1,36 @@ +# +# Copyright 2016 ZTE Corporation. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +DIRNAME=`dirname $0` +RUNHOME=`cd $DIRNAME/; pwd` +WSO_EXT_HOME=${RUNHOME}/.. +echo @RUNHOME@ $RUNHOME + +echo @JAVA_HOME@ $JAVA_HOME +JAVA="$JAVA_HOME/bin/java" +echo @JAVA@ $JAVA + +JAVA_OPTS="-Xms50m -Xmx128m -Djava.awt.headless=true" +port=8312 +# JAVA_OPTS="$JAVA_OPTS -Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,address=$port,server=y,suspend=n" +JAVA_OPTS="$JAVA_OPTS -DWSO2_EXT_HOME=${WSO_EXT_HOME}" +echo @JAVA_OPTS@ $JAVA_OPTS + +class_path="$RUNHOME/:$RUNHOME/../lib/*:$RUNHOME/../wso2bpel-service.jar" +echo @class_path@ $class_path + +"$JAVA" $JAVA_OPTS -classpath "$class_path" org.openo.carbon.bpel.Wso2BpelApplication server "$RUNHOME/../conf/wso2bpel.yml" + diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/conf/wso2bpel.yml b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/conf/wso2bpel.yml new file mode 100644 index 0000000..b56bb5a --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps-ext/conf/wso2bpel.yml @@ -0,0 +1,73 @@ +# +# Copyright 2016-2017 ZTE Corporation. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +template: Hello, %s! + +# defaultName: ${DW_DEFAULT_NAME:-Stranger} +# the micro service ip +serviceIp: +msbServerAddr: http://127.0.0.1:80 + +wso2Host: localhost +wso2HostPort: 9443 +wso2AuthUserName: admin +wso2AuthPassword: admin +wso2Path: ../wso2bps +wso2UploadFilePath: ../wso2bps/tmp/bpeluploads +wso2SslJksFile: ../wso2bps/repository/resources/security/wso2carbon.jks +wso2SslJksPassword: wso2carbon + + +# use the simple server factory if you only want to run on a single port +#server: +# type: simple +# connector: +# type: http +# port: 8080 +server: + type: simple + rootPath: '/openoapi/wso2bpel/v1/*' + applicationContextPath: / + adminContextPath: /admin + connector: + type: http + port: 8101 + +# Logging settings. +logging: + + # The default level of all loggers. Can be OFF, ERROR, WARN, INFO, DEBUG, TRACE, or ALL. + level: ALL + + # Logger-specific levels. + loggers: + + # Sets the level for 'com.example.app' to DEBUG. + org.openo.carbon.bpel.Wso2BpelApplication: INFO + + appenders: + - type: console + threshold: INFO + timeZone: UTC + logFormat: "%d{yyyy-MM-dd HH:mm:ss SSS} %-5p [%c][%t] - %m%n" + - type: file + threshold: INFO + logFormat: "%d{yyyy-MM-dd HH:mm:ss SSS} %-5p [%c][%t] - %m%n" + currentLogFilename: ./logs/wso2bpel-ext.log + archivedLogFilenamePattern: ./logs/zip/wso2bpel-ext-%d{yyyy-MM-dd}.log.gz + archivedFileCount: 7 + timeZone: UTC + diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/bin/find_kill_process.bat b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/bin/find_kill_process.bat new file mode 100644 index 0000000..d89cf27 --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/bin/find_kill_process.bat @@ -0,0 +1,23 @@ +@REM +@REM Copyright (C) 2015 ZTE, Inc. and others. All rights reserved. (ZTE) +@REM +@REM Licensed under the Apache License, Version 2.0 (the "License"); +@REM you may not use this file except in compliance with the License. +@REM You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, software +@REM distributed under the License is distributed on an "AS IS" BASIS, +@REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +@REM See the License for the specific language governing permissions and +@REM limitations under the License. +@REM +echo %1 | findstr %2 >NUL +echo ERRORLEVEL=%ERRORLEVEL% +IF ERRORLEVEL 1 goto findend +for /f "tokens=1" %%a in (%1) do ( + echo kill %1 + taskkill /F /pid %%a +) +:findend \ No newline at end of file diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/bin/shutdown.bat b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/bin/shutdown.bat new file mode 100644 index 0000000..d932cb7 --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/bin/shutdown.bat @@ -0,0 +1,34 @@ +@REM +@REM Copyright (C) 2015 ZTE, Inc. and others. All rights reserved. (ZTE) +@REM +@REM Licensed under the Apache License, Version 2.0 (the "License"); +@REM you may not use this file except in compliance with the License. +@REM You may obtain a copy of the License at +@REM +@REM http://www.apache.org/licenses/LICENSE-2.0 +@REM +@REM Unless required by applicable law or agreed to in writing, software +@REM distributed under the License is distributed on an "AS IS" BASIS, +@REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +@REM See the License for the specific language governing permissions and +@REM limitations under the License. +@REM +@echo off +title stopping WSO2 + +set HOME=%~dp0 +set Main_Class="org.wso2.carbon.bootstrap.Bootstrap" + +echo ================== WSO2 info ============================================= +echo HOME=$HOME +echo Main_Class=%Main_Class% +echo =============================================================================== + +echo ### Stopping WSO2 +cd /d %HOME% + +rem set JAVA_HOME=D:\WorkSoftware\jdk1.7.0_60 +for /f "delims=" %%i in ('"%JAVA_HOME%\bin\jcmd"') do ( + call find_kill_process "%%i" %Main_Class% +) +exit diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/bin/shutdown.sh b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/bin/shutdown.sh new file mode 100644 index 0000000..06a0950 --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/bin/shutdown.sh @@ -0,0 +1,44 @@ +#!/bin/bash +# +# Copyright (C) 2015 ZTE, Inc. and others. All rights reserved. (ZTE) +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +DIRNAME=`dirname $0` +HOME=`cd $DIRNAME/; pwd` +Main_Class="org.wso2.carbon.bootstrap.Bootstrap" + +echo ================== umc-service info ============================================= +echo HOME=$HOME +echo Main_Class=$Main_Class +echo =============================================================================== +cd $HOME; pwd + +echo @WORK_DIR@ $HOME + +function save_service_pid(){ + service_pid=`ps -ef | grep $Main_Class | grep -v grep | awk '{print $2}'` + echo @service_pid@ $service_pid +} + +function kill_service_process(){ + ps -p $service_pid + if [ $? == 0 ]; then + kill -9 $service_pid + fi +} + +save_service_pid; +echo @C_CMD@ kill -9 $service_pid +kill_service_process; \ No newline at end of file diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/dbscripts/bps/bpel/create/mysql.sql b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/dbscripts/bps/bpel/create/mysql.sql new file mode 100644 index 0000000..c12bbfb --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/dbscripts/bps/bpel/create/mysql.sql @@ -0,0 +1,170 @@ +-- +-- Licensed to the Apache Software Foundation (ASF) under one +-- or more contributor license agreements. See the NOTICE file +-- distributed with this work for additional information +-- regarding copyright ownership. The ASF licenses this file +-- to you under the Apache License, Version 2.0 (the +-- "License"); you may not use this file except in compliance +-- with the License. You may obtain a copy of the License at +-- +-- http://www.apache.org/licenses/LICENSE-2.0 +-- +-- Unless required by applicable law or agreed to in writing, +-- software distributed under the License is distributed on an +-- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +-- KIND, either express or implied. See the License for the +-- specific language governing permissions and limitations +-- under the License. +-- + +-- +-- BPEL Related SQL Scripts +-- + + +create table ODE_SCHEMA_VERSION (VERSION integer); +insert into ODE_SCHEMA_VERSION values (6); +-- Apache ODE - SimpleScheduler Database Schema +-- +-- MySQL scripts by Maciej Szefler. +-- +-- +DROP TABLE IF EXISTS ODE_JOB; + +CREATE TABLE ODE_JOB ( + jobid CHAR(64) NOT NULL DEFAULT '', + ts BIGINT NOT NULL DEFAULT 0, + nodeid char(64) NULL, + scheduled int NOT NULL DEFAULT 0, + transacted int NOT NULL DEFAULT 0, + + instanceId BIGINT, + mexId varchar(255), + processId varchar(255), + type varchar(255), + channel varchar(255), + correlatorId varchar(255), + correlationKeySet varchar(255), + retryCount int, + inMem int, + detailsExt blob(4096), + + PRIMARY KEY(jobid), + INDEX IDX_ODE_JOB_TS(ts), + INDEX IDX_ODE_JOB_NODEID(nodeid) +) +ENGINE=innodb; + +COMMIT; + +CREATE TABLE TASK_ATTACHMENT (ATTACHMENT_ID BIGINT NOT NULL, MESSAGE_EXCHANGE_ID VARCHAR(255), PRIMARY KEY (ATTACHMENT_ID)) ENGINE=innodb; +CREATE TABLE ODE_ACTIVITY_RECOVERY (ID BIGINT NOT NULL, ACTIONS VARCHAR(255), ACTIVITY_ID BIGINT, CHANNEL VARCHAR(255), DATE_TIME DATETIME, DETAILS TEXT, INSTANCE_ID BIGINT, REASON VARCHAR(255), RETRIES INTEGER, PRIMARY KEY (ID)) ENGINE=innodb; +CREATE TABLE ODE_CORRELATION_SET (CORRELATION_SET_ID BIGINT NOT NULL, CORRELATION_KEY VARCHAR(255), NAME VARCHAR(255), SCOPE_ID BIGINT, PRIMARY KEY (CORRELATION_SET_ID)) ENGINE=innodb; +CREATE TABLE ODE_CORRELATOR (CORRELATOR_ID BIGINT NOT NULL, CORRELATOR_KEY VARCHAR(255), PROC_ID BIGINT, PRIMARY KEY (CORRELATOR_ID)) ENGINE=innodb; +CREATE TABLE ODE_CORSET_PROP (ID BIGINT NOT NULL, CORRSET_ID BIGINT, PROP_KEY VARCHAR(255), PROP_VALUE VARCHAR(255), PRIMARY KEY (ID)) ENGINE=innodb; +CREATE TABLE ODE_EVENT (EVENT_ID BIGINT NOT NULL, DETAIL VARCHAR(255), DATA BLOB, SCOPE_ID BIGINT, TSTAMP DATETIME, TYPE VARCHAR(255), INSTANCE_ID BIGINT, PROCESS_ID BIGINT, PRIMARY KEY (EVENT_ID)) ENGINE=innodb; +CREATE TABLE ODE_FAULT (FAULT_ID BIGINT NOT NULL, ACTIVITY_ID INTEGER, DATA TEXT, MESSAGE VARCHAR(4000), LINE_NUMBER INTEGER, NAME VARCHAR(255), PRIMARY KEY (FAULT_ID)) ENGINE=innodb; +CREATE TABLE ODE_MESSAGE (MESSAGE_ID BIGINT NOT NULL, DATA TEXT, HEADER TEXT, TYPE VARCHAR(255), MESSAGE_EXCHANGE_ID VARCHAR(255), PRIMARY KEY (MESSAGE_ID)) ENGINE=innodb; +CREATE TABLE ODE_MESSAGE_EXCHANGE (MESSAGE_EXCHANGE_ID VARCHAR(255) NOT NULL, CALLEE VARCHAR(255), CHANNEL VARCHAR(255), CORRELATION_ID VARCHAR(255), CORRELATION_KEYS VARCHAR(255), CORRELATION_STATUS VARCHAR(255), CREATE_TIME DATETIME, DIRECTION INTEGER, EPR TEXT, FAULT VARCHAR(255), FAULT_EXPLANATION VARCHAR(255), OPERATION VARCHAR(255), PARTNER_LINK_MODEL_ID INTEGER, PATTERN VARCHAR(255), PIPED_ID VARCHAR(255), PORT_TYPE VARCHAR(255), PROPAGATE_TRANS BIT, STATUS VARCHAR(255), SUBSCRIBER_COUNT INTEGER, CORR_ID BIGINT, PARTNER_LINK_ID BIGINT, PROCESS_ID BIGINT, PROCESS_INSTANCE_ID BIGINT, REQUEST_MESSAGE_ID BIGINT, RESPONSE_MESSAGE_ID BIGINT, PRIMARY KEY (MESSAGE_EXCHANGE_ID)) ENGINE=innodb; +CREATE TABLE ODE_MESSAGE_ROUTE (MESSAGE_ROUTE_ID BIGINT NOT NULL, CORRELATION_KEY VARCHAR(255), GROUP_ID VARCHAR(255), ROUTE_INDEX INTEGER, PROCESS_INSTANCE_ID INTEGER, ROUTE_POLICY VARCHAR(16), CORR_ID BIGINT, PRIMARY KEY (MESSAGE_ROUTE_ID)) ENGINE=innodb; +CREATE TABLE ODE_MEX_PROP (ID BIGINT NOT NULL, MEX_ID VARCHAR(255), PROP_KEY VARCHAR(255), PROP_VALUE VARCHAR(2000), PRIMARY KEY (ID)) ENGINE=innodb; +CREATE TABLE ODE_PARTNER_LINK (PARTNER_LINK_ID BIGINT NOT NULL, MY_EPR TEXT, MY_ROLE_NAME VARCHAR(255), MY_ROLE_SERVICE_NAME VARCHAR(255), MY_SESSION_ID VARCHAR(255), PARTNER_EPR TEXT, PARTNER_LINK_MODEL_ID INTEGER, PARTNER_LINK_NAME VARCHAR(255), PARTNER_ROLE_NAME VARCHAR(255), PARTNER_SESSION_ID VARCHAR(255), SCOPE_ID BIGINT, PRIMARY KEY (PARTNER_LINK_ID)) ENGINE=innodb; +CREATE TABLE ODE_PROCESS (ID BIGINT NOT NULL, GUID VARCHAR(255), PROCESS_ID VARCHAR(255), PROCESS_TYPE VARCHAR(255), VERSION BIGINT, PRIMARY KEY (ID)) ENGINE=innodb; +CREATE TABLE ODE_PROCESS_INSTANCE (ID BIGINT NOT NULL, DATE_CREATED DATETIME, EXECUTION_STATE BLOB, FAULT_ID BIGINT, LAST_ACTIVE_TIME DATETIME, LAST_RECOVERY_DATE DATETIME, PREVIOUS_STATE SMALLINT, SEQUENCE BIGINT, INSTANCE_STATE SMALLINT, INSTANTIATING_CORRELATOR_ID BIGINT, PROCESS_ID BIGINT, ROOT_SCOPE_ID BIGINT, PRIMARY KEY (ID)) ENGINE=innodb; +CREATE TABLE ODE_SCOPE (SCOPE_ID BIGINT NOT NULL, MODEL_ID INTEGER, SCOPE_NAME VARCHAR(255), SCOPE_STATE VARCHAR(255), PROCESS_INSTANCE_ID BIGINT, PARENT_SCOPE_ID BIGINT, PRIMARY KEY (SCOPE_ID)) ENGINE=innodb; +CREATE TABLE ODE_XML_DATA (XML_DATA_ID BIGINT NOT NULL, DATA TEXT, IS_SIMPLE_TYPE BIT, NAME VARCHAR(255), SCOPE_ID BIGINT, PRIMARY KEY (XML_DATA_ID)) ENGINE=innodb; +CREATE TABLE ODE_XML_DATA_PROP (ID BIGINT NOT NULL, XML_DATA_ID BIGINT, PROP_KEY VARCHAR(255), PROP_VALUE VARCHAR(255), PRIMARY KEY (ID)) ENGINE=innodb; +CREATE TABLE OPENJPA_SEQUENCE_TABLE (ID TINYINT NOT NULL, SEQUENCE_VALUE BIGINT, PRIMARY KEY (ID)) ENGINE=innodb; +CREATE TABLE STORE_DU (NAME VARCHAR(255) NOT NULL, DEPLOYDT DATETIME, DEPLOYER VARCHAR(255), DIR VARCHAR(255), PRIMARY KEY (NAME)) ENGINE=innodb; +CREATE TABLE STORE_PROCESS (PID VARCHAR(255) NOT NULL, STATE VARCHAR(255), TYPE VARCHAR(255), VERSION BIGINT, DU VARCHAR(255), PRIMARY KEY (PID)) ENGINE=innodb; +CREATE TABLE STORE_PROCESS_PROP (id BIGINT NOT NULL, PROP_KEY VARCHAR(255), PROP_VAL VARCHAR(255), PRIMARY KEY (id)) ENGINE=innodb; +CREATE TABLE STORE_PROC_TO_PROP (PROCESSCONFDAOIMPL_PID VARCHAR(255), ELEMENT_ID BIGINT) ENGINE=innodb; +CREATE TABLE STORE_VERSIONS (id BIGINT NOT NULL, VERSION BIGINT, PRIMARY KEY (id)) ENGINE=innodb; +CREATE INDEX I_D_TASK_ATTACMENT ON TASK_ATTACHMENT (MESSAGE_EXCHANGE_ID); +CREATE INDEX I_D_CTVRY_INSTANCE ON ODE_ACTIVITY_RECOVERY (INSTANCE_ID); +CREATE INDEX I_D_CR_ST_SCOPE ON ODE_CORRELATION_SET (SCOPE_ID); +CREATE INDEX I_D_CRLTR_PROCESS ON ODE_CORRELATOR (PROC_ID); +CREATE INDEX I_D_CRPRP_CORRSET ON ODE_CORSET_PROP (CORRSET_ID); +CREATE INDEX I_OD_VENT_INSTANCE ON ODE_EVENT (INSTANCE_ID); +CREATE INDEX I_OD_VENT_PROCESS ON ODE_EVENT (PROCESS_ID); +CREATE INDEX I_OD_MSSG_MESSAGEEXCHANGE ON ODE_MESSAGE (MESSAGE_EXCHANGE_ID); +CREATE INDEX I_D_MSHNG_CORRELATOR ON ODE_MESSAGE_EXCHANGE (CORR_ID); +CREATE INDEX I_D_MSHNG_PARTNERLINK ON ODE_MESSAGE_EXCHANGE (PARTNER_LINK_ID); +CREATE INDEX I_D_MSHNG_PROCESS ON ODE_MESSAGE_EXCHANGE (PROCESS_ID); +CREATE INDEX I_D_MSHNG_PROCESSINST ON ODE_MESSAGE_EXCHANGE (PROCESS_INSTANCE_ID); +CREATE INDEX I_D_MSHNG_REQUEST ON ODE_MESSAGE_EXCHANGE (REQUEST_MESSAGE_ID); +CREATE INDEX I_D_MSHNG_RESPONSE ON ODE_MESSAGE_EXCHANGE (RESPONSE_MESSAGE_ID); +CREATE INDEX I_D_MS_RT_CORRELATOR ON ODE_MESSAGE_ROUTE (CORR_ID); +CREATE INDEX I_D_MS_RT_PROCESSINST ON ODE_MESSAGE_ROUTE (PROCESS_INSTANCE_ID); +CREATE INDEX I_D_MXPRP_MEX ON ODE_MEX_PROP (MEX_ID); +CREATE INDEX I_D_PRLNK_SCOPE ON ODE_PARTNER_LINK (SCOPE_ID); +CREATE INDEX I_D_PRTNC_FAULT ON ODE_PROCESS_INSTANCE (FAULT_ID); +CREATE INDEX I_D_PRTNC_INSTANTIATINGCORRELATOR ON ODE_PROCESS_INSTANCE (INSTANTIATING_CORRELATOR_ID); +CREATE INDEX I_D_PRTNC_PROCESS ON ODE_PROCESS_INSTANCE (PROCESS_ID); +CREATE INDEX I_D_PRTNC_ROOTSCOPE ON ODE_PROCESS_INSTANCE (ROOT_SCOPE_ID); +CREATE INDEX I_OD_SCOP_PARENTSCOPE ON ODE_SCOPE (PARENT_SCOPE_ID); +CREATE INDEX I_OD_SCOP_PROCESSINSTANCE ON ODE_SCOPE (PROCESS_INSTANCE_ID); +CREATE INDEX I_D_XM_DT_SCOPE ON ODE_XML_DATA (SCOPE_ID); +CREATE INDEX I_D_XMPRP_XMLDATA ON ODE_XML_DATA_PROP (XML_DATA_ID); +CREATE INDEX I_STR_CSS_DU ON STORE_PROCESS (DU); +CREATE INDEX I_STR_PRP_ELEMENT ON STORE_PROC_TO_PROP (ELEMENT_ID); +CREATE INDEX I_STR_PRP_PROCESSCONFDAOIMPL_PID ON STORE_PROC_TO_PROP (PROCESSCONFDAOIMPL_PID); + + + +-- +-- Human Task Related SQL Scripts +-- + + +CREATE TABLE HT_DEADLINE (id BIGINT NOT NULL, DEADLINE_DATE DATETIME NOT NULL, DEADLINE_NAME VARCHAR(255) NOT NULL, STATUS_TOBE_ACHIEVED VARCHAR(255) NOT NULL, TASK_ID BIGINT, PRIMARY KEY (id)) ENGINE = innodb; +CREATE TABLE HT_DEPLOYMENT_UNIT (id BIGINT NOT NULL, CHECKSUM VARCHAR(255) NOT NULL, DEPLOYED_ON DATETIME, DEPLOY_DIR VARCHAR(255) NOT NULL, NAME VARCHAR(255) NOT NULL, PACKAGE_NAME VARCHAR(255) NOT NULL, STATUS VARCHAR(255) NOT NULL, TENANT_ID BIGINT NOT NULL, VERSION BIGINT NOT NULL, PRIMARY KEY (id)) ENGINE = innodb; +CREATE TABLE HT_EVENT (id BIGINT NOT NULL, EVENT_DETAILS VARCHAR(255), NEW_STATE VARCHAR(255), OLD_STATE VARCHAR(255), EVENT_TIMESTAMP DATETIME NOT NULL, EVENT_TYPE VARCHAR(255) NOT NULL, EVENT_USER VARCHAR(255) NOT NULL, TASK_ID BIGINT, PRIMARY KEY (id)) ENGINE = innodb; +CREATE TABLE HT_GENERIC_HUMAN_ROLE (GHR_ID BIGINT NOT NULL, GHR_TYPE VARCHAR(255), TASK_ID BIGINT, PRIMARY KEY (GHR_ID)) ENGINE = innodb; +CREATE TABLE HT_HUMANROLE_ORGENTITY (HUMANROLE_ID BIGINT, ORGENTITY_ID BIGINT) ENGINE = innodb; +CREATE TABLE HT_JOB (id BIGINT NOT NULL, JOB_DETAILS VARCHAR(4000), JOB_NAME VARCHAR(255), NODEID VARCHAR(255), SCHEDULED VARCHAR(1) NOT NULL, TASKID BIGINT NOT NULL, JOB_TIME BIGINT NOT NULL, TRANSACTED VARCHAR(1) NOT NULL, JOB_TYPE VARCHAR(255) NOT NULL, PRIMARY KEY (id)) ENGINE = innodb; +CREATE TABLE HT_MESSAGE (MESSAGE_ID BIGINT NOT NULL, MESSAGE_DATA LONGTEXT, MESSAGE_HEADER LONGTEXT, MESSAGE_TYPE VARCHAR(255), MESSAGE_NAME VARCHAR(512), TASK_ID BIGINT, PRIMARY KEY (MESSAGE_ID)) ENGINE = innodb; +CREATE TABLE HT_ORG_ENTITY (ORG_ENTITY_ID BIGINT NOT NULL, ORG_ENTITY_NAME VARCHAR(255), ORG_ENTITY_TYPE VARCHAR(255), PRIMARY KEY (ORG_ENTITY_ID)) ENGINE = innodb; +CREATE TABLE HT_PRESENTATION_ELEMENT (id BIGINT NOT NULL, PE_CONTENT VARCHAR(2000), XML_LANG VARCHAR(255), PE_TYPE VARCHAR(31), CONTENT_TYPE VARCHAR(255), TASK_ID BIGINT, PRIMARY KEY (id)) ENGINE = innodb; +CREATE TABLE HT_PRESENTATION_PARAM (id BIGINT NOT NULL, PARAM_NAME VARCHAR(255), PARAM_TYPE VARCHAR(255), PARAM_VALUE VARCHAR(2000), TASK_ID BIGINT, PRIMARY KEY (id)) ENGINE = innodb; +CREATE TABLE HT_TASK (id BIGINT NOT NULL, ACTIVATION_TIME DATETIME, COMPLETE_BY_TIME DATETIME, CREATED_ON DATETIME, ESCALATED VARCHAR(1), EXPIRATION_TIME DATETIME, TASK_NAME VARCHAR(255) NOT NULL, PACKAGE_NAME VARCHAR(255) NOT NULL, PRIORITY INTEGER NOT NULL, SKIPABLE VARCHAR(1), START_BY_TIME DATETIME, STATUS VARCHAR(255) NOT NULL, STATUS_BEFORE_SUSPENSION VARCHAR(255), TASK_DEF_NAME VARCHAR(255) NOT NULL, TASK_VERSION BIGINT NOT NULL, TENANT_ID INTEGER NOT NULL, TASK_TYPE VARCHAR(255) NOT NULL, UPDATED_ON DATETIME, FAILURE_MESSAGE BIGINT, INPUT_MESSAGE BIGINT, OUTPUT_MESSAGE BIGINT, PARENTTASK_ID BIGINT, PRIMARY KEY (id)) ENGINE = innodb; +CREATE TABLE HT_TASK_ATTACHMENT (id BIGINT NOT NULL, ACCESS_TYPE VARCHAR(255), ATTACHED_AT DATETIME, CONTENT_TYPE VARCHAR(255), ATTACHMENT_NAME VARCHAR(255), ATTACHMENT_VALUE VARCHAR(255), TASK_ID BIGINT, ATTACHED_BY BIGINT, PRIMARY KEY (id)) ENGINE = innodb; +CREATE TABLE HT_TASK_COMMENT (id BIGINT NOT NULL, COMMENT_TEXT VARCHAR(4000), COMMENTED_BY VARCHAR(100), COMMENTED_ON DATETIME, MODIFIED_BY VARCHAR(100), MODIFIED_ON DATETIME, TASK_ID BIGINT, PRIMARY KEY (id)) ENGINE = innodb; +CREATE TABLE HT_VERSIONS (id BIGINT NOT NULL, TASK_VERSION BIGINT NOT NULL, PRIMARY KEY (id)) ENGINE = innodb; +CREATE INDEX I_HT_DDLN_TASK ON HT_DEADLINE (TASK_ID); +CREATE INDEX I_HT_VENT_TASK ON HT_EVENT (TASK_ID); +CREATE INDEX I_HT_G_RL_TASK ON HT_GENERIC_HUMAN_ROLE (TASK_ID); +CREATE INDEX I_HT_HTTY_ELEMENT ON HT_HUMANROLE_ORGENTITY (ORGENTITY_ID); +CREATE INDEX I_HT_HTTY_HUMANROLE_ID ON HT_HUMANROLE_ORGENTITY (HUMANROLE_ID); +CREATE INDEX I_HT_MSSG_TASK ON HT_MESSAGE (TASK_ID); +CREATE INDEX I_HT_PMNT_DTYPE ON HT_PRESENTATION_ELEMENT (PE_TYPE); +CREATE INDEX I_HT_PMNT_TASK ON HT_PRESENTATION_ELEMENT (TASK_ID); +CREATE INDEX I_HT_PPRM_TASK ON HT_PRESENTATION_PARAM (TASK_ID); +CREATE INDEX I_HT_TASK_FAILUREMESSAGE ON HT_TASK (FAILURE_MESSAGE); +CREATE INDEX I_HT_TASK_INPUTMESSAGE ON HT_TASK (INPUT_MESSAGE); +CREATE INDEX I_HT_TASK_OUTPUTMESSAGE ON HT_TASK (OUTPUT_MESSAGE); +CREATE INDEX I_HT_TASK_PARENTTASK ON HT_TASK (PARENTTASK_ID); +CREATE INDEX I_HT_TMNT_ATTACHEDBY ON HT_TASK_ATTACHMENT (ATTACHED_BY); +CREATE INDEX I_HT_TMNT_TASK ON HT_TASK_ATTACHMENT (TASK_ID); +CREATE INDEX I_HT_TMNT_TASK1 ON HT_TASK_COMMENT (TASK_ID); + +-- +-- Attachment Management Related SQL Scripts +-- +CREATE TABLE ATTACHMENT ( + id BIGINT NOT NULL AUTO_INCREMENT, + CREATED_TIME TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP, + ATTACHMENT_NAME VARCHAR(255) NOT NULL, + CREATED_BY VARCHAR(255) NOT NULL, + CONTENT_TYPE VARCHAR(255) NOT NULL, + ATTACHMENT_URL VARCHAR(2048) NOT NULL, + ATTACHMENT_CONTENT BLOB, + PRIMARY KEY (id)); + +-- CREATE INDEX I_ATTACHMENT_URL ON ATTACHMENT (ATTACHMENT_URL); + + +-- +-- B4P Related SQL Scripts +-- +CREATE TABLE HT_COORDINATION_DATA (MESSAGE_ID VARCHAR(255) NOT NULL, PROCESS_INSTANCE_ID VARCHAR(255), PROTOCOL_HANDlER_URL VARCHAR(255) NOT NULL, TASK_ID VARCHAR(255), PRIMARY KEY (MESSAGE_ID)) ENGINE = innodb; diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/dbscripts/bps/bpel/create/wso-bpel-mysql-createdb.sql b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/dbscripts/bps/bpel/create/wso-bpel-mysql-createdb.sql new file mode 100644 index 0000000..16dca47 --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/dbscripts/bps/bpel/create/wso-bpel-mysql-createdb.sql @@ -0,0 +1,31 @@ +-- +-- Copyright 2016 ZTE Corporation. +-- +-- Licensed under the Apache License, Version 2.0 (the "License"); +-- you may not use this file except in compliance with the License. +-- You may obtain a copy of the License at +-- +-- http://www.apache.org/licenses/LICENSE-2.0 +-- +-- Unless required by applicable law or agreed to in writing, software +-- distributed under the License is distributed on an "AS IS" BASIS, +-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +-- See the License for the specific language governing permissions and +-- limitations under the License. +-- + +/******************drop old database and user***************************/ +use mysql; +drop database IF EXISTS wso_bpel; +delete from user where User='wso_bpel'; +FLUSH PRIVILEGES; + +/******************create new database and user***************************/ +create database wso_bpel CHARACTER SET utf8; + +GRANT ALL PRIVILEGES ON wso_bpel.* TO 'wso_bpel'@'%' IDENTIFIED BY 'wso_bpel' WITH GRANT OPTION; +GRANT ALL PRIVILEGES ON mysql.* TO 'wso_bpel'@'%' IDENTIFIED BY 'wso_bpel' WITH GRANT OPTION; + +GRANT ALL PRIVILEGES ON wso_bpel.* TO 'wso_bpel'@'localhost' IDENTIFIED BY 'wso_bpel' WITH GRANT OPTION; +GRANT ALL PRIVILEGES ON mysql.* TO 'wso_bpel'@'localhost' IDENTIFIED BY 'wso_bpel' WITH GRANT OPTION; +FLUSH PRIVILEGES; \ No newline at end of file diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/bps.xml b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/bps.xml new file mode 100644 index 0000000..1e09356 --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/bps.xml @@ -0,0 +1,174 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 50 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +   + + + + + + + + + + + + + + + + + diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/carbon/bps.xml b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/carbon/bps.xml new file mode 100644 index 0000000..1e09356 --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/carbon/bps.xml @@ -0,0 +1,174 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 50 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +   + + + + + + + + + + + + + + + + + diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/carbon/carbon.xml b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/carbon/carbon.xml new file mode 100644 index 0000000..6973b7c --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/carbon/carbon.xml @@ -0,0 +1,683 @@ + + + + + + + + + WSO2 Business Process Server + + + BPS + + + 3.5.0 + + + + + + + + + local:/${carbon.context}/services/ + + + + + + + BusinessProcessServer + + + + + + + org.wso2.carbon + + + / + + + + + + + + + 15 + + + + + + + + + 0 + + + + + 9999 + + 11111 + + + + + + 10389 + + 8000 + + + + + + 10500 + + + + + + + org.wso2.carbon.tomcat.jndi.CarbonJavaURLContextFactory + + + + + + + + + java + + + + + + + + + + false + + + false + + + 600 + + + + false + + + + + + + + 30 + + + + + + + + + 15 + + + + + + ${carbon.home}/repository/deployment/server/ + + + 15 + + + ${carbon.home}/repository/conf/axis2/axis2.xml + + + 30000 + + + ${carbon.home}/repository/deployment/client/ + + ${carbon.home}/repository/conf/axis2/axis2_client.xml + + false + + + + + + + + + + admin + Default Administrator Role + + + user + Default User Role + + + + + + + + + + + + ${carbon.home}/repository/resources/security/wso2carbon.jks + + JKS + + wso2carbon + + wso2carbon + + wso2carbon + + + + + + ${carbon.home}/repository/resources/security/client-truststore.jks + + JKS + + wso2carbon + + + + + + + + + + + + + + + + + + + UserManager + + + false + + + + + + + + + + ${carbon.home}/tmp/work + + + + + + true + + + 10 + + + 30 + + + + + + 100 + + + + keystore + certificate + * + + org.wso2.carbon.ui.transports.fileupload.AnyFileUploadExecutor + + + + + jarZip + + org.wso2.carbon.ui.transports.fileupload.JarZipUploadExecutor + + + + dbs + + org.wso2.carbon.ui.transports.fileupload.DBSFileUploadExecutor + + + + tools + + org.wso2.carbon.ui.transports.fileupload.ToolsFileUploadExecutor + + + + toolsAny + + org.wso2.carbon.ui.transports.fileupload.ToolsAnyFileUploadExecutor + + + + + + + info + org.wso2.carbon.core.transports.util.InfoProcessor + + + wsdl + org.wso2.carbon.core.transports.util.Wsdl11Processor + + + wsdl2 + org.wso2.carbon.core.transports.util.Wsdl20Processor + + + xsd + org.wso2.carbon.core.transports.util.XsdProcessor + + + + + + false + false + true + svn + http://svnrepo.example.com/repos/ + username + password + true + + + + + + + + + + + + + + + ${require.carbon.servlet} + + + + + true + + + + + + + default repository + http://dist.wso2.org/p2/carbon/releases/4.4.1-SNAPSHOT + + + + + + + + true + + + + + + true + + diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/datasources/activiti-datasources.xml b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/datasources/activiti-datasources.xml new file mode 100644 index 0000000..f95cb87 --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/datasources/activiti-datasources.xml @@ -0,0 +1,32 @@ + + + + org.wso2.carbon.ndatasource.rdbms.RDBMSDataSourceReader + + + + + + ACTIVITI_DB + The datasource used for activiti engine + + jdbc/ActivitiDB + + + + jdbc:h2:repository/database/activiti;DB_CLOSE_DELAY=-1;DB_CLOSE_ON_EXIT=FALSE;LOCK_TIMEOUT=60000 + wso2carbon + wso2carbon + org.h2.Driver + 50 + 60000 + true + SELECT 1 + 30000 + + + + + + + diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/datasources/bps-datasources.xml b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/datasources/bps-datasources.xml new file mode 100644 index 0000000..22f79f7 --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/datasources/bps-datasources.xml @@ -0,0 +1,32 @@ + + + + org.wso2.carbon.ndatasource.rdbms.RDBMSDataSourceReader + + + + + BPS_DS + + + bpsds + + + + jdbc:mysql://localhost:3306/wso_bpel + wso_bpel + wso_bpel + com.mysql.jdbc.Driver + true + SELECT 1 + 30000 + false + true + 100 + 20 + 10000 + + + + + diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/datasources/master-datasources.xml b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/datasources/master-datasources.xml new file mode 100644 index 0000000..897e335 --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/repository/conf/datasources/master-datasources.xml @@ -0,0 +1,68 @@ + + + + org.wso2.carbon.ndatasource.rdbms.RDBMSDataSourceReader + + + + + + WSO2_CARBON_DB + The datasource used for registry and user manager + + jdbc/WSO2CarbonDB + + + + jdbc:h2:repository/database/WSO2CARBON_DB;DB_CLOSE_ON_EXIT=FALSE;LOCK_TIMEOUT=60000 + wso2carbon + wso2carbon + org.h2.Driver + 50 + 60000 + true + SELECT 1 + 30000 + false + + + + + + + + + + diff --git a/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/wso2bps-ext.properties b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/wso2bps-ext.properties new file mode 100644 index 0000000..02d1b6d --- /dev/null +++ b/wso2/wso2bpel-ext/wso2bpel-core/distribution/standalone/src/main/assembly/wso2bps/wso2bps-ext.properties @@ -0,0 +1 @@ +MSB_URL=http://127.0.0.1:80 \ No newline at end of file -- cgit 1.2.3-korg