-
Notifications
You must be signed in to change notification settings - Fork 124
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#379 - adding ability to not fail batches and keep track of what failed.
fixed some things on search view
- Loading branch information
1 parent
f36a42d
commit eac5426
Showing
157 changed files
with
3,592 additions
and
1,691 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
.dockerignore | ||
|
||
.DS_Store | ||
|
||
**/node_modules | ||
.gradle | ||
**/.gradle | ||
!**/build.gradle | ||
!**/settings.gradle | ||
|
||
.idea | ||
|
||
# **/build/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,11 @@ | ||
language: java | ||
jdk: | ||
- oraclejdk8 | ||
env: | ||
- NODE_VERSION=6.1 | ||
sudo: true | ||
dist: trusty | ||
sudo: required | ||
services: | ||
- docker | ||
|
||
before_install: | ||
- echo 'America/Los_Angeles' | sudo tee /etc/timezone | ||
- sudo dpkg-reconfigure --frontend noninteractive tzdata | ||
install: | ||
- nvm install $NODE_VERSION | ||
- nvm use $NODE_VERSION | ||
- npm install -g typings | ||
- ./shared/dev-tasks/install-dependencies.sh | ||
- ./.travis/download.sh | ||
|
||
script: | ||
- nvm use $NODE_VERSION | ||
- if [[ $TRAVIS_SECURE_ENV_VARS == true ]]; then | ||
./gradlew check; | ||
else | ||
./gradlew jshint; | ||
fi | ||
- docker-compose build | ||
- docker-compose run marklogic |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
FROM openjdk:8 | ||
VOLUME /code | ||
ADD ./ /code | ||
WORKDIR /code | ||
ENTRYPOINT [ "sh", "-c", "./gradlew check" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
FROM centos:centos7 | ||
|
||
ENV LANG C.UTF-8 | ||
|
||
RUN yum -y install glibc.i686 \ | ||
gdb.x86_64 redhat-lsb.x86_64 vim \ | ||
bzip2 \ | ||
unzip \ | ||
xz-utils \ | ||
java-1.8.0-openjdk-devel 2>&1 > /dev/null | ||
|
||
# Install MarkLogic | ||
COPY ./MarkLogic.rpm /tmp/MarkLogic.rpm | ||
|
||
RUN yum -y install /tmp/MarkLogic.rpm 2>&1 > /dev/null | ||
|
||
# Expose MarkLogic Server ports - add additional ones for your REST, etc | ||
# endpoints | ||
EXPOSE 7997-8002 | ||
|
||
# init | ||
COPY .travis/startml.sh /tmp/startml.sh | ||
RUN chmod 755 /tmp/startml.sh | ||
COPY .travis/setup.sh /tmp/setup.sh | ||
RUN chmod 755 /tmp/setup.sh | ||
RUN /tmp/setup.sh | ||
|
||
VOLUME /marklogic-data-hub | ||
ADD ./ /marklogic-data-hub | ||
WORKDIR /marklogic-data-hub | ||
|
||
RUN ./gradlew tasks 2>&1 > /dev/null | ||
|
||
# Define default command (which avoids immediate shutdown) | ||
CMD /tmp/startml.sh && ./gradlew test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
#!/bin/bash | ||
|
||
# runs command from parameters and exits with the eoror code of the command | ||
# if it fails | ||
function successOrExit { | ||
"$@" | ||
local status=$? | ||
if [ $status -ne 0 ]; then | ||
echo "$1 exited with error: $status" | ||
exit $status | ||
fi | ||
} | ||
|
||
set | grep TRAVIS | ||
|
||
test $1 && arg1=$1 | ||
|
||
ver=${ML_VERSION} | ||
fname=MarkLogic-RHEL7-${ver}.x86_64.rpm | ||
fnamedeb="marklogic_" | ||
fnamedeb=$fnamedeb$ver | ||
suff="_amd64.deb" | ||
fnamedeb=$fnamedeb$suff | ||
|
||
echo "Logging in for Download" | ||
curl -s -c cookies.txt --data "email=${MLBUILD_USER}&password=${MLBUILD_PASSWORD}" https://developer.marklogic.com/login > /dev/null 2>&1 | ||
|
||
echo | ||
echo "Getting Download Link" | ||
dl_link=$(curl -s -b cookies.txt --data "download=/download/binaries/8.0/${fname}" https://developer.marklogic.com/get-download-url | perl -pe 's/.*"path":"([^"]+).*/\1/') | ||
url="https://developer.marklogic.com${dl_link}" | ||
|
||
echo "********* Downloading MarkLogic $ver" | ||
successOrExit curl -s -k -o ./MarkLogic.rpm $url |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
#!/bin/sh | ||
# | ||
# Initializes a virgin MarkLogic installation. | ||
|
||
HOST=localhost | ||
ADMINUSER=admin | ||
ADMINPASSWORD=admin | ||
|
||
/tmp/startml.sh | ||
|
||
until curl -fsS --head --digest --user "$ADMINUSER":"$ADMINPASSWORD" http://"$HOST":8001/admin/v1/timestamp # &>/dev/null | ||
do | ||
echo "MarkLogic hasn't started yet. Retrying in 3 seconds…" | ||
sleep 3 | ||
done | ||
|
||
# curl -X POST --data "" http://"$HOST":8001/admin/v1/init | ||
echo "Initializing…" | ||
curl --fail --show-error --silent -X POST --data "" http://"$HOST":8001/admin/v1/init 1>/dev/null | ||
if [[ $? != 0 ]] ; then | ||
echo "error on init" | ||
exit 1 | ||
fi | ||
echo "Completed initialization. Waiting for restart…" | ||
sleep 20 | ||
|
||
# curl -fsS --head --digest --user admin:"$ADMINPASSWORD" http://"$HOST":8001/admin/v1/timestamp | ||
# One liner: until curl -fsS --head http://192.168.56.101:8001/admin/v1/timestamp --digest --user admin:admin; do sleep 5; done | ||
|
||
|
||
until curl -fsS --head --digest --user "$ADMINUSER":"$ADMINPASSWORD" http://"$HOST":8001/admin/v1/timestamp &>/dev/null | ||
do | ||
echo "Restart hasn't completed. Retrying in 3 seconds…" | ||
sleep 3 | ||
done | ||
|
||
# curl -X POST -H "Content-type: application/x-www-form-urlencoded" --data "admin-username=admin" --data "admin-password=********" http://localhost:8001/admin/v1/instance-admin | ||
echo "Starting instance administration…" | ||
curl --fail --show-error --silent \ | ||
-X POST -H "Content-type: application/x-www-form-urlencoded" \ | ||
--data "admin-username=${ADMINUSER}" --data "admin-password=${ADMINPASSWORD}" --data "realm=public" \ | ||
http://"$HOST":8001/admin/v1/instance-admin 1>/dev/null | ||
if [[ $? != 0 ]] ; then | ||
echo "Error on instance-admin" | ||
exit 1 | ||
fi | ||
|
||
echo "Completed instance administration. Waiting for restart…" | ||
sleep 10 | ||
until curl -fsS --head --digest --user admin:"$ADMINPASSWORD" http://"$HOST":8001/admin/v1/timestamp &>/dev/null | ||
do | ||
echo "Restart hasn't completed. Retrying in 5 seconds…" | ||
sleep 5 | ||
done | ||
|
||
echo "Turning off log file rotation" | ||
curl --fail --show-error --silent \ | ||
-X PUT --digest -u "$ADMINUSER":"$ADMINPASSWORD" -H "Content-type: application/json" \ | ||
-d '{"rotate-log-files":"never"}' http://"$HOST":8002/manage/v2/groups/Default/properties &>/dev/null | ||
|
||
echo "Done!" | ||
exit 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
#!/bin/bash | ||
|
||
export MARKLOGIC_INSTALL_DIR=/opt/MarkLogic | ||
export MARKLOGIC_DATA_DIR=/data | ||
|
||
export MARKLOGIC_FSTYPE=ext4 | ||
export MARKLOGIC_USER=daemon | ||
export MARKLOGIC_PID_FILE=/var/run/MarkLogic.pid | ||
export MARKLOGIC_MLCMD_PID_FILE=/var/run/mlcmd.pid | ||
export MARKLOGIC_UMASK=022 | ||
|
||
export PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/opt/MarkLogic/mlcmd/bin | ||
export LD_PRELOAD=/opt/MarkLogic/lib/libjemalloc.so.1 | ||
export LD_LIBRARY_PATH=/opt/MarkLogic/lib:/data/Lib | ||
|
||
echo "STARTING MARKLOGIC" | ||
|
||
/opt/MarkLogic/bin/MarkLogic |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
version: '2' | ||
services: | ||
marklogic: | ||
build: | ||
context: ./ | ||
dockerfile: .travis/Dockerfile-ml | ||
ports: | ||
- "8000-8020" |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.