Skip to content

Commit

Permalink
spring data v4.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
rashtao committed Jan 16, 2024
1 parent 8942d55 commit f63fd57
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 9 deletions.
22 changes: 14 additions & 8 deletions docker/start_db.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# STARTER_MODE: (single|cluster|activefailover), default single
# DOCKER_IMAGE: ArangoDB docker image, default docker.io/arangodb/arangodb:latest
# SSL: (true|false), default false
# DATABASE_EXTENDED_NAMES: (true|false), default false
# EXTENDED_NAMES: (true|false), default false
# ARANGO_LICENSE_KEY: only required for ArangoDB Enterprise

# EXAMPLE:
Expand All @@ -13,9 +13,11 @@
STARTER_MODE=${STARTER_MODE:=single}
DOCKER_IMAGE=${DOCKER_IMAGE:=docker.io/arangodb/arangodb:latest}
SSL=${SSL:=false}
DATABASE_EXTENDED_NAMES=${DATABASE_EXTENDED_NAMES:=false}
EXTENDED_NAMES=${EXTENDED_NAMES:=false}

STARTER_DOCKER_IMAGE=docker.io/arangodb/arangodb-starter:latest
GW=172.28.0.1
docker network create arangodb --subnet 172.28.0.0/16

# exit when any command fails
set -e
Expand All @@ -32,10 +34,10 @@ AUTHORIZATION_HEADER=$(cat "$LOCATION"/jwtHeader)
STARTER_ARGS=
SCHEME=http
ARANGOSH_SCHEME=http+tcp
COORDINATORS=("172.17.0.1:8529" "172.17.0.1:8539" "172.17.0.1:8549")
COORDINATORS=("$GW:8529" "$GW:8539" "$GW:8549")

if [ "$STARTER_MODE" == "single" ]; then
COORDINATORS=("172.17.0.1:8529")
COORDINATORS=("$GW:8529")
fi

if [ "$SSL" == "true" ]; then
Expand All @@ -44,8 +46,8 @@ if [ "$SSL" == "true" ]; then
ARANGOSH_SCHEME=http+ssl
fi

if [ "$DATABASE_EXTENDED_NAMES" == "true" ]; then
STARTER_ARGS="${STARTER_ARGS} --all.database.extended-names-databases=true"
if [ "$EXTENDED_NAMES" == "true" ]; then
STARTER_ARGS="${STARTER_ARGS} --all.database.extended-names=true"
fi

if [ "$USE_MOUNTED_DATA" == "true" ]; then
Expand All @@ -66,9 +68,10 @@ docker run -d \
$STARTER_ARGS \
--docker.container=adb \
--auth.jwt-secret=/jwtSecret \
--starter.address=172.17.0.1 \
--starter.address="${GW}" \
--docker.image="${DOCKER_IMAGE}" \
--starter.local --starter.mode=${STARTER_MODE} --all.log.level=debug --all.log.output=+ --log.verbose
--starter.local --starter.mode=${STARTER_MODE} --all.log.level=debug --all.log.output=+ --log.verbose \
--all.server.descriptors-minimum=1024 --all.javascript.allow-admin-execute=true


wait_server() {
Expand All @@ -87,12 +90,15 @@ done

set +e
for a in ${COORDINATORS[*]} ; do
echo ""
echo "Setting username and password..."
docker run --rm ${DOCKER_IMAGE} arangosh --server.endpoint="$ARANGOSH_SCHEME://$a" --server.authentication=false --javascript.execute-string='require("org/arangodb/users").update("root", "test")'
done
set -e

for a in ${COORDINATORS[*]} ; do
echo ""
echo "Requesting endpoint version..."
curl -u root:test --insecure --fail "$SCHEME://$a/_api/version"
done

Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@
<dependency>
<groupId>com.arangodb</groupId>
<artifactId>arangodb-spring-data</artifactId>
<version>4.0.0</version>
<version>4.0.1</version>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
Expand Down

0 comments on commit f63fd57

Please sign in to comment.