Hi

Before I ask - I'm Not asking about the multisite functionality of Solr (searching content across sites from a single site) - I've read many issues saying that it's not supported..

I have installed Solr search on one site of many in a single installation. It seems to be working well (haven't dug into the file content searching, but the rest of the pieces work at the moment)

If I enable Solr on a 2nd site, do "things go bad"? Is my only work-around to run separate instances of the Solr per site?

Thanks..

CommentFileSizeAuthor
#3 Picture 1.png102.57 KBbrianjhoffman

Comments

robertdouglass’s picture

Hi timatlee,

Everything depends on your index. You have the chance in the Solr configuration to specify the URL for your indexer, and this can be thought of as being similar to the database connection details that you enter while setting up a Drupal site. If you have separate indexes for each of your Drupal sites, they will always remain separate and never cause each other problems. Solr is capable of having separate indexes in one installation, so there is theoretically no problem with you running many separate Drupal sites off of one Solr server.

The ApacheSolr multisite functionality is not supported in that the engineers being paid by Acquia to work on ApacheSolr don't yet have the mandate to make this part of the product offering. It does (or at least did) work, however, and it may be worth a try if you're in need of it. This is the case where multiple Drupal sites share the same Solr index, and the originating site is stored as a part of each document. This allows you to search filtered by site, or search across multiple sites.

robertdouglass’s picture

Status: Active » Fixed

If you have more questions feel free to re-open the issue.

brianjhoffman’s picture

Category: support » feature
Status: Fixed » Active
StatusFileSize
new102.57 KB

Hi,

I hope you don't mind my re-opening this issue. I'm not sure if it's the right protocol.

I have a question / suggestion about enabling cross site searches. Why not make a small adjustment to the apachesolr_search.module such that lines 129-132 (hook for modules to alter the query) are moved below lines 137-138 (fixes the query on the given site). It seems to me like this would give implementers the freedom to easily code their own multisite modules.

Also, the hook call appears to be repeated twice.

Thanks,

Brian

pwolanin’s picture

Version: 6.x-1.0-beta7 » 6.x-1.x-dev

I'm not sure what version of the code you are looking at that you'd see that duplication.

There is also no code to fix the query to a specific site.

Please check out the DRUPAL-6--1 branch from CVS, or download the latest release.

brianjhoffman’s picture

Status: Active » Closed (fixed)

Hi,

I didn't realize how much the development branch differed from the Releases. I was looking at the last non development releases for both 5 and 6, both of which have a line after the hook for query modification and before the query is passed of to solr. The line adds a hash parameter to the query, which basically didn't allow any extensions to opt out of single-site searching. I think it's a moot point now as I see that the logic is not the same in the current development branch.

Thanks,

Brian

ddorian’s picture

Title: Drupal Multi-site and Solr » Does solr search works on multilingual sites?
Version: 6.x-1.x-dev » 6.x-2.x-dev
Component: Multisite » Language
Category: feature » support
Status: Closed (fixed) » Active

just like core.search works:
if im in english and i search only english stuff(nodes) appear

if im in dutch only dutch nodes appear
thank you

jpmckinney’s picture

Title: Does solr search works on multilingual sites? » Drupal Multi-site and Solr
Version: 6.x-2.x-dev » 6.x-1.x-dev
Component: Language » Multisite
Category: support » feature
Status: Active » Closed (fixed)

@ddorlan: Why did you change this issue instead of creating a new one? See #394728: By default filter by the user's language and provide setting on settings page. for what you want.

ddorian’s picture

honestly i dont remember must have been drunk :(
im very sorry