Commit fcdaaf30 authored by dgasull's avatar dgasull

Using dataClay 2.5 and dcinitializer

parent 339b6b65
FROM bscdataclay/client:2.5.dev-alpine
LABEL maintainer dataClay team <support-dataclay@bsc.es>
FROM bscdataclay/client:alpine
# Prepare environment
ENV ELASTIC_MODEL_HOME=/elastic
......
version: '3.4'
services:
logicmodule:
image: "bscdataclay/logicmodule:2.5.dev-alpine"
image: "bscdataclay/logicmodule:alpine"
ports:
- "11034:11034"
environment:
......@@ -9,9 +9,6 @@ services:
- LOGICMODULE_HOST=logicmodule
- DATACLAY_ADMIN_USER=admin
- DATACLAY_ADMIN_PASSWORD=admin
volumes:
- ./prop/global.properties:/home/dataclayusr/dataclay/cfgfiles/global.properties:ro
- ./prop/log4j2.xml:/home/dataclayusr/dataclay/logging/log4j2.xml:ro
stop_grace_period: 5m
healthcheck:
interval: 5s
......@@ -19,7 +16,7 @@ services:
test: ["CMD-SHELL", "/home/dataclayusr/dataclay/health/health_check.sh"]
dsjava:
image: "bscdataclay/dsjava:2.5.dev-alpine"
image: "bscdataclay/dsjava:alpine"
ports:
- "2127:2127"
depends_on:
......@@ -29,9 +26,6 @@ services:
- DATASERVICE_JAVA_PORT_TCP=2127
- LOGICMODULE_PORT_TCP=11034
- LOGICMODULE_HOST=logicmodule
volumes:
- ./prop/global.properties:/home/dataclayusr/dataclay/cfgfiles/global.properties:ro
- ./prop/log4j2.xml:/home/dataclayusr/dataclay/logging/log4j2.xml:ro
stop_grace_period: 5m
healthcheck:
interval: 5s
......
CHECK_LOG4J_ENABLED=false
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<Configuration monitorInterval="60" status="off">
<Appenders>
<Console name="ConsoleAppender" target="SYSTEM_ERR">
<PatternLayout pattern="%d{ISO8601} %p [%c] [%t] [%C{1}:%L] %m%n"></PatternLayout>
</Console>
</Appenders>
<Loggers>
<!-- Runtime -->
<Logger name="ClientRuntime" level="off" />
<Logger name="ClientManagementLib" level="off"/>
<Logger name="DataClayRuntime" level="off"/>
<Logger name="DataServiceRuntime" level="off"/>
<Logger name="DataClayObjectLoader" level="off"/>
<Logger name="DataClayObject" level="off" /> <!-- This is very verbose! -->
<!-- Data service -->
<Logger name="DataService" level="off"/>
<Logger name="DataService.srv" level="off"/>
<Logger name="ExecutionEnvironmentSrv" level="off"/>
<!-- Lockers -->
<Logger name="dataclay.util.classloaders.SyncClass" level="off"/>
<Logger name="dataclay.heap.LockerPool" level="off"/>
<Logger name="LockerPool" level="off"/>
<Logger name="dataclay.util.classloaders.ClassLockers" level="off"/>
<!-- Garbage collection -->
<Logger name="GlobalGC" level="off"/>
<Logger name="heap.HeapManager" level="off"/>
<Logger name="ReferenceCounting" level="off"/>
<Logger name="StorageLocation" level="off"/>
<!-- Logic module -->
<Logger name="LogicModule" level="off"/>
<Logger name="LogicModule.srv" level="off"/>
<Logger name="LMDB" level="off"/>
<Logger name="managers" level="off" />
<Logger name="MetaDataService.db" level="off" />
<Logger name="MetaDataService" level="off" />
<!-- Communication -->
<Logger name="io.grpc" level="off"/>
<Logger name="io.netty" level="off"/>
<Logger name="NettyClientHandler" level="off"/>
<Logger name="grpc.client" level="off"/>
<Logger name="grpc.client.logicmodule" level="off"/>
<Logger name="communication.LogicModule.service" level="off"/>
<!-- Databases -->
<Logger name="dataclay.dbhandler" level="off"/>
<Logger name="dbhandler.PostgresConnection" level="off" />
<Logger name="org.apache.commons.dbcp2" level="off"/>
<Logger name="PostgresHandler" level="off"/>
<Logger name="SQLHandler" level="off"/>
<!-- Misc -->
<Logger name="util" level="off" />
<Logger name="exceptions" level="off"/>
<Logger name="Paraver" level="info"/>
<Logger name="DataClaySerializationLib" level="off"/>
<Logger name="DataClayDeserializationLib" level="off"/>
<!-- ROOT LOGGER -->
<Root level="off">
<AppenderRef ref="ConsoleAppender" />
</Root>
</Loggers>
</Configuration>
......@@ -20,7 +20,7 @@ STUBSPATH=/elastic/stubs
docker run --rm --network=dataclay_default \
-v $PWD/cfgfiles/:/home/dataclayusr/dataclay/cfgfiles/:ro \
-v $PWD/stubs:/elastic/stubs:rw \
bscdataclay/client:2.5.dev-alpine GetStubs ${USER} ${PASS} ${NAMESPACE} ${STUBSPATH}
bscdataclay/client:alpine GetStubs ${USER} ${PASS} ${NAMESPACE} ${STUBSPATH}
echo "$blu
Stubs stored at $PWD/stubs/ directory
......
......@@ -20,7 +20,7 @@ popd
# wait for dataClay to be alive
docker run --rm --network=dataclay_default -v $PWD/cfgfiles/:/home/dataclayusr/dataclay/cfgfiles/:ro \
bscdataclay/client:2.5.dev-alpine WaitForDataClayToBeAlive 10 5
bscdataclay/client:alpine WaitForDataClayToBeAlive 10 5
printMsg "dataClay successfully started!"
......
......@@ -11,38 +11,11 @@ function printMsg {
echo "${blu}======== $1 ========${end}"
}
printMsg "Stopping dataClay"
echo "Optional commands=$COMMAND_OPTS"
export COMMAND_OPTS=$COMMAND_OPTS
pushd $SCRIPTDIR/dataclay
# first stop all dataclay services that are not logicmodule
# IMPORTANT: docker-compose stop will send a SIGTERM to ask dataClay to gracefully stop first, and then wait 5 minutes to
# send a SIGKILL to kill dataClay. It is very importat to do a graceful stop of dataClay to make sure that all
# objects created are flushed!!!
# IMPORTANT: First we should stop all python services, always in the following order 1.python - 2.java - 3.logicmodule
for SERVICE in $(docker-compose ps --services | grep python)
do
STARTTIME=$(date +%s)
docker-compose stop $SERVICE
ENDTIME=$(date +%s)
echo "$SERVICE stopped in $(($ENDTIME - $STARTTIME)) seconds"
done
# IMPORTANT: Now all java services
for SERVICE in $(docker-compose ps --services | grep java)
do
STARTTIME=$(date +%s)
docker-compose stop $SERVICE
ENDTIME=$(date +%s)
echo "$SERVICE stopped in $(($ENDTIME - $STARTTIME)) seconds"
done
# IMPORTANT: finally Logic module
STARTTIME=$(date +%s)
docker-compose stop logicmodule
docker-compose down
ENDTIME=$(date +%s)
echo "logicmodule stopped in $(($ENDTIME - $STARTTIME)) seconds"
echo "dataClay stopped in $(($ENDTIME - $STARTTIME)) seconds"
popd
printMsg "dataClay successfully stopped!"
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment