Problem
According to #1432912: Move Acquia search module to contrib? issue and Commons make file history:
- Before 6.x-2.7 Commons used http://network.acquia.com/files/downloads/acquia-search-current.tar.gz which contained http://drupal.org/project/apachesolr module and other relevant stuff that need to be downloaded manually otherwise.
- Then Commons switched to http://drupal.org/project/acquia_search but that module doesn't contain http://drupal.org/project/apachesolr.
Proposed resolution
Include http://drupal.org/project/apachesolr module in Commons make file.
Is it possible to also download automagically that extra stuff e.g. SolrPhpClient? :/
Original report by Andrea C
In Commons until version 6.x-2.6 was available the module "Apache Solr framework".
It was located in
profiles/drupal_commons/modules/acquia/acquia_search/apachesolr
Thanks to this module and to a local installation of the Apache Solr search engine we could have very usefull faceted search (see attached image), without the need of an Acquia Network subscription (our security policy doesn't allow to send data outside the company)
We upgrade Commons to 6.x-2.7, using the full package form https://network.acquia.com/downloads/drupal-commons but
the "Apache Solr framework" module has now been removed.
We restored the module form the backup and we put it in sites/all/modules so we can still use it but we think this module deserve to be part of the Commons distribution.
We all want to improve Commons so why this important feature has been removed?
Do we get the same results (faceted search) in other better ways?
Thanks
Comment | File | Size | Author |
---|---|---|---|
#16 | commons-include-SolrPhpClient-1629860-16.patch | 2.2 KB | mariomaric |
#9 | 1629860-commons-apachesolr.patch | 543 bytes | ezra-g |
Apache Solr faceted search in Commons (JPG) | 111 KB | Andrea C |
Comments
Comment #1
lightsurge CreditAttribution: lightsurge commentedThe acquia search module has been posted on drupal.org
http://drupal.org/project/acquia_search
But it actually sounds like you'd be as well using
http://drupal.org/project/apachesolr
If its been removed I'm not sure why, might be a mistake, I know it was moved to drupal.org to facilitate packaging it into Commons on drupal.org #1432912: Move Acquia search module to contrib? so doesn't seem like it would be intentionally removed.
Comment #2
mariomaric CreditAttribution: mariomaric commentedRelated issue: #1432912: Move Acquia search module to contrib?
Hm, as far as I can see from the Commons make file and according to above mentioned issue:
1) Before 6.x-2.7 Commons used http://network.acquia.com/files/downloads/acquia-search-current.tar.gz which obviously contained http://drupal.org/project/apachesolr module.
2) They switched to http://drupal.org/project/acquia_search but that module doesn't contain http://drupal.org/project/apachesolr
@lighsurge: You are really fast! :P
Comment #3
lightsurge CreditAttribution: lightsurge commentedAhh that makes sense. Fast, but not as on target ;)
Comment #4
mariomaric CreditAttribution: mariomaric commentedSo, the workouraund is to install http://drupal.org/project/apachesolr manually - or just like you did - restore from backup i.e. Commons 6.x-2.6.
I changed issue title to represent more precisely what is going on. ;)
Comment #5
Andrea C CreditAttribution: Andrea C commentedYou are really fast!
May be there is a reason: in commons the faceted search has been thought as provided by Acquia Search, an hosted web service from Acquia. It seems the Apache Solr Framework was included as a component of Acquia Search, not to be used alone.
But this is what I did:
This post is also related to http://groups.drupal.org/node/236508
It's talking about how to better find information in Commons...
From one side we need to better classify content in Commons through Taxonomy and, very important, Folksonomy (that for me seem missing in Commons);
on the other side how to easily find what we are looking for thanks to Apache Solr
Comment #6
mariomaric CreditAttribution: mariomaric commentedIMHO this is definitely bug, so I changed category and updated issue summary.
Comment #7
ezra-g CreditAttribution: ezra-g commentedAgreed - This was a regression not detected when we switched to the Drupal.org copy of Acquia search. I apologize for any inconvenience and will make sure this is fixed for the 2.8 Commons release.
Luckily, in the meantime the mitigation is quite simple: Download the ApacheSolr module.
Thanks for pointing this out.
Comment #8
ezra-g CreditAttribution: ezra-g commentedIt would be great to get some testing on a 6.x-2.6=>6.x-2.8 upgrade that verifies that there are no errors as a result of moving apachesolr* modules to /contrib instead of the /acquia directory.
Comment #9
ezra-g CreditAttribution: ezra-g commentedComment #10
ezra-g CreditAttribution: ezra-g commentedIn Commons 2.6 and below:
select filename from system where name = 'apachesolr_search';
+------------------------------------------------------------------------------------------+
| filename |
+------------------------------------------------------------------------------------------+
| profiles/drupal_commons/modules/acquia/acquia_search/apachesolr/apachesolr_search.module |
+------------------------------------------------------------------------------------------+
We need to either change the path where apachesolr_search lives via Drush make or an update to the system table.
Comment #11
ezra-g CreditAttribution: ezra-g commentedI verified that this change to the Drush make file places the latest Apachesolr module in the same location as Commons 2.6 and below: profiles/drupal_commons/modules/acquia/acquia_search/apachesolr/apachesolr_search.module.
http://drupalcode.org/project/commons.git/commitdiff/154a76d?hp=183d033f...
Comment #12
ezra-g CreditAttribution: ezra-g commentedGetting the files in place wasn't sufficient here.
On a test build I got the following after enabling Acquia_Search module and its Apachesolr dependencies.
Fatal error: Call to undefined function apachesolr_has_searched() in /Users/ezra/Developer/htdocs/dev/acquia/commons_nightly_dev_7-5-1/profiles/drupal_commons/modules/acquia/acquia_search/apachesolr/apachesolr_search.module on line 573
Comment #13
ezra-g CreditAttribution: ezra-g commentedI was able to resolve that problem by ensuring we grab the latest from the 1.x branch of apchesolr_search that does not contain an apachesolr_search.make.
http://drupalcode.org/project/commons.git/blobdiff/3811651d363802e0bcee1...
Comment #14
Andrea C CreditAttribution: Andrea C commentedAfter updating from Commons 6.x-2.7 to 6.x-2.9 (jump over 2.8), using the full package from Acquia, I found apachesolr module back in profiles/drupal_commons/modules/acquia/acquia_search/apachesolr but inside this folder two libraries where missing (compared to same module in 6.x-2.6) :
- SolrPhpClient (reported as missing also by admin/reports/status )
- Zend
I recover both from the backup
Comment #15
mariomaric CreditAttribution: mariomaric commentedHi Andrea!
As stated in README.txt you need to manually download those libraries...
BUT, we could also use d.o make file and include Solr PHP client - it is included in Drupal.org Library Packaging Whitelist.
I will try to fix it this weekend, in meantime, workaround is to download it manually.
Comment #16
mariomaric CreditAttribution: mariomaric commented@ezra-g regarding #13: in Drush command to get PHP client can't run issue apachesolr.make was renamed to apachesolr.make.example - this is why 6.x-1.x version is working - it's related with some Drush make recursion bug, although it supposed to be fixed...
Regarding additional libraries that apachesolr module require, I included SolrPHPClient in drupal_commons.make file (mostly c/p from apachesolr.make.example file).
Zend library is only needed for PHP < 5.2.0 (more than 6 years old and unsupported version of PHP) and it's not whitelisted in Drupal.org Library Packaging Whitelist - so I suppose we don't need to include it (although it is included in http://network.acquia.com/files/downloads/acquia-search-current.tar.gz which Commons used before 6.x-2.7).
I also fixed download type method for other libraries in drupal_commons.make file - Drush Make docs don't mention "get", only "file" method.
Patch attached.
Comment #17
ezra-g CreditAttribution: ezra-g commentedComment #17.0
ezra-g CreditAttribution: ezra-g commentedUpdate -- m.m