queryHistData.sh 536 B

123456789101112131415161718
  1. #!/usr/bin/env bash
  2. #host=39.104.80.229
  3. host=127.0.0.1
  4. for days in 1 2 3 4 7 15 30 60 90 180 360
  5. do
  6. echo "----test query range days:$days"
  7. beginDate="2021-03-01 00:00:00"
  8. echo beginDate:beginDate
  9. endDate=$(date -d "${beginDate} ${days} days" +"%Y-%m-%d %H:%M:%S")
  10. echo endDate:$endDate
  11. java -cp ./lib/tsdb.jar demo.query.histQuery.QueryHistData \
  12. --host=$host --pointNamePrefix=pointName_ --pointCount=1 \
  13. --beginDate="$beginDate" --endDate="$endDate" \
  14. --showQueryResult=10000 2>&1 | tee -a ./log/tsdb/out.log
  15. done