Re: Analytics Component not working Solr-5.0

2015-02-12 Thread sumitj25
Can somebody help, has anyone used analytics component here?



--
View this message in context: 
http://lucene.472066.n3.nabble.com/Analytics-Component-not-working-Solr-5-0-tp4185666p4185977.html
Sent from the Solr - User mailing list archive at Nabble.com.


Re: Analytics Component not working Solr-5.0

2015-02-11 Thread sumitj25
I have put the jar in contrib/extraction/lib/ and now I can see it is getting
loaded

INFO  - 2015-02-11 13:36:35.484; org.apache.solr.core.SolrResourceLoader;
Adding
'file:/home/sumit/workspaces/github/lucene-solr/solr/contrib/extraction/lib/solr-analytics-5.0.0-SNAPSHOT.jar'
to classloader

But, still the query is not working. Is any additional configuration
required in solrConfig.xml? If not, why doesn't it work?



--
View this message in context: 
http://lucene.472066.n3.nabble.com/Analytics-Component-not-working-Solr-5-0-tp4185666p4185875.html
Sent from the Solr - User mailing list archive at Nabble.com.


Re: Analytics Component not working Solr-5.0

2015-02-11 Thread Shawn Heisey
On 2/11/2015 6:20 AM, sumitj25 wrote:
> I have compiled analytics component using 'ant clean dist' in
> contrib/analytics/, which puts the jar in
> dist/solr-analytics-5.0.0-SNAPSHOT.jar. I have also copied this jar to
> server/solr-we solr.log
>  
> bapp/webapp/WEB-INF/lib/solr-analytics-5.0.0-SNAPSHOT.jar. But I am not
> getting anything in the logs as well as the response. Can the startup logs
> tell if the component is loaded?
> 
> solr.log   

Yes, if the jar is being loaded, you will usually see a log entry if the
log if your detail is at least INFO.  An excerpt from my log:

INFO  - 2015-02-06 16:09:00.685;
org.apache.solr.core.SolrResourceLoader; using system property
solr.solr.home: /index/solr4
INFO  - 2015-02-06 16:09:00.686;
org.apache.solr.core.SolrResourceLoader; new SolrResourceLoader for
directory: '/index/solr4/'
INFO  - 2015-02-06 16:09:00.687;
org.apache.solr.core.SolrResourceLoader; Adding
'file:/index/solr4/lib/solrupdate.jar' to classloader
INFO  - 2015-02-06 16:09:00.687;
org.apache.solr.core.SolrResourceLoader; Adding
'file:/index/solr4/lib/mysql-connector-java-5.1.33-bin.jar' to classloader
INFO  - 2015-02-06 16:09:00.687;
org.apache.solr.core.SolrResourceLoader; Adding
'file:/index/solr4/lib/icu4j-53.1.jar' to classloader
INFO  - 2015-02-06 16:09:00.688;
org.apache.solr.core.SolrResourceLoader; Adding
'file:/index/solr4/lib/pixolutionForApacheSolr4.9.0_v1.6.2.jar' to
classloader
INFO  - 2015-02-06 16:09:00.688;
org.apache.solr.core.SolrResourceLoader; Adding
'file:/index/solr4/lib/lucene-analyzers-icu-4.9.1.jar' to classloader
INFO  - 2015-02-06 16:09:00.688;
org.apache.solr.core.SolrResourceLoader; Adding
'file:/index/solr4/lib/solr-dataimporthandler-4.9.1.jar' to classloader
INFO  - 2015-02-06 16:09:00.689;
org.apache.solr.core.SolrResourceLoader; Adding
'file:/index/solr4/lib/CJKFoldingFilter.jar' to classloader

By far the easiest way to handle extra jars in Solr is to create a "lib"
directory inside your solr home and put all extra jars for Solr there.
No  directives are needed in solrconfig.xml, and in 4.3 and later,
that directory will be automatically searched with zero config.  The
jars will only be loaded once and will be available to all cores.  If
you use  directives, the jars will be loaded again for every core,
even if they have already been loaded.

It's not a good idea in most cases to mess with WEB-INF, unless you are
unpacking the war, adding jars, and then repacking it.  If you use this
method, then you will not see a loading message for those jars.

Thanks,
Shawn



Re: Analytics Component not working Solr-5.0

2015-02-11 Thread sumitj25
I get normal docs response without any olap part 

{
  "responseHeader":{
"status":0,
"QTime":1,
"params":{
  "o.req1.s.stat1":"sum(int(salesCompleted))",
  "indent":"true",
  "q":"*:*",
  "olap":"true",
  "wt":"json"}},
  "response":{"numFound":57,"start":0,"docs":[
  {
"salesCompleted":3280814,
"salesReturned":30331,
"date":"2015-02-04T18:30:00Z"},
  {
"salesCompleted":2258319,
"salesReturned":18252,
"date":"2015-02-04T18:30:00Z"} .}

I have compiled analytics component using 'ant clean dist' in
contrib/analytics/, which puts the jar in
dist/solr-analytics-5.0.0-SNAPSHOT.jar. I have also copied this jar to
server/solr-we solr.log
 
bapp/webapp/WEB-INF/lib/solr-analytics-5.0.0-SNAPSHOT.jar. But I am not
getting anything in the logs as well as the response. Can the startup logs
tell if the component is loaded?

solr.log   





--
View this message in context: 
http://lucene.472066.n3.nabble.com/Analytics-Component-not-working-Solr-5-0-tp4185666p4185683.html
Sent from the Solr - User mailing list archive at Nabble.com.


Re: Analytics Component not working Solr-5.0

2015-02-11 Thread Erick Erickson
What do you get as a response? The analytics component
was moved to a contrib in 5.x so you have to path to it, but
your Solr logs should be showing you that.

Best,
Erick

On Wed, Feb 11, 2015 at 7:24 AM, sumitj25  wrote:
> I have checked out solr git repo, and built 5.0. I am trying to use the
> Analytics Component, but not getting anything in the response
>
> q=*%3A*&wt=json&indent=true&olap=true&o.req1.s.stat1=sum(int(sales))
>
> Why is it not working? Is any additional configuration required?
>
>
>
>
>
> --
> View this message in context: 
> http://lucene.472066.n3.nabble.com/Analytics-Component-not-working-Solr-5-0-tp4185666.html
> Sent from the Solr - User mailing list archive at Nabble.com.


Analytics Component not working Solr-5.0

2015-02-11 Thread sumitj25
I have checked out solr git repo, and built 5.0. I am trying to use the
Analytics Component, but not getting anything in the response

q=*%3A*&wt=json&indent=true&olap=true&o.req1.s.stat1=sum(int(sales))

Why is it not working? Is any additional configuration required?

 



--
View this message in context: 
http://lucene.472066.n3.nabble.com/Analytics-Component-not-working-Solr-5-0-tp4185666.html
Sent from the Solr - User mailing list archive at Nabble.com.