You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Shawn Heisey <so...@elyograg.org> on 2013/03/13 15:09:02 UTC

Reusing same searcher in Solr?

I was reading Mike McCandless' blog and came across this post:

http://blog.mikemccandless.com/2011/11/searcherlifetimemanager-prevents-broken.html

Is this kind of functionality available in Solr?  I update my index once 
a minute, so being able to reuse an old searcher for a little while 
would be very interesting.  I do get a little worried about memory usage.

Thanks,
Shawn

Re: Reusing same searcher in Solr?

Posted by Mark Miller <ma...@gmail.com>.
I think there is a JIRA issue for Searcher leases somewhere. If not, it's something we have talked a lot about. It's useful for a variety of reasons.

I'm sure it's in the pipeline, though I don't know where.

- Mark

On Mar 13, 2013, at 10:09 AM, Shawn Heisey <so...@elyograg.org> wrote:

> I was reading Mike McCandless' blog and came across this post:
> 
> http://blog.mikemccandless.com/2011/11/searcherlifetimemanager-prevents-broken.html
> 
> Is this kind of functionality available in Solr?  I update my index once a minute, so being able to reuse an old searcher for a little while would be very interesting.  I do get a little worried about memory usage.
> 
> Thanks,
> Shawn


Re: velocity in /srv/www

Posted by Shawn Heisey <el...@elyograg.org>.
On 3/13/2013 8:39 AM, Guy Dobson wrote:
> Is there a way to put the Velocity pages in /srv/www alongside of /htdocs and /cgi-bin
> and tell it to look in /opt/solr-4.1.0/... to find my Solr index
> so that we don't have to open port 8983 on the firewall

When starting a new thread on a mailing list, please don't reply to an 
existing message.  There are message headers that place your message in 
the same thread as the message you replied to, hiding it from people who 
might otherwise reply.  This is a particularly bad problem for people 
who read one of the many forum-style websites that track the mailing list.

The velocity templates that come with Solr (the /browse handler) require 
that the user's browser contact Solr directly.  Solr has no security, so 
any user that can contact Solr directly can see how your index is 
structured, update your index with invalid data, delete your index, or 
send denial of service queries.  By putting a proxy front end in front 
of it, you can make that less of a problem, but it is *strongly* 
recommended that you do not make Solr directly available to the end user 
at all.

Because of this, the /browse handler in Solr was never intended for 
production use.  It is a prototyping tool that shows off what Solr can 
do.  You will need to either find an existing front-end for Solr or use 
one of the fine Solr programming APIs (available in multiple languages) 
to write one yourself.

Thanks,
Shawn


Re: velocity in /srv/www

Posted by Erik Hatcher <er...@gmail.com>.
Not using Solr's VelocityResponseWriter.   It literally is a Solr response writer :)  And thus to use it you have to make standard search requests to Solr.

You can move the Velocity templates to another location, as there is a way to specify the root directory for templates, but they only get rendered from standard search requests (by default to port 8983).

	Erik

On Mar 13, 2013, at 10:39 , Guy Dobson wrote:

> Fellow Solrites,
> 
> Is there a way to put the Velocity pages in /srv/www alongside of /htdocs and /cgi-bin 
> and tell it to look in /opt/solr-4.1.0/... to find my Solr index
> so that we don't have to open port 8983 on the firewall
> ?
> 
> Thanks,
> Guy
> 
> 
> Guy Dobson
> Integrated Systems Librarian
> Drew University Library
> http://users.drew.edu/gdobson
> 973-408-3207 


Re: velocity in /srv/www

Posted by Paul Libbrecht <pa...@hoplahup.net>.
Guy,

you'd need a proxy to go from one port (80 for the apache) to port 8983. Apache httpd will not run solr alone.
Then the question of where you put the velocity page is "just a matter of configuration".
A symbolic link probably.

paul


On 13 mars 2013, at 15:39, Guy Dobson wrote:

> Fellow Solrites,
> 
> Is there a way to put the Velocity pages in /srv/www alongside of /htdocs and /cgi-bin 
> and tell it to look in /opt/solr-4.1.0/... to find my Solr index
> so that we don't have to open port 8983 on the firewall
> ?
> 
> Thanks,
> Guy
> 
> 
> Guy Dobson
> Integrated Systems Librarian
> Drew University Library
> http://users.drew.edu/gdobson
> 973-408-3207 


velocity in /srv/www

Posted by Guy Dobson <gd...@drew.edu>.
Fellow Solrites,
 
Is there a way to put the Velocity pages in /srv/www alongside of /htdocs and /cgi-bin 
and tell it to look in /opt/solr-4.1.0/... to find my Solr index
so that we don't have to open port 8983 on the firewall
?
 
Thanks,
Guy
 
 
Guy Dobson
Integrated Systems Librarian
Drew University Library
http://users.drew.edu/gdobson
973-408-3207