[ 
https://issues.apache.org/jira/browse/SOLR-12697?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16708618#comment-16708618
 ] 

Stanislav Livotov edited comment on SOLR-12697 at 12/4/18 1:33 PM:
-------------------------------------------------------------------

Hi all, 

I've created a new patch where I had migrated the FieldValueFeature on using 
SolrDocumentFetcher#solrDoc introduced in patch SOLR-12625. [~erickerickson] 
can you please take a look at it?

I had also done a couple of additional code changes:
 # fixed small issue with defaultValue(previously it was impossible to set it 
from feature.json, and the tests were written where Feature were created 
manually, and not by parsing json). Tests are added which are validating 
defaultValue from schema field configuration and from a feature default value. 
 # added functionality of parsing numbers persisted as StrFields(tests added). 
Please note that I first try to check that it is boolean String(T/F) in order 
to support the previous behavior. Please note that there is a difference in 
behavior - previously in case if we were getting some not supported field we 
were silently returning defaultValue. Now FeatureException is thrown. 

As we had migrated code on using SolrDocumentFetcher to retrieve fieldValues, 
it is now impossible to test FieldValueFeature with LuceneTestCase, so I had to 
migrate test TestLTRReRankingPipeline on SolrTestCaseJ4(I tried to do minimum 
changes there)

[~cpoerschke] please take a look at the patch and described changes. WDYT?


was (Author: slivotov):
Hi all, 

I've created a new patch where I had migrated the FieldValueFeature on using 
SolrDocumentFetcher#solrDoc introduced in patch SOLR-12625. [~erickerickson] 
can you please take a look at it?

I had also done a couple of additional code changes:
 # fixed small issue with defaultValue(previously it was impossible to set it 
from feature.json, and the tests were written where Feature were created 
manually, and not by parsing json). Tests are added which are validating 
defaultValue from schema field configuration and from a feature default value. 
 # added functionality of parsing numbers persisted as StrFields(tests added). 
Please note that I first try to check that it is boolean String(T/F) in order 
to support the previous behavior. Please note that there is a difference in 
behavior - previously in case if we were getting some not supported field we 
were silently returning defaultValue. Now FeatureException is thrown. 

Please also note that as we had migrated code on using SolrDocumentFetcher to 
retrieve fieldValues, it is now impossible to test FieldValueFeature with 
LuceneTestCase, so I had to migrate test TestLTRReRankingPipeline on 
SolrTestCaseJ4(I tried to do minimum changes there)

[~cpoerschke] please take a look at the patch and described changes. WDYT?

> pure DocValues support for FieldValueFeature
> --------------------------------------------
>
>                 Key: SOLR-12697
>                 URL: https://issues.apache.org/jira/browse/SOLR-12697
>             Project: Solr
>          Issue Type: Sub-task
>      Security Level: Public(Default Security Level. Issues are Public) 
>          Components: contrib - LTR
>            Reporter: Stanislav Livotov
>            Priority: Major
>         Attachments: SOLR-12697.patch, SOLR-12697.patch
>
>
> [~slivotov] wrote in SOLR-12688:
> bq. ... FieldValueFeature doesn't support pure DocValues fields (Stored 
> false). Please also note that for fields which are both stored and DocValues 
> it is working not optimal because it is extracting just one field from the 
> stored document. DocValues are obviously faster for such usecases. ...
> (Please see SOLR-12688 description for overall context and analysis results.)



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to