[ https://issues.apache.org/jira/browse/OAK-3576?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14988378#comment-14988378 ]
Vikas Saurabh commented on OAK-3576: ------------------------------------ [~jsedding], thanks for the comments. The reason I went for simplistic index augment behavior was that it seemed that an ootb should remain unimpeded. I like the idea of passing the current set of prepared fields but I think it's better (more definitive) that augmentation can't meddle with the ootb field list i.e. I still think that custom code shouldn't meddle with ootb fields... sure, we can have lots of logging if input and output field list from custom code is different... but that I think would bring us more pain than benefit. I was sort-of undecided on passing index definition - {{IndexDefinition}} isn't an exposed interface, so we'd need to work with it's {{NodeState}} instead... which can be fine but then the custom code would start to depend really deeply into how we manage the index definition content structure... that bit seemed 'too much work' to me. About having an explicit marker in index definition for inclusion of custom indexing - I think having custom indexing should be the last resort or iow ootb declarative definition should fit almost all the cases... so, I think pinging all custom code to know if it's interested feels too intrusive. Over all, from feature point of view, I was targeting for some hooks such that some control can be given to custom augmenters but still not make it so general that it starts to become a API maintenance and debugging nightmare. > Allow custom extension to augment indexed lucene documents > ---------------------------------------------------------- > > Key: OAK-3576 > URL: https://issues.apache.org/jira/browse/OAK-3576 > Project: Jackrabbit Oak > Issue Type: Improvement > Components: lucene > Reporter: Vikas Saurabh > Attachments: OAK-3576.wip.patch > > > Following up on http://oak.markmail.org/thread/a53ahsgb3bowtwyq, we should > have an extension point in oak to allow custom code to add fields to > documents getting indexed in lucene. We'd also need to allow extension point > to add extra query terms to utilize such augmented fields. > (cc [~teofili], [~chetanm]) -- This message was sent by Atlassian JIRA (v6.3.4#6332)