Skip to content

Commit

Permalink
chore(merge): release-10.2.0 into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
bonita-ci committed Sep 17, 2024
2 parents 605d4db + c9e1721 commit bf6f24b
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 46 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
# Bonita database properties
#########################################

# valid values are (h2, postgres, sqlserver, oracle, mysql)
# Valid values are: h2, postgres in Community edition, and also sqlserver, oracle, mysql in Subscription editions
db.vendor=h2
# when using h2, no server or port setting is needed since connexion is made using file protocol mode using relative directory:
db.server.name=SERVER_NAME
Expand All @@ -24,7 +24,7 @@ db.password=
###################################
# Business Data database properties
###################################
# valid values are (h2, postgres, sqlserver, oracle, mysql)
# Valid values are: h2, postgres in Community edition, and also sqlserver, oracle, mysql in Subscription editions
bdm.db.vendor=h2
bdm.db.server.name=SERVER_NAME
bdm.db.server.port=SERVER_PORT
Expand Down
40 changes: 0 additions & 40 deletions platform/platform-setup/src/main/standalone/internal.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,22 +15,6 @@ postgres.nonXaDriver=org.postgresql.Driver
postgres.xaDriver=org.postgresql.xa.PGXADataSource
postgres.xaDSFactory=org.postgresql.xa.PGXADataSourceFactory

# use this drivers for pre-8.0 MySQL version:
# mysql.nonXaDriver=com.mysql.jdbc.Driver
# mysql.xaDriver=com.mysql.jdbc.jdbc2.optional.MysqlXADataSource
# Otherwise use MySQL 8+ new driver:
mysql.nonXaDriver=com.mysql.cj.jdbc.Driver
mysql.xaDriver=com.mysql.cj.jdbc.MysqlXADataSource
mysql.xaDSFactory=com.mysql.cj.jdbc.MysqlDataSourceFactory

sqlserver.nonXaDriver=com.microsoft.sqlserver.jdbc.SQLServerDriver
sqlserver.xaDriver=com.microsoft.sqlserver.jdbc.SQLServerXADataSource
sqlserver.xaDSFactory=com.microsoft.sqlserver.jdbc.SQLServerDataSourceObjectFactory

oracle.nonXaDriver=oracle.jdbc.OracleDriver
oracle.xaDriver=oracle.jdbc.xa.client.OracleXADataSource
oracle.xaDSFactory=oracle.jdbc.pool.OracleDataSourceFactory

###########################
## Bonita database
###########################
Expand All @@ -43,18 +27,6 @@ h2.testQuery=SELECT 1
postgres.url=jdbc:postgresql://${db.server.name}:${db.server.port}/${db.database.name}
postgres.testQuery=SELECT 1

# mysql properties
mysql.url=jdbc:mysql://${db.server.name}:${db.server.port}/${db.database.name}?dontTrackOpenResources=true&useUnicode=true&characterEncoding=UTF-8&useSSL=false&allowPublicKeyRetrieval=true
mysql.testQuery=SELECT 1

# sqlserver properties
sqlserver.url=jdbc:sqlserver://${db.server.name}:${db.server.port};database=${db.database.name}
sqlserver.testQuery=SELECT 1

# oracle properties
oracle.url=jdbc:oracle:thin:@//${db.server.name}:${db.server.port}/${db.database.name}?oracle.net.disableOob=true
oracle.testQuery=SELECT 1 FROM DUAL


# spring properties
spring.datasource.username=${db.user}
Expand Down Expand Up @@ -83,18 +55,6 @@ h2.bdm.testQuery=SELECT 1
postgres.bdm.url=jdbc:postgresql://${bdm.db.server.name}:${bdm.db.server.port}/${bdm.db.database.name}
postgres.bdm.testQuery=SELECT 1

# mysql properties
mysql.bdm.url=jdbc:mysql://${bdm.db.server.name}:${bdm.db.server.port}/${bdm.db.database.name}?dontTrackOpenResources=true&useUnicode=true&characterEncoding=UTF-8&useSSL=false&allowPublicKeyRetrieval=true
mysql.bdm.testQuery=SELECT 1

# sqlserver properties
sqlserver.bdm.url=jdbc:sqlserver://${bdm.db.server.name}:${bdm.db.server.port};database=${bdm.db.database.name}
sqlserver.bdm.testQuery=SELECT 1

# oracle properties
oracle.bdm.url=jdbc:oracle:thin:@//${bdm.db.server.name}:${bdm.db.server.port}/${bdm.db.database.name}?oracle.net.disableOob=true
oracle.bdm.testQuery=SELECT 1 FROM DUAL

# The initial number of connections when the connection pool starts.
bdm.connection-pool.initialSize=4
# The maximum number of active connections that can be allocated from this pool at the same time.
Expand Down
4 changes: 2 additions & 2 deletions platform/platform-setup/src/main/standalone/setup.bat
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ set LIB_FOLDER=%BASEDIR%\lib
FOR /F "tokens=1,* delims== eol=#" %%A IN (database.properties) DO (set %%A=%%B)
set BONITA_DATABASE=%db.vendor%

IF NOT "%BONITA_DATABASE%" == "h2" IF NOT "%BONITA_DATABASE%" == "postgres" IF NOT "%BONITA_DATABASE%" == "sqlserver" IF NOT "%BONITA_DATABASE%" == "oracle" IF NOT "%BONITA_DATABASE%" == "mysql" (
echo Cannot determine database vendor valid values are [h2, postgres, sqlserver, oracle, mysql].
IF NOT "%BONITA_DATABASE%" == "h2" IF NOT "%BONITA_DATABASE%" == "postgres" (
echo Cannot determine database vendor valid values are [h2, postgres].
echo Please configure file %BASEDIR%database.properties properly.
exit /b 1
)
Expand Down
4 changes: 2 additions & 2 deletions platform/platform-setup/src/main/standalone/setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ done

BONITA_DATABASE=$(grep '^db.vendor=' database.properties | sed -e 's/db.vendor=//g')

if [ "$BONITA_DATABASE" != "h2" -a "$BONITA_DATABASE" != "postgres" -a "$BONITA_DATABASE" != "sqlserver" -a "$BONITA_DATABASE" != "oracle" -a "$BONITA_DATABASE" != "mysql" ]; then
echo "Cannot determine database vendor (valid values are h2, postgres, sqlserver, oracle, mysql)."
if [ "$BONITA_DATABASE" != "h2" ] && [ "$BONITA_DATABASE" != "postgres" ]; then
echo "Cannot determine database vendor (valid values are h2, postgres)."
echo "Please configure file ${BASEDIR}/database.properties properly."
exit 1
fi
Expand Down

0 comments on commit bf6f24b

Please sign in to comment.