velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sergiu Dumitriu <>
Subject Re: Velocity to fetch full docs?
Date Mon, 26 Sep 2011 15:24:28 GMT
On 09/26/2011 10:56 AM, Nathan Bubna wrote:
> Definitely for a question for the Nutch or Solr lists.  Velocity is a
> simple template engine and knows nothing about Nutch or Solr that it
> isn't "told" about.

Indeed, Velocity is a very simple template engine, with no smart APIs 
provided by the engine alone. What you need to do is to put in the 
context some data objects holding the instance data you're currently 
processing (or even just the servlet request and response objects to get 
access to the request parameters), and some smart objects that can 
contact Solr, Nutch and your other nonSolr services. You'd have to write 
these yourself in Java, and put instances in the velocity context before 

Another approach is to put enough low level services to allow you to 
implement the whole logic inside a Velocity template, like a HTTP 
client, XML processing library, the escape tool, etc.

> On Mon, Sep 26, 2011 at 5:17 AM, Fred Zimmerman<>  wrote:
>> Hi,
>> I am using Nutch/Solr to index an intranet of about 12 million pages and
>> when I do a search I want Solr to retrieve the full documents and append
>> them into a single simple HTML doc (no js, not ads, etc.), then shoot the
>> single doc to another (nonSolr) process for postprocessing.   Can I use
>> Velocity to do this? How?  Can Velocity "reach back" to the Nutch crawl for
>> the full text of the docs (they don't change often at all)?
>> Any help would be much appreciated.

Sergiu Dumitriu

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message