You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by GitBox <gi...@apache.org> on 2020/06/09 15:56:27 UTC
[GitHub] [incubator-pinot] fx19880617 commented on a change in pull request #5508: Fix Travis quickstart tests
fx19880617 commented on a change in pull request #5508:
URL: https://github.com/apache/incubator-pinot/pull/5508#discussion_r437130895
##########
File path: .travis/.travis_quickstart.sh
##########
@@ -30,60 +30,75 @@ java -version
# Quickstart
DIST_BIN_DIR=`ls -d pinot-distribution/target/apache-pinot-*/apache-pinot-*`
-cd ${DIST_BIN_DIR}
+cd "${DIST_BIN_DIR}"
# Test quick-start-batch
bin/quick-start-batch.sh &
PID=$!
PASS=0
+
+# Wait for 30 seconds for table to be set up, then at most 5 minutes to reach the desired state
sleep 30
-for i in $(seq 1 200)
+for i in $(seq 1 300)
do
- COUNT_STAR_RES=`curl -X POST --header 'Accept: application/json' -d '{"sql":"select count(*) from baseballStats limit 1","trace":false}' http://localhost:8000/query/sql | jq '.resultTable.rows[0][0]'`
- if [[ "${COUNT_STAR_RES}" =~ ^[0-9]+$ ]]; then
- if [ "${COUNT_STAR_RES}" -eq 97889 ]; then
+ QUERY_RES=`curl -X POST --header 'Accept: application/json' -d '{"sql":"select count(*) from baseballStats limit 1","trace":false}' http://localhost:8000/query/sql`
+ if [ $? -eq 0 ]; then
+ COUNT_STAR_RES=`echo "${QUERY_RES}" | jq '.resultTable.rows[0][0]'`
+ if [[ "${COUNT_STAR_RES}" =~ ^[0-9]+$ ]] && [ "${COUNT_STAR_RES}" -eq 97889 ]; then
PASS=1
break
fi
fi
sleep 1
Review comment:
how about sleep 2 or 3 seconds instead of just 1 ?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org