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

Aaron McCurry commented on BLUR-49:
-----------------------------------

Yes I think we can move forward.

In the Thrift definition file (now found 
src/distribution/src/main/scripts/interface/Blur.thrift) we should modify the 
ClassDefinition struct to look something like:

struct ClassDefinition {
 1:string className,
 2:map<string,string> arguments,
 3:string initFunction
}

NOTE: To regenerate the Thrift RPC code run the genAndReplace.sh script.

The initFunction would where we would pass in the javascript function.  Maybe 
an example initFunction would like something like:

function initAnalyzer(arguments) {
  return new 
org.apache.lucene.analysis.standard.StandardAnalyzer(org.apache.lucene.util.Version.LUCENE_40);
}

This function would create a standard analyzer and the arguments in the case 
aren't used.

That do you think?
                
> BlurAnalyzer add constructor arguments
> --------------------------------------
>
>                 Key: BLUR-49
>                 URL: https://issues.apache.org/jira/browse/BLUR-49
>             Project: Apache Blur
>          Issue Type: Bug
>    Affects Versions: 0.2.0
>            Reporter: Aaron McCurry
>             Fix For: 0.2.0
>
>
> In the 0.2-dev branch, the BlurAnalyzer should be enhanced to allow 
> constructor arguments to be passed in the ClassDefinition.arguments map.  Not 
> sure what the best way to implement this, but the use case would be creating 
> a StandardAnalyzer with a non-default set of stop words.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to