Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -772,6 +772,13 @@
<version>2.6.4</version>
<scope>compile</scope>
</dependency>

<dependency>
<groupId>com.sleepycat</groupId>
<artifactId>je</artifactId>
<version>18.3.12</version>
<scope>compile</scope>
</dependency>

<dependency>
<groupId>org.mybatis</groupId>
Expand Down
11 changes: 8 additions & 3 deletions sample/hsqldb/bin/lsc-sample
Original file line number Diff line number Diff line change
Expand Up @@ -60,10 +60,12 @@ fi
CONFIGPATH="${SAMPLE_HOME}/etc"

LSC_LIB_DIR="${SAMPLE_HOME}/../../lib"
LSC_SAMPLE_LIB_DIR="${SAMPLE_HOME}/../lib"
LSC_BIN_DIR="${SAMPLE_HOME}/../../bin"

# HSQLDB jar file
[ -z "$HSQLDB_LIB" -a -e "${LSC_LIB_DIR}"/hsqldb*.jar ] && HSQLDB_LIB=$( readlink -f "${LSC_LIB_DIR}"/hsqldb*.jar )
[ -z "$HSQLDB_LIB" -a -e "${LSC_SAMPLE_LIB_DIR}"/hsqldb*.jar ] && HSQLDB_LIB=$( readlink -f "${LSC_SAMPLE_LIB_DIR}"/hsqldb*.jar )
[ -z "$HSQLDB_LIB" ] && echo "hsqldb driver (hsqldb*.jar) is missing" && exit 1
# Temporary directory so that HSQLDB server could store files
HSQLDB_DIR="/tmp/lsc/hsqldb"
Expand Down Expand Up @@ -217,14 +219,17 @@ run_java_command()
# check if we have java executable
get_java

for jar in "${LSC_LIB_DIR}"/*.jar; do
LDAPCP="$LDAPCP:$jar"
for jar in "${LSC_LIB_DIR}"/*.jar "${LSC_SAMPLE_LIB_DIR}"/*.jar; do
[ -e "$jar" ] && LDAPCP="$LDAPCP:$jar"
done

"${JAVA_COMMAND}" \
-cp "$LDAPCP" \
--add-exports java.base/sun.security.tools.keytool=ALL-UNNAMED \
--add-exports java.base/sun.security.x509=ALL-UNNAMED $1
--add-exports java.base/sun.security.x509=ALL-UNNAMED \
--add-opens java.base/java.lang=ALL-UNNAMED \
--add-opens java.base/java.util=ALL-UNNAMED \
--add-opens java.base/sun.security.x509=ALL-UNNAMED $1
}

start_ldap() {
Expand Down
13 changes: 9 additions & 4 deletions sample/ldap2hsqldb/bin/lsc-sample
Original file line number Diff line number Diff line change
Expand Up @@ -60,10 +60,12 @@ fi
CONFIGPATH="${SAMPLE_HOME}/etc"

LSC_LIB_DIR="${SAMPLE_HOME}/../../lib"
LSC_SAMPLE_LIB_DIR="${SAMPLE_HOME}/../lib"
LSC_BIN_DIR="${SAMPLE_HOME}/../../bin"

# HSQLDB jar file
[ -z "$HSQLDB_LIB" -a -e "${LSC_LIB_DIR}"/hsqldb*.jar ] && HSQLDB_LIB=$( readlink -f "${LSC_LIB_DIR}"/hsqldb*.jar )
[ -z "$HSQLDB_LIB" -a -e "${LSC_SAMPLE_LIB_DIR}"/hsqldb*.jar ] && HSQLDB_LIB=$( readlink -f "${LSC_SAMPLE_LIB_DIR}"/hsqldb*.jar )
[ -z "$HSQLDB_LIB" ] && echo "hsqldb driver (hsqldb*.jar) is missing" && exit 1
# Temporary directory so that HSQLDB server could store files
HSQLDB_DIR=/tmp/lsc/hsqldb
Expand Down Expand Up @@ -163,14 +165,17 @@ run_java_command()
# check if we have java executable
get_java

for jar in "${LSC_LIB_DIR}"/*.jar; do
LDAPCP="$LDAPCP:$jar"
for jar in "${LSC_LIB_DIR}"/*.jar "${LSC_SAMPLE_LIB_DIR}"/*.jar; do
[ -e "$jar" ] && LDAPCP="$LDAPCP:$jar"
done

"${JAVA_COMMAND}" \
-cp "$LDAPCP" \
--add-exports java.base/sun.security.tools.keytool=ALL-UNNAMED \
--add-exports java.base/sun.security.x509=ALL-UNNAMED $1 $2 $3 $4 $5
--add-exports java.base/sun.security.x509=ALL-UNNAMED \
--add-opens java.base/java.lang=ALL-UNNAMED \
--add-opens java.base/java.util=ALL-UNNAMED \
--add-opens java.base/sun.security.x509=ALL-UNNAMED $1 $2 $3 $4 $5
}

start_ldap() {
Expand Down Expand Up @@ -247,7 +252,7 @@ case "$1" in
;;
"--stop-hsql-server")
ACTIONS="$ACTIONS stophsql"
! shift
shift
;;
"--run")
run LDAP2JDBCTask LDAP2JDBCTask
Expand Down
6 changes: 4 additions & 2 deletions src/main/assembly/dist.xml
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,8 @@
<outputDirectory>lib</outputDirectory>
<excludes>
<exclude>junit:junit</exclude>
<exclude>org.forgerock.opendj:opendj-server</exclude>
<exclude>org.forgerock.ce.opendj:opendj-server</exclude>
<exclude>com.sleepycat:je</exclude>
<exclude>postgresql:postgresql</exclude>
</excludes>
<fileMode>0644</fileMode>
Expand All @@ -209,7 +210,8 @@
<dependencySet>
<outputDirectory>sample/lib</outputDirectory>
<includes>
<include>org.forgerock.opendj:opendj-server</include>
<include>org.forgerock.ce.opendj:opendj-server</include>
<include>com.sleepycat:je</include>
<include>postgresql:postgresql</include>
<!-- see also the tests jar included in a fileSet above -->
</includes>
Expand Down
Loading