lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Liz Sommers <lizswo...@gmail.com>
Subject Re: Having problems with the java api in 1.4.0
Date Tue, 24 Aug 2010 16:33:15 GMT
We do have synonyms.txt in our config directory.  The config directory is a
copy of the example directory.  We will probably also run into this problem
with stopwords.xml.

We don't understand how to make it look in the correct directory.  We
thought it got the correct directory out of the solrconfig variable (cfg).

Thanks

Liz Sommers
lizsworks@gmail.com

2010/8/24 Rafał Kuć <rafal@alud.com.pl>

> Hello!
>
>   The exception thrown by Solr says that You do not have synonyms.txt
> file either in classpath or in solr core config directory. Check Your
> schema.xml file for a filter - SynonymFilterFactory. That filter use
> synonyms.txt file to read synonyms definitions. If You don`t need
> synonyms filter, just delete that filter from type (or types) definition.
> If You
> need that filter - add synonyms.txt file to Your config directory.
>
> --
> Regards,
>  Rafał Kuć (gro@solr.pl)
>
> > I am very new to the solr/lucene world.  I am using solr 1.4.0 and cannot
> > move to 1.4.1.
>
> > I have to index about 50 fields for each document, these fields are
> already
> > in key/value pairs by the time I get to my index methods.  I was able to
> > index them with lucene without any problem, but found that I could not
> then
> > read the indexes with solr/admin.  So, I decided to use Solr for my
> > indexing.
>
> > The error I am currently getting is
> > java.lang.RuntimeException: Can't find resource 'synonyms.txt' in
> classpath
> > or 'solr/conf'/'
>
> > This exception is being thrown by
> > SolrResourceLoader.openResource(line 260).
> > which is called by IndexSchema<init> (line 102)
>
> > My code that leads up to this follows:
>
> > <code>
> > String path = "c:/swdev/apache-solr-1.4.0/IDW"
> > SolrConfig cfg new SolrConfig(path + "/solr/conf/solrconfig.xml");
> > schema = new IndexSchema(cfg,path + "/solr/conf/schema.xml",null);
>
> > </code>
>
> > This also fails if I use
> > schema = new IndexSchema(cfg,"schema.xml",null);
>
>
> > Any help would be greatly appreciated.
>
> > Thank you
>
> > Liz Sommers
> > lizsworks@gmail.com
>
>
>
> --
> Regards,
>  Rafał Kuć
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message