[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[or-cvs] [metrics-db/master] Stop calling the (deleted) db/refresh.sql script.
commit 05da2dd7d3d3c95d7bd6cdaa25f2759a7512cb2d
Author: Karsten Loesing <karsten.loesing@xxxxxxx>
Date: Tue Jan 18 09:56:40 2011 +0100
Stop calling the (deleted) db/refresh.sql script.
Refreshing the materialized views should be done by calling refresh_all()
using psql.
---
run.sh | 16 ----------------
1 files changed, 0 insertions(+), 16 deletions(-)
diff --git a/run.sh b/run.sh
index 30af813..e804876 100755
--- a/run.sh
+++ b/run.sh
@@ -3,19 +3,3 @@
# TODO is there a better way to suppress Ant's output?
ant -q | grep -Ev "^$|^BUILD SUCCESSFUL|^Total time: "
-# Refresh matviews if we are supposed to
-n=`grep "^WriteRelayDescriptorDatabase" config | awk '{print $2}'`
-if [ "$n" -eq 1 ]; then
- # TODO Alternatively use a more reliable URI parser?
- #db=$( echo "$uri" | ruby -ruri -e 'puts URI.parse(gets.chomp).path' )
-
- uri=`grep "^RelayDescriptorDatabaseJDBC" config | awk '{print $2}'`
- conn=`echo $uri | awk -F"//" '{print $2}'`
- host=`echo $conn | sed -e 's/\/.*//'`
- db=`echo $conn | awk -F"/" '{print $2}' | sed -e 's/\?.*//'`
- user=`echo $conn | awk -F"=" '{print $2}' | sed -e 's/\&.*//'`
- pswd=`echo $conn | awk -F"password=" '{print $2}'`
-
- export PGPASSWORD="$pswd"
- psql -d $db -h $host -A -t -q -U $user -f db/refresh.sql
-fi