Strabon

changeset 834:5e4a561d0a11 DiffDateTime

fix logging and add comment for example command
author George Garbis <ggarbis@di.uoa.gr>
date Thu Jan 03 19:31:25 2013 +0200 (2013-01-03)
parents e933de33721c
children 250d177995ca
files endpoint/src/log4j.properties examples/teleios/runChain.sh runtime/src/main/resources/log4j.properties
line diff
     1.1 --- a/endpoint/src/log4j.properties	Thu Jan 03 15:30:23 2013 +0200
     1.2 +++ b/endpoint/src/log4j.properties	Thu Jan 03 19:31:25 2013 +0200
     1.3 @@ -1,6 +1,6 @@
     1.4  # logger level values: OFF, ERROR, WARN, INFO, DEBUG, ALL
     1.5 -log4j.rootLogger=INFO, CA
     1.6 -#log4j.rootLogger=INFO, CA, FA
     1.7 +#log4j.rootLogger=INFO, CA
     1.8 +log4j.rootLogger=DEBUG, CA, FA
     1.9  
    1.10  # Console Appender
    1.11  log4j.appender.CA=org.apache.log4j.ConsoleAppender
     2.1 --- a/examples/teleios/runChain.sh	Thu Jan 03 15:30:23 2013 +0200
     2.2 +++ b/examples/teleios/runChain.sh	Thu Jan 03 19:31:25 2013 +0200
     2.3 @@ -14,6 +14,8 @@
     2.4  # Author: Konstantina Bereta <Konstantina.Bereta@di.uoa.gr>
     2.5  #
     2.6  
     2.7 +# Example run command: examples/teleios/runChain.sh -b http://dev.strabon.di.uoa.gr/rdf/data-dump-postgres-9.tgz  -l /home/ggarbis/runChain.log -e http://pathway.di.uoa.gr:8080/endpoint
     2.8 +
     2.9  # Command name
    2.10  cmd="$(basename ${0})" 
    2.11  # Get the directory where the script resides
    2.12 @@ -166,11 +168,10 @@
    2.13  	elif test "${bgFile:0:7}" = "http://"; then
    2.14  		curl -s ${bgFile} | tar xzf - -O > /tmp/bgFiles$$.sql
    2.15  #		wget ${bgFile} -O /tmp/bgFile$$.tar.gz
    2.16 -#		tar xzf /tmp/bgFile$$.tar.gz
    2.17 -		
    2.18 +#		tar xzf /tmp/bgFile$$.tar.gz		
    2.19  		handlePostgresDatabase runscript ${db} /tmp/bgFiles$$.sql
    2.20 -		rm /tmp/bgFile$$.tar.gz
    2.21 -		rm /tmp/bgFile$$.sql
    2.22 +#		rm /tmp/bgFile$$.tar.gz
    2.23 +		rm /tmp/bgFiles$$.sql
    2.24  	else
    2.25  		echo "Backgound file not foung"
    2.26  		exit -1
    2.27 @@ -231,7 +232,8 @@
    2.28  endpoint="http://pathway.di.uoa.gr:8080/endpoint"
    2.29  db="NOA2012"
    2.30  hotspotsURL="http://jose.di.uoa.gr/rdf/hotspots/MSG1"
    2.31 -bgFile="http://dev.strabon.di.uoa.gr/rdf/Kallikratis-Coastline-Corine-dump-postgres-9.tgz"
    2.32 +#                                 ./examples/teleios/data/data-dump-9.sql
    2.33 +bgFile="http://dev.strabon.di.uoa.gr/rdf/Kallikratis-Coastline-ExcludeArea-dump.tgz"
    2.34  logFile="runChain.log"
    2.35  
    2.36  chain="DynamicThresholds"
    2.37 @@ -370,7 +372,7 @@
    2.38          # Delete Reflections
    2.39      	minTime=`date --date="${year}-${month}-${day} ${time2}:00 EEST -60 minutes" +%Y-%m-%dT%H:%M:00`
    2.40  		update="`${instantiate} -t ${timestamp} -c ${chain} -s ${sensor} -m ${minTime} ${loc}/deleteReflections.rq`"
    2.41 -        echo "Delete Reflections: ${update}" ;
    2.42 +#        echo "Delete Reflections: ${update}" ;
    2.43  		handleStrabonEndpoint ${endpoint} update "${update}"
    2.44  
    2.45  		# Refine Partial Sea Hotspots
    2.46 @@ -391,14 +393,14 @@
    2.47  		maxTime=`date --date="${year}-${month}-${day} 23:59 EEST" +%Y-%m-%dT%H:%M:00`
    2.48          query="`${instantiate} -c ${chain} -s ${sensor} -m ${minTime} -M ${maxTime} ${loc}/discover.rq`"
    2.49  #        echo "Discover: ${query}" ; #read t
    2.50 -		handleStrabonEndpoint ${endpoint} query "${query}" 2>&1 >> /home/ggarbis/discover.log
    2.51 +		handleStrabonEndpoint ${endpoint} query "${query}" &>> /home/ggarbis/discover.log
    2.52      
    2.53  		# Discover Fires
    2.54  		minTime=`date --date="${year}-${month}-${day} 00:00 EEST" +%Y-%m-%dT%H:%M:00`
    2.55  		maxTime=`date --date="${year}-${month}-${day} 23:59 EEST" +%Y-%m-%dT%H:%M:00`
    2.56          query="`${instantiate} -c ${chain} -s ${sensor} -m ${minTime} -M ${maxTime} -p 10 -r 3 ${loc}/discoverFires.rq`"
    2.57  #        echo "Discover Fires: ${query}" ; #read t
    2.58 -		handleStrabonEndpoint ${endpoint} query "${query}" 2>&1 >> /home/ggarbis/discoverFires.log
    2.59 +		handleStrabonEndpoint ${endpoint} query "${query}" &>> /home/ggarbis/discoverFires.log
    2.60  
    2.61          echo >> ${logFile}    
    2.62  	done
     3.1 --- a/runtime/src/main/resources/log4j.properties	Thu Jan 03 15:30:23 2013 +0200
     3.2 +++ b/runtime/src/main/resources/log4j.properties	Thu Jan 03 19:31:25 2013 +0200
     3.3 @@ -1,6 +1,6 @@
     3.4  # logger level values: OFF, ERROR, WARN, INFO, DEBUG, ALL
     3.5 -log4j.rootLogger=INFO, CA
     3.6 -#log4j.rootLogger=DEBUG, CA
     3.7 +#log4j.rootLogger=INFO, CA
     3.8 +log4j.rootLogger=DEBUG, CA
     3.9  #log4j.rootLogger=INFO, CA, FA
    3.10  
    3.11  # Console Appender