ingo@3683: #!/bin/bash ingo@3683: ingo@3683: ######################### CONFIG OPTIONS ############################ ingo@3683: BACKEND_USER="flys28" ingo@3683: BACKEND_PASS="flys28" ingo@3683: BACKEND_HOST="czech-republic.atlas.intevation.de" ingo@3683: BACKEND_PORT="1521" ingo@3683: BACKEND_NAME="XE" ingo@3683: LOG4J_CONFIG="conf/log4j.properties" aheinecke@5066: JAR="hydr_morph/importer.jar" ingo@3683: ##################################################################### ingo@3683: ingo@3683: ingo@3683: ########################## Oracle Settings ########################## ingo@3683: BACKEND_DB_PREFIX="jdbc:oracle:thin:@" ingo@3683: BACKEND_DB_DRIVER="oracle.jdbc.OracleDriver" ingo@3683: BACKEND_DB_DIALECT="org.hibernate.dialect.OracleDialect" ingo@3683: BACKEND_URL=$BACKEND_DB_PREFIX//$BACKEND_HOST:$BACKEND_PORT/$BACKEND_NAME ingo@3683: ##################################################################### ingo@3683: ingo@3683: ingo@3683: ######################## Custom Importer Settings ################### ingo@3683: IMPORTER_DRY_RUN=false tom@6449: IMPORTER_MAINVALUE_TYPES=QWTD- ingo@3683: IMPORTER_ANNOTATION_TYPES="conf/annotation-types.xml" ingo@3683: felix@5043: IMPORTER_SKIP_ANNOTATIONS=false felix@5043: IMPORTER_SKIP_BWASTR=false felix@5043: IMPORTER_SKIP_DA50S=false felix@5043: IMPORTER_SKIP_DA66S=false felix@5043: IMPORTER_SKIP_EXTRA_WST=false felix@5043: IMPORTER_SKIP_FIXATIONS=false felix@5043: IMPORTER_SKIP_FLOOD_WATER=false felix@5043: IMPORTER_SKIP_FLOOD_PROTECTION=false ingo@3683: IMPORTER_SKIP_GAUGES=false tom@7326: IMPORTER_SKIP_HISTORICAL_DISCHARGE_GAUGES=true felix@5043: IMPORTER_SKIP_HYKS=false felix@5043: IMPORTER_SKIP_OFFICIAL_LINES=false ingo@3683: IMPORTER_SKIP_PRFS=false felix@4766: IMPORTER_SKIP_W80S=false felix@5807: IMPORTER_SKIP_W80_CSVS=false felix@5043: IMPORTER_SKIP_WST=false ingo@3683: tom@6417: IMPORTER_SKIP_MEASUREMENT_STATIONS=false ingo@3683: IMPORTER_SKIP_BED_HEIGHT_SINGLE=false felix@5043: IMPORTER_SKIP_FLOW_VELOCITY=false ingo@3683: IMPORTER_SKIP_MORPHOLOGICAL_WIDTH=false tom@7882: IMPORTER_SKIP_POROSITY=false felix@5043: IMPORTER_SKIP_SEDIMENT_DENSITY=false tom@8032: IMPORTER_SKIP_SEDIMENT_LOAD_LS=false felix@5043: IMPORTER_SKIP_SQ_RELATION=false ingo@3683: IMPORTER_SKIP_WATERLEVELS=false ingo@3683: IMPORTER_SKIP_WATERLEVEL_DIFFERENCES=false ingo@3683: ##################################################################### ingo@3683: tom@6816: MIN_MEMORY="8192m" ingo@3683: aheinecke@5066: ######################### Run Importer ############################## tom@6811: INFO_GEW=$1 tom@6811: aheinecke@5066: OPTIONAL_LIBS="${DIR}"/../opt aheinecke@5066: if [ -d "$OPTIONAL_LIBS" ]; then aheinecke@5066: export PATH="$OPTIONAL_LIBS/bin:$PATH" aheinecke@5066: export LD_LIBRARY_PATH="$OPTIONAL_LIBS/lib:$LD_LIBRARY_PATH" aheinecke@5066: export LD_LIBRARY_PATH="$OPTIONAL_LIBS/lib64:$LD_LIBRARY_PATH" aheinecke@5066: fi ingo@3683: tom@6651: # Default encoding. Change here if necessary tom@6651: export LC_ALL=de_DE@euro ingo@3683: aheinecke@5066: exec java -jar \ ingo@3683: -Xmx$MIN_MEMORY \ ingo@3683: -server \ ingo@3683: -Dlog4j.configuration=file://`readlink -f $LOG4J_CONFIG` \ ingo@3683: -Dflys.backend.importer.infogew.file=$INFO_GEW \ ingo@3683: -Dflys.backend.main.value.types=$IMPORTER_MAINVALUE_TYPES \ ingo@3683: -Dflys.backend.importer.annotation.types=$IMPORTER_ANNOTATION_TYPES \ ingo@3683: -Dflys.backend.importer.dry.run=$IMPORTER_DRY_RUN \ felix@5042: -Dflys.backend.importer.skip.annotations=$IMPORTER_SKIP_ANNOTATIONS \ felix@5042: -Dflys.backend.importer.skip.bed.height.single=$IMPORTER_SKIP_BED_HEIGHT_SINGLE \ felix@5018: -Dflys.backend.importer.skip.bwastr=$IMPORTER_SKIP_BWASTR \ felix@4766: -Dflys.backend.importer.skip.da50s=$IMPORTER_SKIP_DA50S \ felix@4711: -Dflys.backend.importer.skip.da66s=$IMPORTER_SKIP_DA66S \ ingo@3683: -Dflys.backend.importer.skip.extra.wsts=$IMPORTER_SKIP_EXTRA_WST \ ingo@3683: -Dflys.backend.importer.skip.fixations=$IMPORTER_SKIP_FIXATIONS \ ingo@3683: -Dflys.backend.importer.skip.flood.water=$IMPORTER_SKIP_FLOOD_WATER \ ingo@3683: -Dflys.backend.importer.skip.flood.protection=$IMPORTER_SKIP_FLOOD_PROTECTION \ tom@6417: -Dflys.backend.importer.skip.measurement.stations=$IMPORTER_SKIP_MEASUREMENT_STATIONS \ felix@5042: -Dflys.backend.importer.skip.flow.velocity=$IMPORTER_SKIP_FLOW_VELOCITY \ felix@5042: -Dflys.backend.importer.skip.gauges=$IMPORTER_SKIP_GAUGES \ felix@5042: -Dflys.backend.importer.skip.historical.discharge.tables=$IMPORTER_SKIP_HISTORICAL_DISCHARGE_GAUGES \ felix@5042: -Dflys.backend.importer.skip.hyks=$IMPORTER_SKIP_HYKS \ felix@5042: -Dflys.backend.importer.skip.morphological.width=$IMPORTER_SKIP_MORPHOLOGICAL_WIDTH \ tom@7882: -Dflys.backend.importer.skip.porosity=$IMPORTER_SKIP_POROSITY \ felix@5042: -Dflys.backend.importer.skip.official.lines=$IMPORTER_SKIP_OFFICIAL_LINES \ felix@5042: -Dflys.backend.importer.skip.prfs=$IMPORTER_SKIP_PRFS \ ingo@3683: -Dflys.backend.importer.skip.sediment.density=$IMPORTER_SKIP_SEDIMENT_DENSITY \ tom@8032: -Dflys.backend.importer.skip.sediment.load.ls=$IMPORTER_SKIP_SEDIMENT_LOAD_LS \ felix@5042: -Dflys.backend.importer.skip.sq.relation=$IMPORTER_SKIP_SQ_RELATION \ felix@5042: -Dflys.backend.importer.skip.w80s=$IMPORTER_SKIP_W80S \ felix@5807: -Dflys.backend.importer.skip.w80.csvs=$IMPORTER_SKIP_W80_CSVS \ ingo@3683: -Dflys.backend.importer.skip.waterlevels=$IMPORTER_SKIP_WATERLEVELS \ ingo@3683: -Dflys.backend.importer.skip.waterlevel.differences=$IMPORTER_SKIP_WATERLEVEL_DIFFERENCES \ felix@5042: -Dflys.backend.importer.skip.wst=$IMPORTER_SKIP_WST \ ingo@3683: -Dflys.backend.user=$BACKEND_USER \ ingo@3683: -Dflys.backend.password=$BACKEND_PASS \ ingo@3683: -Dflys.backend.url=$BACKEND_URL \ ingo@3683: -Dflys.backend.driver=$BACKEND_DB_DRIVER \ ingo@3683: -Dflys.backend.dialect=$BACKEND_DB_DIALECT \ aheinecke@5066: $JAR