diff --git a/Makefile b/Makefile index dba9c028..b2fde265 100644 --- a/Makefile +++ b/Makefile @@ -16,6 +16,8 @@ deps: clean: $(REBAR) clean rm -rf riak_test/ebin + rm -rf build + git clean -dfx priv/solr distclean: clean $(REBAR) delete-deps diff --git a/priv/conf/solrconfig.xml b/priv/conf/solrconfig.xml index d6417dc3..53ea8b6a 100644 --- a/priv/conf/solrconfig.xml +++ b/priv/conf/solrconfig.xml @@ -4,7 +4,7 @@ this file, see http://wiki.apache.org/solr/SolrConfigXml. --> - LUCENE_43 + 4.4 + formdataUploadLimitInKB="102400" + addHttpRequestToContext="false"/> - + @@ -430,7 +426,7 @@ - + @@ -442,7 +438,7 @@ - + @@ -464,7 +460,7 @@ - + @@ -474,7 +470,7 @@ - + @@ -484,7 +480,7 @@ - + @@ -498,7 +494,7 @@ - + @@ -508,7 +504,7 @@ - + @@ -519,7 +515,7 @@ - + @@ -533,7 +529,7 @@ - + @@ -542,7 +538,7 @@ - + @@ -555,7 +551,7 @@ - + @@ -569,9 +565,9 @@ - + - + @@ -581,7 +577,7 @@ - + @@ -596,7 +592,7 @@ - + @@ -606,7 +602,7 @@ - + @@ -617,7 +613,7 @@ - + @@ -627,7 +623,7 @@ - + @@ -640,7 +636,7 @@ - + @@ -685,11 +681,11 @@ - + - + @@ -702,7 +698,7 @@ - + @@ -712,7 +708,7 @@ - + @@ -723,7 +719,7 @@ - + @@ -735,7 +731,7 @@ - + @@ -748,7 +744,7 @@ - + @@ -758,7 +754,7 @@ - + @@ -769,7 +765,7 @@ - + @@ -781,7 +777,7 @@ - + @@ -790,7 +786,7 @@ - + diff --git a/priv/template_solr.xml b/priv/template_solr.xml index 42bbd03c..3d6eacb6 100644 --- a/priv/template_solr.xml +++ b/priv/template_solr.xml @@ -1,22 +1,10 @@ - - - - - diff --git a/solr-patches/no-stale-check.patch b/solr-patches/no-stale-check.patch index d2e19935..4b16e844 100644 --- a/solr-patches/no-stale-check.patch +++ b/solr-patches/no-stale-check.patch @@ -1,4 +1,4 @@ -From 47a169fe3eee2ff8edc2fbea15040993fd48c81b Mon Sep 17 00:00:00 2001 +From 7f09bcb1e795e58a6f1fe525a20526e5a2430bc6 Mon Sep 17 00:00:00 2001 From: Ryan Zezeski Date: Tue, 12 Feb 2013 11:54:21 -0500 Subject: [PATCH] Disable stale check and nagle @@ -12,31 +12,31 @@ Subject: [PATCH] Disable stale check and nagle * Disable nagle as it's meant for protocols that use many small messages. --- - .../solr/handler/component/HttpShardHandlerFactory.java | 3 +++ - .../org/apache/solr/client/solrj/impl/HttpClientUtil.java | 13 +++++++++++++ + .../solr/handler/component/HttpShardHandlerFactory.java | 3 +++ + .../org/apache/solr/client/solrj/impl/HttpClientUtil.java | 13 +++++++++++++ 2 files changed, 16 insertions(+) diff --git a/solr/core/src/java/org/apache/solr/handler/component/HttpShardHandlerFactory.java b/solr/core/src/java/org/apache/solr/handler/component/HttpShardHandlerFactory.java -index 27f9f79..2537705 100644 +index d55e01f..cc59731 100644 --- a/solr/core/src/java/org/apache/solr/handler/component/HttpShardHandlerFactory.java +++ b/solr/core/src/java/org/apache/solr/handler/component/HttpShardHandlerFactory.java -@@ -20,6 +20,7 @@ import java.net.MalformedURLException; - import java.util.Random; - import java.util.concurrent.*; +@@ -29,6 +29,7 @@ import java.util.concurrent.SynchronousQueue; + import java.util.concurrent.ThreadPoolExecutor; + import java.util.concurrent.TimeUnit; +import org.apache.http.params.HttpConnectionParams; import org.apache.http.client.HttpClient; + import org.apache.solr.client.solrj.SolrServerException; import org.apache.solr.client.solrj.impl.HttpClientUtil; - import org.apache.solr.client.solrj.impl.LBHttpSolrServer; -@@ -132,6 +133,8 @@ public class HttpShardHandlerFactory extends ShardHandlerFactory implements Plug +@@ -150,6 +151,8 @@ public class HttpShardHandlerFactory extends ShardHandlerFactory implements org. clientParams.set(HttpClientUtil.PROP_CONNECTION_TIMEOUT, connectionTimeout); clientParams.set(HttpClientUtil.PROP_USE_RETRY, false); this.defaultClient = HttpClientUtil.createClient(clientParams); + this.defaultClient.getParams().setParameter(HttpConnectionParams.STALE_CONNECTION_CHECK, false); + this.defaultClient.getParams().setParameter(HttpConnectionParams.TCP_NODELAY, true); + this.loadbalancer = createLoadbalancer(defaultClient); + } - try { - loadbalancer = new LBHttpSolrServer(defaultClient); diff --git a/solr/solrj/src/java/org/apache/solr/client/solrj/impl/HttpClientUtil.java b/solr/solrj/src/java/org/apache/solr/client/solrj/impl/HttpClientUtil.java index 3887302..4649138 100644 --- a/solr/solrj/src/java/org/apache/solr/client/solrj/impl/HttpClientUtil.java @@ -69,5 +69,5 @@ index 3887302..4649138 100644 return httpClient; } -- -1.7.10.4 +1.8.1.2 diff --git a/tools/build-solr.sh b/tools/build-solr.sh index a9b9fbb6..e5b97fee 100755 --- a/tools/build-solr.sh +++ b/tools/build-solr.sh @@ -10,6 +10,8 @@ #> #> ./build-solr.sh --patch-dir ~/yokozuna/solr-patches /tmp/build-solr solr-4.2.0-yz http://www.motorlogy.com/apache/lucene/solr/4.2.0/solr-4.2.0-src.tgz | tee build-solr.out +set -e + error() { echo "ERROR: $1" @@ -68,14 +70,13 @@ WORK_DIR=$1; shift NAME=$1; shift URL=$1; shift -if [ ! -x "`which ant`"]; then +if [ ! -x "`which ant`" ]; then echo "Couldn't find ant, which is needed to compile Solr." exit 1 fi -mkdir $WORK_DIR if test ! -e $WORK_DIR; then - error "failed to created work dir: $WORK_DIR" + mkdir $WORK_DIR fi cd $WORK_DIR diff --git a/tools/grab-solr.sh b/tools/grab-solr.sh index 8ca49609..627e2994 100755 --- a/tools/grab-solr.sh +++ b/tools/grab-solr.sh @@ -15,7 +15,7 @@ fi SOLR_DIR=../priv/solr BUILD_DIR=../build -VSN=solr-4.3.0-yz +VSN=solr-4.4.0-yz FILENAME=$VSN.tgz TMP_DIR=/tmp/yokozuna TMP_FILE=$TMP_DIR/$FILENAME @@ -38,8 +38,12 @@ get_solr() else echo "Pulling Solr from S3" wget --no-check-certificate --progress=dot:mega https://s3.amazonaws.com/yzami/pkgs/$FILENAME - mkdir $TMP_DIR - cp $FILENAME $TMP_DIR + if [ -d $TMP_DIR ]; then + cp $FILENAME $TMP_DIR + else + mkdir $TMP_DIR + cp $FILENAME $TMP_DIR + fi fi else # This is now obsolete thanks to implicit caching above