Closed (won't fix)
Project:
Apache Solr Organic Groups Integration
Version:
6.x-2.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
10 Jun 2010 at 13:39 UTC
Updated:
24 Jul 2012 at 12:10 UTC
Jump to comment: Most recent file
Comments
Comment #1
ebeyrent commentedAfter looking at this issue a bit more, I think that the fix should be in the apachesolr_attachments module, because it creates a separate Lucene document for each file it indexes. The attached patch simply adds the appropriate OG key to the document. After I patched the module and re-indexed my files, the problem appeared to be fixed.
Comment #2
ebeyrent commentedComment #3
pwolanin commentedNo. This needs to be handled by the _og module. the attachments module should not know anything about groups.
Comment #4
pwolanin commentedOn approach is to use this hook:
The existing nodeaccess bit is a bit of an ugly hack and I'd rather not extend it.
ideally we should have a more generic hook that can alter documented created from or related to a specific node.
For 6.x-1.x I'm not sure sure a change is in scope - we coudl basiclaly use hook_apachesolr_update_index() if we indicate that modules implementing it may need to check
$document->entityto decide whether to act, and maybe pass$entityas an option third parameter?Comment #5
pwolanin commented#832118: Make hook_apachesolr_update_index() more generic so it can be used e.g. for file attachments, etc
Comment #6
ebeyrent commentedI did think about that, but instead elected to go with a solution consistent with how taxonomy and nodeaccess are handled in the attachments code.
I like your idea about extending the hook though.
Comment #7
jsagotsky commentedebeyrent, we still use your patch at OpenScholar, but had to make some changes to get it to apply to 6.x-1.0-beta1. See attached.
Comment #8
jsagotsky commentedErr, try this attachment. Last one didn't stick.
Comment #9
nick_vh6.x-2.x has become unsupported