Repository: incubator-wave
Updated Branches:
  refs/heads/master 20ae1d86c -> 65653a59e


WAVE-311 Allows to download the Solr dependency via ant and run with 
run-solr.sh script.


Project: http://git-wip-us.apache.org/repos/asf/incubator-wave/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-wave/commit/ef9a9a93
Tree: http://git-wip-us.apache.org/repos/asf/incubator-wave/tree/ef9a9a93
Diff: http://git-wip-us.apache.org/repos/asf/incubator-wave/diff/ef9a9a93

Branch: refs/heads/master
Commit: ef9a9a93e6de8c169e0510f454c10ad5828eee1b
Parents: ca645a7
Author: Yuri Zelikov <[email protected]>
Authored: Thu Aug 21 21:29:44 2014 +0300
Committer: Yuri Zelikov <[email protected]>
Committed: Wed Aug 27 19:17:55 2014 +0300

----------------------------------------------------------------------
 build.properties |  1 +
 build.xml        | 25 +++++++++++++++++++------
 run-solr.sh      | 33 +++++++++++++++++++++++++++++++++
 3 files changed, 53 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-wave/blob/ef9a9a93/build.properties
----------------------------------------------------------------------
diff --git a/build.properties b/build.properties
index 6a94a2d..37802f9 100644
--- a/build.properties
+++ b/build.properties
@@ -49,6 +49,7 @@ lib.test=${lib.dir}/test
 lib.runtime=${lib.dir}/runtime
 lib.codegen=${lib.dir}/codegen
 lib.release=${lib.dir}/release
+lib.solr=${lib.dir}/solr
 
 # Intermediary build directories (temporary)
 build.dir=${basedir}/build

http://git-wip-us.apache.org/repos/asf/incubator-wave/blob/ef9a9a93/build.xml
----------------------------------------------------------------------
diff --git a/build.xml b/build.xml
index c9d6beb..41a154f 100644
--- a/build.xml
+++ b/build.xml
@@ -62,6 +62,7 @@
     <delete dir="${lib.codegen}"/>
     <delete dir="${lib.runtime}"/>
     <delete dir="${lib.release}"/>
+    <delete dir="${lib.solr}"/>
   </target>
 
   <target name="init-logging" description="Enable logging to file">
@@ -85,6 +86,7 @@
     <mkdir dir="${lib.codegen}"/>
     <mkdir dir="${lib.runtime}"/>
     <mkdir dir="${lib.release}"/>
+    <mkdir dir="${lib.solr}"/>
     <mkdir dir="${gen.dir}/gxp"/>
     <mkdir dir="${gen.dir}/messages"/>
   </target>
@@ -1100,14 +1102,25 @@
   </target>
 
   <target name="get-third-party-release-dep" depends="init" 
description="Download release tool third party dependencies">
-       <get dest="${lib.release}" usetimestamp="true" skipexisting="true">
-         <url 
url="http://apache.spd.co.il/creadur/apache-rat-0.10/apache-rat-0.10-bin.zip"; />
-       </get>
-       <unzip src="${lib.release}/apache-rat-0.10-bin.zip" 
dest="${lib.release}">
-         <patternset>
+    <get dest="${lib.release}" usetimestamp="true" skipexisting="true">
+      <url 
url="http://apache.spd.co.il/creadur/apache-rat-0.10/apache-rat-0.10-bin.zip"; />
+    </get>
+    <unzip src="${lib.release}/apache-rat-0.10-bin.zip" dest="${lib.release}">
+      <patternset>
         <include name="apache-rat-0.10/apache-rat-0.10.jar"/>
       </patternset>
-         <mapper type="flatten"/>
+      <mapper type="flatten"/>
+    </unzip>
+  </target>
+
+  <target name="get-third-party-solr-dep" depends="init" description="Download 
Solr third party dependencies.">
+    <get dest="${lib.solr}" usetimestamp="true" skipexisting="true">
+      <url url="http://apache.spd.co.il/lucene/solr/4.9.0/solr-4.9.0.zip"; />
+    </get>
+    <unzip src="${lib.solr}/solr-4.9.0.zip" dest="${lib.solr}">
+      <patternset>
+        <include name="solr-4.9.0/example/"/>
+      </patternset>
     </unzip>
   </target>
 

http://git-wip-us.apache.org/repos/asf/incubator-wave/blob/ef9a9a93/run-solr.sh
----------------------------------------------------------------------
diff --git a/run-solr.sh b/run-solr.sh
new file mode 100755
index 0000000..7f18090
--- /dev/null
+++ b/run-solr.sh
@@ -0,0 +1,33 @@
+#!/bin/bash
+
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+# This script will start the Solr server.
+
+# Make sure the third_party/solr/solr-4.9.0/example folder exists.
+if [ ! -d third_party/solr/solr-4.9.0/example ]; then
+  echo "You need to download the solr third party dependency into 
third_party/solr/ and unzip it by running: ant get-third-party-solr-dep. "
+  echo "Or download it manually from 
http://apache.spd.co.il/lucene/solr/4.9.0/ into third_party/solr and unzip 
there."
+  exit 1
+fi
+
+
+exec java \
+  -Dsolr.solr.home=third_party/solr/solr-4.9.0/example/solr\
+  -Djetty.home=third_party/solr/solr-4.9.0/example\
+  -jar third_party/solr/solr-4.9.0/example/start.jar

Reply via email to