callback with active state of node

2014-05-16 Thread ronak kirit
Hello,

We are using solr ver 4.3.1 and running them in solrcloud mode. We would
like to keep some dynamic configs under data directory of every shards
and/or replica of a collection. I would like to know that if nodes in not
in active state (lets say it is in recovery or other stats), and if it
comes back to active state, is there any callback can be registered for
active state? If the component is solrcoreaware, would that component's
inform method called every time, the nodes come back to active state?

Thanks,
Ronak


callback with active state of solr core (solr ver 4.3.1)

2014-05-15 Thread ronak kirit
Hello,

We are using solr ver 4.3.1 and running them in solrcloud mode. We would
like to keep some dynamic configs under data directory of every shards
and/or replica of a collection. I would like to know that if nodes in not
in active state (lets say it is in recovery or other stats), and if it
comes back to active state, is there any callback can be registered for
active state? If the component is solrcoreaware, would that component's
inform method called every time, the nodes come back to active state?

Thanks,
Ronak


QueryElevationComponent always reads config from zookeeper

2014-04-18 Thread ronak kirit
Hello,

I was looking into "QueryElevationComponent" component.

As per the spec (http://wiki.apache.org/solr/QueryElevationComponent), if
config is not found in zookeepr, it should be loaded from data directory.
However, I see the bug. It doesn't seem to be working even in latest 4.7.2
release.

I have checked the latest code and found this:
Map getElevationMap(IndexReader reader, SolrCore
core) throws Exception {
synchronized (elevationCache) {
  Map map = elevationCache.get(null);
  if (map != null) return map;

  map = elevationCache.get(reader);
  if (map == null) {
String f = initArgs.get(CONFIG_FILE);
if (f == null) {
  throw new SolrException(SolrException.ErrorCode.SERVER_ERROR,
  "QueryElevationComponent must specify argument: " +
CONFIG_FILE);
}
log.info("Loading QueryElevation from data dir: " + f);

Config cfg;

ZkController zkController =
core.getCoreDescriptor().getCoreContainer().getZkController();
if (zkController != null) {
  cfg = new Config(core.getResourceLoader(), f, null, null);
} else {
  InputStream is = VersionedFile.getLatestFile(core.getDataDir(),
f);
  cfg = new Config(core.getResourceLoader(), f, new
InputSource(is), null);
}

map = loadElevationMap(cfg);
elevationCache.put(reader, map);
  }
  return map;
}
  }

As per this code, we will never be able to load config from data directory
if zookeepr exists.

Can we fix this issue?

Thanks,
Ronak


Re: Class not found ICUFoldingFilter (SOLR-4852)

2014-04-15 Thread ronak kirit
Hello Shawn,

Thanks for your reply.

Yes, I have defined ${solr.solr.home} explicitly, and all the mentioned
jars present in ${solr.solr.home}/lib. solr.log also shows that those files
are getting added once (grep "icu4" solr.log). I could see the lines in
log,

INFO  - 2014-04-15 15:40:21.448; org.apache.solr.core.SolrResourceLoader;
Adding 'file:/solr/lib/icu4j-49.1.jar' to classloader
INFO  - 2014-04-15 15:40:21.454; org.apache.solr.core.SolrResourceLoader;
Adding 'file:/solr/lib/lucene-analyzers-icu-4.3.1.jar' to classloader
INFO  - 2014-04-15 15:40:21.454; org.apache.solr.core.SolrResourceLoader;
Adding 'file:/solr/lib/lucene-analyzers-morfologik-4.3.1.jar' to
classloader
INFO  - 2014-04-15 15:40:21.455; org.apache.solr.core.SolrResourceLoader;
Adding 'file:/solr/lib/lucene-analyzers-smartcn-4.3.1.jar' to classloader
INFO  - 2014-04-15 15:40:21.455; org.apache.solr.core.SolrResourceLoader;
Adding 'file:/solr/lib/lucene-analyzers-stempel-4.3.1.jar' to classloader
INFO  - 2014-04-15 15:40:21.455; org.apache.solr.core.SolrResourceLoader;
Adding 'file:/solr/lib/lucene-analyzers-uima-4.3.1.jar' to classloader

But, still, I get the same exception ICUFoldingFilter not found. However,
coping those files to WEB-INF/lib, works fine for me.

Thanks,
Ronak


On Fri, Apr 11, 2014 at 3:14 PM, ronak kirit  wrote:

> Hello,
>
> I am facing the same issue discussed at SOLR-4852. I am getting below
> error:
>
> Caused by: java.lang.NoClassDefFoundError: Could not initialize class
> org.apache.lucene.analysis.icu.ICUFoldingFilter
> at
> org.apache.lucene.analysis.icu.ICUFoldingFilterFactory.create(ICUFoldingFilterFactory.java:50)
>   at
> org.apache.solr.analysis.TokenizerChain.createComponents(TokenizerChain.java:67)
>
>
> I am using solr-4.3.1. As discussed at SOLR-4852, I had all the jars at
> (SOLR_HOME)/lib and there is no reference to lib via any of solrconfig.xml
> or schema.xml.
>
> I have also tried with setting "sharedLib=foo", but that also didn't work.
> However, if  I removed all the below files:
>
> icu4j-49.1.jar
>
> lucene-analyzers-morfologik-4.3.1.jar  l
>
> ucene-analyzers-stempel-4.3.1.jar
>
> solr-analysis-extras-4.3.1.jar
>
> lucene-analyzers-icu-4.3.1.jar
>
> lucene-analyzers-smartcn-4.3.1.jar
>
> lucene-analyzers-uima-4.3.1.jar
>
> from $(solrhome)/lib and move to solr-webapp/webapp/WEB-INF/lib things are
> working fine.
>
> Any guess? Any help?
>
> Thanks,
>
> Ronak
>


Re: Class not found ICUFoldingFilter (SOLR-4852)

2014-04-15 Thread Ronak Kirit
Hello Shawn,

Thanks for your reply.

Yes, I have defined ${solr.solr.home} explicitly, and all the mentioned jars
present in ${solr.solr.home}/lib. solr.log also shows that those files are
getting added once (grep "icu4" solr.log). I could see the lines in log,

INFO  - 2014-04-15 15:40:21.448; org.apache.solr.core.SolrResourceLoader;
Adding 'file:/solr/lib/icu4j-49.1.jar' to classloader
INFO  - 2014-04-15 15:40:21.454; org.apache.solr.core.SolrResourceLoader;
Adding 'file:/solr/lib/lucene-analyzers-icu-4.3.1.jar' to classloader
INFO  - 2014-04-15 15:40:21.454; org.apache.solr.core.SolrResourceLoader;
Adding 'file:/solr/lib/lucene-analyzers-morfologik-4.3.1.jar' to classloader
INFO  - 2014-04-15 15:40:21.455; org.apache.solr.core.SolrResourceLoader;
Adding 'file:/solr/lib/lucene-analyzers-smartcn-4.3.1.jar' to classloader
INFO  - 2014-04-15 15:40:21.455; org.apache.solr.core.SolrResourceLoader;
Adding 'file:/solr/lib/lucene-analyzers-stempel-4.3.1.jar' to classloader
INFO  - 2014-04-15 15:40:21.455; org.apache.solr.core.SolrResourceLoader;
Adding 'file:/solr/lib/lucene-analyzers-uima-4.3.1.jar' to classloader

But, still, I get the same exception ICUFoldingFilter not found. However,
coping those files to WEB-INF/lib, works fine for me. 



--
View this message in context: 
http://lucene.472066.n3.nabble.com/Class-not-found-ICUFoldingFilter-SOLR-4852-tp4130612p4131221.html
Sent from the Solr - User mailing list archive at Nabble.com.


Class not found ICUFoldingFilter (SOLR-4852)

2014-04-11 Thread ronak kirit
Hello,

I am facing the same issue discussed at SOLR-4852. I am getting below error:

Caused by: java.lang.NoClassDefFoundError: Could not initialize class
org.apache.lucene.analysis.icu.ICUFoldingFilter
at
org.apache.lucene.analysis.icu.ICUFoldingFilterFactory.create(ICUFoldingFilterFactory.java:50)
  at
org.apache.solr.analysis.TokenizerChain.createComponents(TokenizerChain.java:67)


I am using solr-4.3.1. As discussed at SOLR-4852, I had all the jars at
(SOLR_HOME)/lib and there is no reference to lib via any of solrconfig.xml
or schema.xml.

I have also tried with setting "sharedLib=foo", but that also didn't work.
However, if  I removed all the below files:

icu4j-49.1.jar

lucene-analyzers-morfologik-4.3.1.jar  l

ucene-analyzers-stempel-4.3.1.jar

solr-analysis-extras-4.3.1.jar

lucene-analyzers-icu-4.3.1.jar

lucene-analyzers-smartcn-4.3.1.jar

lucene-analyzers-uima-4.3.1.jar

from $(solrhome)/lib and move to solr-webapp/webapp/WEB-INF/lib things are
working fine.

Any guess? Any help?

Thanks,

Ronak