Hi Scott,
I have everything well configured but no parameters can be passed to an
Analyzer (FieldTypePluginLoader just calls the constructor without
parameters).
So, the quick solution is to create a TokenizerFactory instead.

Thanks,
Roxana



On 2 February 2016 at 16:29, Scott Stults <sstu...@opensourceconnections.com
> wrote:

> There are a lot of things that can go wrong when you're wiring up a custom
> analyzer. I'd first check the simple things:
>
> * Custom jar is in Solr's classpath
> * Not using the custom factory in a field type's analysis chain
> * Not declaring a field with that type
> * Not using that field in a document
> * Assuming the tokenizer/filter will be instantiated directly rather than
> through the factory interfaces.
>
> Hope that helps!
>
> k/r,
> Scott
>
>
> On Tue, Feb 2, 2016 at 3:04 AM, Roxana Danger <
> roxana.dan...@reedonline.co.uk> wrote:
>
> > Hello,
> > I would like to use some code embedded on an analyser. The problem is
> that
> > I need to pass some parameters for initializing it. My though was to
> create
> > a plugin and initialize the parameters with the init( Map<String,String>
> > args ) or init( NamedList args ) methods as explained in
> > http://wiki.apache.org/solr/SolrPlugins.
> > But none of these methods are called when the schema is read and the
> > analyser constructed. I have also tried implementing the
> > ResourceLoaderAware interface, but the inform() method is not called
> > either.
> > I am missing something to have my analyser running? When these init
> methods
> > are and how can I trigger their call? Any suggestion that does not imply
> to
> > divide the code on Tokenizer/Filters?
> >
> > Thank you very much in advance,
> > Roxana
> >
>
>
>
> --
> Scott Stults | Founder & Solutions Architect | OpenSource Connections, LLC
> | 434.409.2780
> http://www.opensourceconnections.com
>



-- 
Roxana Danger | Data Scientist
Dragon Court, 27-29 Macklin Street, London, WC2B 5LX
Tel: 020 7067 4568
[image: reed.co.uk] <http://www.reed.co.uk/>
The UK's #1 job site. <http://www.reed.co.uk/>
[image: Follow us on Twitter] <https://twitter.com/reedcouk>
<https://www.linkedin.com/company/reed.co.uk> [image: Like us on Facebook]
<https://www.facebook.com/reedcouk/>
<https://plus.google.com/u/0/+reedcouk/posts>
It's time to Love Mondays ยป <http://www.reed.co.uk/lovemondays>

Reply via email to