You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by th...@apache.org on 2014/11/11 05:28:43 UTC
svn commit: r1638025 -
/lucene/dev/branches/branch_5x/dev-tools/scripts/smokeTestRelease.py
Author: thelabdude
Date: Tue Nov 11 04:28:42 2014
New Revision: 1638025
URL: http://svn.apache.org/r1638025
Log:
SOLR-6708: Smoke tester couldn't communicate with Solr started using 'bin/solr start'
Modified:
lucene/dev/branches/branch_5x/dev-tools/scripts/smokeTestRelease.py
Modified: lucene/dev/branches/branch_5x/dev-tools/scripts/smokeTestRelease.py
URL: http://svn.apache.org/viewvc/lucene/dev/branches/branch_5x/dev-tools/scripts/smokeTestRelease.py?rev=1638025&r1=1638024&r2=1638025&view=diff
==============================================================================
--- lucene/dev/branches/branch_5x/dev-tools/scripts/smokeTestRelease.py (original)
+++ lucene/dev/branches/branch_5x/dev-tools/scripts/smokeTestRelease.py Tue Nov 11 04:28:42 2014
@@ -859,7 +859,10 @@ def testSolrExample(unpackPath, javaPath
env.update(os.environ)
env['JAVA_HOME'] = javaPath
env['PATH'] = '%s/bin:%s' % (javaPath, env['PATH'])
- server = subprocess.Popen(['bin/solr', '-f'], stdout=subprocess.PIPE, stderr=subprocess.STDOUT, stdin=subprocess.PIPE, env=env)
+ # Stop Solr running on port 8983 (in case a previous run didn't shutdown cleanly)
+ subprocess.call(['bin/solr','stop','-p','8983'])
+ print(' starting Solr on port 8983 from %s' % unpackPath)
+ server = subprocess.Popen(['bin/solr', '-f', '-p', '8983'], stdout=subprocess.PIPE, stderr=subprocess.STDOUT, stdin=subprocess.PIPE, env=env)
startupEvent = threading.Event()
failureEvent = threading.Event()
@@ -887,9 +890,7 @@ def testSolrExample(unpackPath, javaPath
print(' test utf8...')
run('sh ./exampledocs/test_utf8.sh http://localhost:8983/solr/techproducts', 'utf8.log')
print(' index example docs...')
- # "$JAVA" -Durl=http://localhost:$SOLR_PORT/solr/$EXAMPLE/update -jar $SOLR_TIP/example/exampledocs/post.jar $SOLR_TIP/example/exampledocs/*.xml
run('java -Durl=http://localhost:8983/solr/techproducts/update -jar ./exampledocs/post.jar ./exampledocs/*.xml', 'post-example-docs.log')
- #run('sh ./exampledocs/post.sh ./exampledocs/*.xml', 'post-example-docs.log')
print(' run query...')
s = urllib.request.urlopen('http://localhost:8983/solr/techproducts/select/?q=video').read().decode('UTF-8')
if s.find('<result name="response" numFound="3" start="0">') == -1:
@@ -898,7 +899,6 @@ def testSolrExample(unpackPath, javaPath
finally:
# Stop server:
print(' stop server using: bin/solr stop -p 8983')
- #os.kill(server.pid, signal.SIGINT)
if isSrc:
os.chdir(unpackPath+'/solr')
else: