Return-Path: Delivered-To: apmail-lucene-solr-commits-archive@locus.apache.org Received: (qmail 97218 invoked from network); 1 Nov 2008 04:50:18 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 1 Nov 2008 04:50:18 -0000 Received: (qmail 94864 invoked by uid 500); 1 Nov 2008 04:50:23 -0000 Delivered-To: apmail-lucene-solr-commits-archive@lucene.apache.org Received: (qmail 94827 invoked by uid 500); 1 Nov 2008 04:50:23 -0000 Mailing-List: contact solr-commits-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: solr-dev@lucene.apache.org Delivered-To: mailing list solr-commits@lucene.apache.org Received: (qmail 94818 invoked by uid 99); 1 Nov 2008 04:50:23 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 31 Oct 2008 21:50:23 -0700 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 01 Nov 2008 04:49:16 +0000 Received: by eris.apache.org (Postfix, from userid 65534) id 0DFA0238889E; Fri, 31 Oct 2008 21:49:57 -0700 (PDT) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r709649 - in /lucene/solr/trunk/contrib/velocity: ./ src/main/java/ src/main/java/org/apache/solr/request/ src/main/solr/conf/velocity/ Date: Sat, 01 Nov 2008 04:49:56 -0000 To: solr-commits@lucene.apache.org From: ehatcher@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20081101044957.0DFA0238889E@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: ehatcher Date: Fri Oct 31 21:49:56 2008 New Revision: 709649 URL: http://svn.apache.org/viewvc?rev=709649&view=rev Log: Wire in a SolrResourceLoader bridge for Velocity templates, allowing a JAR of templates to live in conf/lib. Refactored the footer.vm template to use this mechanism as an example. Added: lucene/solr/trunk/contrib/velocity/src/main/java/footer.vm lucene/solr/trunk/contrib/velocity/src/main/java/org/apache/solr/request/SolrVelocityResourceLoader.java Removed: lucene/solr/trunk/contrib/velocity/src/main/solr/conf/velocity/footer.vm Modified: lucene/solr/trunk/contrib/velocity/build.xml lucene/solr/trunk/contrib/velocity/src/main/java/org/apache/solr/request/SolrParamResourceLoader.java lucene/solr/trunk/contrib/velocity/src/main/java/org/apache/solr/request/VelocityResponseWriter.java lucene/solr/trunk/contrib/velocity/src/main/solr/conf/velocity/browse.vm Modified: lucene/solr/trunk/contrib/velocity/build.xml URL: http://svn.apache.org/viewvc/lucene/solr/trunk/contrib/velocity/build.xml?rev=709649&r1=709648&r2=709649&view=diff ============================================================================== --- lucene/solr/trunk/contrib/velocity/build.xml (original) +++ lucene/solr/trunk/contrib/velocity/build.xml Fri Oct 31 21:49:56 2008 @@ -61,7 +61,9 @@ + manifest="${common.dir}/${dest}/META-INF/MANIFEST.MF"> + + Added: lucene/solr/trunk/contrib/velocity/src/main/java/footer.vm URL: http://svn.apache.org/viewvc/lucene/solr/trunk/contrib/velocity/src/main/java/footer.vm?rev=709649&view=auto ============================================================================== --- lucene/solr/trunk/contrib/velocity/src/main/java/footer.vm (added) +++ lucene/solr/trunk/contrib/velocity/src/main/java/footer.vm Fri Oct 31 21:49:56 2008 @@ -0,0 +1,9 @@ +#if($params.getBool("debugQuery",false)) +
+  request = $request
+
+  response = $response.values
+
+#end + +Generated by VelocityResponseWriter \ No newline at end of file Modified: lucene/solr/trunk/contrib/velocity/src/main/java/org/apache/solr/request/SolrParamResourceLoader.java URL: http://svn.apache.org/viewvc/lucene/solr/trunk/contrib/velocity/src/main/java/org/apache/solr/request/SolrParamResourceLoader.java?rev=709649&r1=709648&r2=709649&view=diff ============================================================================== --- lucene/solr/trunk/contrib/velocity/src/main/java/org/apache/solr/request/SolrParamResourceLoader.java (original) +++ lucene/solr/trunk/contrib/velocity/src/main/java/org/apache/solr/request/SolrParamResourceLoader.java Fri Oct 31 21:49:56 2008 @@ -30,6 +30,7 @@ public class SolrParamResourceLoader extends ResourceLoader { private HashMap templates = new HashMap(); public SolrParamResourceLoader(SolrQueryRequest request) { + super(); // TODO: Consider using content streams, but need a template name associated with each stream // for now, a custom param convention of template.=