Re: Problem with indexing chinese characters when using SolrJ

2015-10-19 Thread Zheng Lin Edwin Yeo
quot;literal.title", filename); > > > > Is the URLEncoder doing the encoding from the chinese characters to the > string > > of code like this "%E7%AB%8B%E9".? > > Yes, that's what the URL encoder would do. > > SolrJ will automatically handle URL encod

Re: Problem with indexing chinese characters when using SolrJ

2015-10-19 Thread Shawn Heisey
of code like this "%E7%AB%8B%E9".? Yes, that's what the URL encoder would do. SolrJ will automatically handle URL encoding of parameters. Because it is an API that takes Java code and generates HTTP requests, that's part of its job. If you URL encode it yourself, then SolrJ wil

Re: Problem with indexing chinese characters when using SolrJ

2015-10-18 Thread Zheng Lin Edwin Yeo
:29, Zheng Lin Edwin Yeo wrote: > Hi, > > I'm using the URLEncoder withg "UTF-8" encoding in SolrJ (code is written > in Eclipse) to index the file name to Solr. The code looks like this. > > req.setParam("literal.title", URLEncoder.encode(filename, "U

Problem with indexing chinese characters when using SolrJ

2015-10-18 Thread Zheng Lin Edwin Yeo
Hi, I'm using the URLEncoder withg "UTF-8" encoding in SolrJ (code is written in Eclipse) to index the file name to Solr. The code looks like this. req.setParam("literal.title", URLEncoder.encode(filename, "UTF-8")); However, what is index in Solr is a str

Re: Recursively scan documents for indexing in a folder in SolrJ

2015-10-16 Thread Zheng Lin Edwin Yeo
ot;???". Any idea how to solve this problem? Thank you. Regards, Edwin On 16 October 2015 at 21:16, Duck Geraint (ext) GBJH < geraint.d...@syngenta.com> wrote: > Also, check this link for SolrJ example code (including the recursion): > https://lucidworks.com/blog/2012/02/14/indexi

RE: Recursively scan documents for indexing in a folder in SolrJ

2015-10-16 Thread Duck Geraint (ext) GBJH
Also, check this link for SolrJ example code (including the recursion): https://lucidworks.com/blog/2012/02/14/indexing-with-solrj/ Geraint Geraint Duck Data Scientist Toxicology and Health Sciences Syngenta UK Email: geraint.d...@syngenta.com -Original Message- From: Jan Høydahl

Re: Recursively scan documents for indexing in a folder in SolrJ

2015-10-16 Thread Jan Høydahl
SolrJ does not have any file crawler built in. But you are free to steal code from SimplePostTool.java related to directory traversal, and then index each document found using SolrJ. Note that SimplePostTool.java tries to be smart with what endpoint to post files to, xml, csv and json content

Recursively scan documents for indexing in a folder in SolrJ

2015-10-15 Thread Zheng Lin Edwin Yeo
that are in the folder. Now that I'm moving to production and plans to use SolrJ to do the indexing as it can do more things like robustness checks and retires for indexes that fails. However, I can't seems to find a way to do the same in SolrJ. Is it possible for this to be done in

Re: [SolrJ] Indexing Java Map into Solr

2015-10-09 Thread Erick Erickson
Hmmm, what does the code look like for Java? One of the cardinal sins of indexing with SolrJ is sending docs one at a time rather than as batches of at least 100 (I usually use 1,000). See: https://lucidworks.com/blog/2015/10/05/really-batch-updates-solr-2/ One technique I often use to chase this

[SolrJ] Indexing Java Map into Solr

2015-10-09 Thread Alessandro Benedetti
Hi guys, I was evaluating an Indexer application. This application takes in input a Collection of Objects that are basically Java Maps. This is for covering Solr side a big group of dynamic fields basically and avoid that complexity java side. Let's go to the point, currently the indexing approach

Re: SolrJ CollectionAdminRequest.Reload fails

2015-09-11 Thread Hendrik Haddorp
I created https://issues.apache.org/jira/browse/SOLR-8042 On 11/09/15 23:41, Anshum Gupta wrote: > This certainly can be fixed. Can you create a JIRA for the same? There > might be other calls which might need fixing on similar lines. > > On Fri, Sep 11, 2015 at 2:32 PM, Shawn Heisey wrote: > >>

Re: SolrJ CollectionAdminRequest.Reload fails

2015-09-11 Thread Anshum Gupta
This certainly can be fixed. Can you create a JIRA for the same? There might be other calls which might need fixing on similar lines. On Fri, Sep 11, 2015 at 2:32 PM, Shawn Heisey wrote: > On 9/11/2015 3:12 PM, Hendrik Haddorp wrote: > > I'm using Solr 5.3.0 and noticed that the following code d

Re: SolrJ CollectionAdminRequest.Reload fails

2015-09-11 Thread Hendrik Haddorp
the full stack is: [9/11/15 23:36:17:406 CEST] 0216 SystemErr R Caused by: org.apache.solr.client.solrj.impl.HttpSolrClient$RemoteSolrException: Error from server at http://xxx.xxx.xxx.xxx:10001/solr: Missing required parameter: name [9/11/15 23:36:17:406 CEST] 0216 SystemErr R

Re: SolrJ CollectionAdminRequest.Reload fails

2015-09-11 Thread Shawn Heisey
On 9/11/2015 3:12 PM, Hendrik Haddorp wrote: > I'm using Solr 5.3.0 and noticed that the following code does not work > with Solr Cloud: > CollectionAdminRequest.Reload reloadReq = new > CollectionAdminRequest.Reload(); > reloadReq.process(client, collection); > > It complains that the name

SolrJ CollectionAdminRequest.Reload fails

2015-09-11 Thread Hendrik Haddorp
Hi, I'm using Solr 5.3.0 and noticed that the following code does not work with Solr Cloud: CollectionAdminRequest.Reload reloadReq = new CollectionAdminRequest.Reload(); reloadReq.process(client, collection); It complains that the name parameter is required. When adding reloadReq.set

SolrJ JavaDoc SolrInputDocument.addFiled(..)

2015-09-09 Thread Hendrik Haddorp
method and the version without the boost value does actually invoke the one with a boost value set to 1. regards, Hendrik [1] http://lucene.apache.org/solr/5_3_0/solr-solrj/org/apache/solr/common/SolrInputDocument.html#addField%28java.lang.String,%20java.lang.Object%29

Re: How to close log when use the solrj api

2015-08-20 Thread Susheel Kumar
g 20, 2015 at 4:30 AM, fent wrote: > when i use solrj api to add category data to solr , > their will have a lot of DEBUG info , > how to close this ,or how to set the log ? > ths > > > > -- > View this message in context: > http://lucene.472066.n3.nabble.com/How-t

How to close log when use the solrj api

2015-08-20 Thread fent
when i use solrj api to add category data to solr , their will have a lot of DEBUG info , how to close this ,or how to set the log ? ths -- View this message in context: http://lucene.472066.n3.nabble.com/How-to-close-log-when-use-the-solrj-api-tp4224142.html Sent from the Solr - User

Re: how to extend JavaBinCodec and make it available in solrj api

2015-08-17 Thread Dmitry Kan
et text goes here > >>> > > >>> > > >>> > > >>> > > >>> > > >>> > > >>> > > >>> > > >>> > > >>> > > >>> > Can

Re: SolrJ update

2015-08-09 Thread Henrique O. Santos
n, create a UUID field on Solrj and add that ID to the outcoming document. Best, Andrea 2015-08-06 21:39 GMT+02:00 Henrique O. Santos : Hello all, I am using SolrJ to do a index update on one of my collections. This collection has a uniqueKey id field: id This field

Re: how to extend JavaBinCodec and make it available in solrj api

2015-08-08 Thread Shalin Shekhar Mangar
existing types? >>> > >>> > >>> > On Thu, Aug 6, 2015 at 9:47 PM, Shalin Shekhar Mangar < >>> > shalinman...@gmail.com> wrote: >>> > >>> >> What do you mean by a custom format? As long as your custom component >>>

Re: how to extend JavaBinCodec and make it available in solrj api

2015-08-08 Thread Shalin Shekhar Mangar
Shekhar Mangar < >> > shalinman...@gmail.com> wrote: >> > >> >> What do you mean by a custom format? As long as your custom component >> >> is writing primitives or NamedList/SimpleOrderedMap or collections >> >> such as List/Map, a

Re: how to extend JavaBinCodec and make it available in solrj api

2015-08-08 Thread Dmitry Kan
t; >> > > >> > Solr: 5.2.1 > >> > class: org.apache.solr.common.util.JavaBinCodec > >> > > >> > I'm working on a custom data structure for the highlighter. The data > >> > structure is ready in JSON and XML formats. I need al

Re: SolrJ update

2015-08-08 Thread Andrea Gazzarini
rsonally, if that is ok for your context, I'd completely avoid the problem moving the logic on the client side. I mean, create a UUID field on Solrj and add that ID to the outcoming document. Best, Andrea 2015-08-06 21:39 GMT+02:00 Henrique O. Santos : > Hello all, > > I am using So

Re: how to extend JavaBinCodec and make it available in solrj api

2015-08-07 Thread Shalin Shekhar Mangar
: >> > Hello, >> > >> > Solr: 5.2.1 >> > class: org.apache.solr.common.util.JavaBinCodec >> > >> > I'm working on a custom data structure for the highlighter. The data >> > structure is ready in JSON and XML formats. I need also

Re: how to extend JavaBinCodec and make it available in solrj api

2015-08-07 Thread Dmitry Kan
cture is already made serializable by extending the > WritableValue > > class (methods write and resolve). > > > > To receive the custom format on the client via solrj api, the data > > structure needs to be parseable by JavaBinCodec. Is this correct > > assumption? Can

SolrJ update

2015-08-06 Thread Henrique O. Santos
Hello all, I am using SolrJ to do a index update on one of my collections. This collection has a uniqueKey id field: id This field is configured to be auto generated on solrconfig.xml like this: id On my Java code, I just add the name

Re: how to extend JavaBinCodec and make it available in solrj api

2015-08-06 Thread Shalin Shekhar Mangar
class (methods write and resolve). > > To receive the custom format on the client via solrj api, the data > structure needs to be parseable by JavaBinCodec. Is this correct > assumption? Can we introduce the custom data structure consumer on the > solrj api without complete overhaul of

Re: how to extend JavaBinCodec and make it available in solrj api

2015-08-05 Thread Shawn Heisey
ructure is already made serializable by extending the WritableValue > class (methods write and resolve). > > To receive the custom format on the client via solrj api, the data > structure needs to be parseable by JavaBinCodec. Is this correct > assumption? Can we introduce the custom data structu

how to extend JavaBinCodec and make it available in solrj api

2015-08-05 Thread Dmitry Kan
class (methods write and resolve). To receive the custom format on the client via solrj api, the data structure needs to be parseable by JavaBinCodec. Is this correct assumption? Can we introduce the custom data structure consumer on the solrj api without complete overhaul of the api? Is there p

RE: Same query fails in SolrJ, but works in the browser.

2015-08-04 Thread Mark Horninger
-user Subject: Re: Same query fails in SolrJ, but works in the browser. On Tue, Aug 4, 2015 at 4:24 PM, Mark Horninger < mhornin...@grayhairsoftware.com> wrote: > Hi Solr Users, > > I am running into a problem where a more complex dismax query I am > trying to run works with no

Re: Same query fails in SolrJ, but works in the browser.

2015-08-04 Thread Mikhail Khludnev
8983/solr//select?q=Fred&defType=dismax&sort=date1%20desc&qf=Line1^2%20Line2%20Line3%20Line4%20Line5%20Line6%20Line7^2%20Line8^2%20Line9%20Line10^1 > > Like I said, I can run this query without problem in the browser, however > there is a problem trying to run the exact same query

Re: Same query fails in SolrJ, but works in the browser.

2015-08-04 Thread Erik Hatcher
What does Solr log in the 400 response situation? It’d be good to compare the logging of both browser and SolrJ requests - something is different. — Erik Hatcher, Senior Solutions Architect http://www.lucidworks.com <http://www.lucidworks.com/> > On Aug 4, 2015, at 9:24 AM, Mark

Same query fails in SolrJ, but works in the browser.

2015-08-04 Thread Mark Horninger
^2%20Line8^2%20Line9%20Line10^1 Like I said, I can run this query without problem in the browser, however there is a problem trying to run the exact same query within SolrJ, I get a 400 error back, with the text "undefined field name" The code to generate the query is as follows: q

How Index Xml file using solrJ or DIH or post command

2015-07-29 Thread Mugeesh Husain
I have more than 30 millions of xml files which is store in a filesystems, Please suggest me in which method i have to follows 1.) Should i have to use Solrj 1.) Should i have to use DIH 1.) Should i have to use post method(in terminal) Basically i have java and lucene developer new in solr. How

Re: SolrJ/Tika custom indexer not indexing CERTAIN .doc text?

2015-07-27 Thread Alexandre Rafalovitch
ot; > file text. It came out as just blank. The documents were 1997-2003. When I > opened them in word 2010 and RESAVED them as 2010 documents they indexed > just fine. > > So I guess I wanted to put this here if anybody has a problem creating their > own custom SolrJ inde

Re: SolrJ/Tika custom indexer not indexing CERTAIN .doc text?

2015-07-27 Thread Paden
cuments they indexed just fine. So I guess I wanted to put this here if anybody has a problem creating their own custom SolrJ indexer. I think the current version of tika has some compatibility issues with 2003 word docs. -- View this message in context: http://lucene.472066.n3.nabble.com/Solr

Re: Running SolrJ from Solr's REST API

2015-07-22 Thread Zheng Lin Edwin Yeo
but if I got it right you are trying > to write some code that will run as part of SOLR. > If that's the case, then you should take a look how to write SOLR plugins ( > https://wiki.apache.org/solr/SolrPlugins). SolrJ is client side library > that simplifies interactions between SOLR

Re: Running SolrJ from Solr's REST API

2015-07-22 Thread Emir Arnautovic
Hi Edwin, Not sure if I understood your case, but if I got it right you are trying to write some code that will run as part of SOLR. If that's the case, then you should take a look how to write SOLR plugins (https://wiki.apache.org/solr/SolrPlugins). SolrJ is client side library

Running SolrJ from Solr's REST API

2015-07-21 Thread Zheng Lin Edwin Yeo
Hi, Would like to check, as I've created a SorJ program and exported it as an Runnable JAR, how do I integrate it together with Solr so that I can call this JAR directly from Solr's REST API? Currently I can only run it on command prompt using the command java -jar solrj.jar I'm using Solr 5.2.1

Re: SolrJ/Tika custom indexer not indexing CERTAIN .doc text? | SIDENOTE

2015-07-10 Thread Erick Erickson
> Erick and Paden, > The following is not the source of your problem, but I thought I'd mention > it while you reference Erick's fantastic blog post on solrj > (http://lucidworks.com/blog/indexing-with-solrj/). I tried to comment on > Erick's blog post, but something

RE: SolrJ/Tika custom indexer not indexing CERTAIN .doc text? | SIDENOTE

2015-07-10 Thread Allison, Timothy B.
>>Wow, that code looks familiar ;)... Erick and Paden, The following is not the source of your problem, but I thought I'd mention it while you reference Erick's fantastic blog post on solrj (http://lucidworks.com/blog/indexing-with-solrj/). I tried to comment on Erick&

Re: SolrJ/Tika custom indexer not indexing CERTAIN .doc text?

2015-07-09 Thread Erick Erickson
n find something that's a problem. I just > find it weird that it was ONLY .doc files and when I put it into another > .doc it actually pulled. Thanks for the post and let me know if there's any > new info I should know. > > > > -- > View this message in context: > http://lucene.472066.n3.nabble.com/SolrJ-Tika-custom-indexer-not-indexing-CERTAIN-doc-text-tp4216541p4216576.html > Sent from the Solr - User mailing list archive at Nabble.com.

Re: SolrJ/Tika custom indexer not indexing CERTAIN .doc text?

2015-07-09 Thread Paden
4 weeks ago so I'll run that debugger and see if I can find something that's a problem. I just find it weird that it was ONLY .doc files and when I put it into another .doc it actually pulled. Thanks for the post and let me know if there's any new info I should know. -- View t

Re: SolrJ/Tika custom indexer not indexing CERTAIN .doc text?

2015-07-09 Thread Erick Erickson
: > I posted the code anyway just forgot to get rid of that line in the post. > Sorry > > > > -- > View this message in context: > http://lucene.472066.n3.nabble.com/SolrJ-Tika-custom-indexer-not-indexing-CERTAIN-doc-text-tp4216541p4216542.html > Sent from the Solr - User mailing list archive at Nabble.com.

Re: SolrJ/Tika custom indexer not indexing CERTAIN .doc text?

2015-07-09 Thread Paden
I posted the code anyway just forgot to get rid of that line in the post. Sorry -- View this message in context: http://lucene.472066.n3.nabble.com/SolrJ-Tika-custom-indexer-not-indexing-CERTAIN-doc-text-tp4216541p4216542.html Sent from the Solr - User mailing list archive at Nabble.com.

SolrJ/Tika custom indexer not indexing CERTAIN .doc text?

2015-07-09 Thread Paden
++_totalTika; // Completely arbitrary, just batch up more than one document // for throughput! // Commit within 5 minutes.

RE: language identification during solrj indexing

2015-07-02 Thread Markus Jelsma
https://wiki.apache.org/solr/LanguageDetection -Original message- > From:Alessandro Benedetti > Sent: Thursday 2nd July 2015 11:06 > To: solr-user@lucene.apache.org > Subject: Re: language identification during solrj indexing > > SolrJ is simply a java client to ac

Re: language identification during solrj indexing

2015-07-02 Thread Alessandro Benedetti
SolrJ is simply a java client to access Solr REST API. This means that " indexing through SolrJ" doesn't exist. You simply need to add the proper chain to the update request handler you are using. Taking a look to the code , by Default SolrJ UpdateRequest refers to the "/update

language identification during solrj indexing

2015-07-02 Thread vineet yadav
Hi, I want to identify language identification during solrj indexing. I have made configuration changes required for language identification on the basis of solr wiki( https://cwiki.apache.org/confluence/display/solr/Detecting+Languages+During+Indexing ). language detection update chain is

Re: /suggest through SolrJ?

2015-06-25 Thread Alessandro Benedetti
in the dev mailing list, I will open a Jira Issue >> for that ! >> >> Cheers >> >> 2015-04-29 12:16 GMT+01:00 Tommaso Teofili : >> >>> 2015-04-27 19:22 GMT+02:00 Alessandro Benedetti < >>> benedetti.ale...@gmail.com> >>> : >>

Re: /suggest through SolrJ?

2015-06-24 Thread Alessandro Benedetti
e for > that ! > > Cheers > > 2015-04-29 12:16 GMT+01:00 Tommaso Teofili : > >> 2015-04-27 19:22 GMT+02:00 Alessandro Benedetti < >> benedetti.ale...@gmail.com> >> : >> >> > Just had the very same problem, and I confirm that currently is quit

Re: Index time field boost with solrj?

2015-06-23 Thread Shawn Heisey
On 6/23/2015 4:42 AM, Karl Kildén wrote: > Hello! Can I boost fields at index time with the solrj client? If not what > do you recommend? Feels like it would be expensive to always do it at query > time? Yes. On the SolrInputDocument class, there are addField and setField variants that

Index time field boost with solrj?

2015-06-23 Thread Karl Kildén
Hello! Can I boost fields at index time with the solrj client? If not what do you recommend? Feels like it would be expensive to always do it at query time? Cheers

Re: Error when submitting PDF to Solr w/text fields using SolrJ

2015-06-19 Thread Erick Erickson
> -- > View this message in context: > http://lucene.472066.n3.nabble.com/Error-when-submitting-PDF-to-Solr-w-text-fields-using-SolrJ-tp4212704p4212967.html > Sent from the Solr - User mailing list archive at Nabble.com.

Re: Error when submitting PDF to Solr w/text fields using SolrJ

2015-06-19 Thread Paden
it worked like a dream. Thanks! You might have just helped me finish this project. -- View this message in context: http://lucene.472066.n3.nabble.com/Error-when-submitting-PDF-to-Solr-w-text-fields-using-SolrJ-tp4212704p4212967.html Sent from the Solr - User mailing list archive at Nabble.com.

Re: Error when submitting PDF to Solr w/text fields using SolrJ

2015-06-19 Thread Erick Erickson
This may be another forehead-slapper (man, you don't know how often I've injured myself that way). Did you commit at the end of the SolrJ indexing to Testcore2? DIH automatically commits at the end of the run, and depending on how your SolrJ program is written it may not have. O

Re: Error when submitting PDF to Solr w/text fields using SolrJ

2015-06-19 Thread Alessandro Benedetti
Testcore on some > random common word like "a" it returns like 279 files. A good margin I can > accept that. > > The second core, which I will refer to as Testcore2, I used my own indexer > that I created and use SolrJ as the client. It indexes everything. However, > when

Re: Error when submitting PDF to Solr w/text fields using SolrJ

2015-06-19 Thread Paden
ommon word like "a" it returns like 279 files. A good margin I can accept that. The second core, which I will refer to as Testcore2, I used my own indexer that I created and use SolrJ as the client. It indexes everything. However, when I query on the same word "a" it only retur

Re: Error when submitting PDF to Solr w/text fields using SolrJ

2015-06-19 Thread Alessandro Benedetti
index the text content without truncating > all the info or filtering it out entirely, thereby messing up my searching > capabilities. > > > > -- > View this message in context: > http://lucene.472066.n3.nabble.com/Error-when-submitting-PDF-to-Solr-w-text-fields-using-Sol

Re: Error when submitting PDF to Solr w/text fields using SolrJ

2015-06-19 Thread Paden
r filtering it out entirely, thereby messing up my searching capabilities. -- View this message in context: http://lucene.472066.n3.nabble.com/Error-when-submitting-PDF-to-Solr-w-text-fields-using-SolrJ-tp4212704p4212919.html Sent from the Solr - User mailing list archive at Nabble.com.

SolrJ: getBeans with multiple document types in response

2015-06-19 Thread Catala, Francois
Hello, I'm trying to parse Solr Responses with SolrJ, but the responses contain mixed types : for example 'song' documents and 'movie' documents with different fields. The getBeans method takes 1 class type as input parameter, this does not allow for mixed document ty

Re: Error when submitting PDF to Solr w/text fields using SolrJ

2015-06-19 Thread Alessandro Benedetti
e and it won't index a set of > > documents. When I clear the index and run the program again it > > submits/doesn't submit the same documents. > > > > And it will index certain PDF's it just won't index others. Which is > weird > > because

Re: Error when submitting PDF to Solr w/text fields using SolrJ

2015-06-18 Thread Erick Erickson
lar to the ones that aren't submitted. > > I can't post the actual strings for sensitivity reasons. > > > > -- > View this message in context: > http://lucene.472066.n3.nabble.com/Error-when-submitting-PDF-to-Solr-w-text-fields-using-SolrJ-tp4212704p4212757.html > Sent from the Solr - User mailing list archive at Nabble.com.

Re: Error when submitting PDF to Solr w/text fields using SolrJ

2015-06-18 Thread Paden
are really similar to the ones that aren't submitted. I can't post the actual strings for sensitivity reasons. -- View this message in context: http://lucene.472066.n3.nabble.com/Error-when-submitting-PDF-to-Solr-w-text-fields-using-SolrJ-tp4212704p4212757.html Sent from the Solr - User mailing list archive at Nabble.com.

Re: Error when submitting PDF to Solr w/text fields using SolrJ

2015-06-18 Thread Paden
(SolrClient.java:153) at TikaSqlIndexer.Index(TikaSqlIndexer.java:238) at TikaSqlIndexer.main(TikaSqlIndexer.java:85) -- View this message in context: http://lucene.472066.n3.nabble.com/Error-when-submitting-PDF-to-Solr-w-text-fields-using-SolrJ-tp4212704p4212736.html Sent from the Solr

Re: Error when submitting PDF to Solr w/text fields using SolrJ

2015-06-18 Thread Alessandro Benedetti
hing to do with how the field is defined in schema but > I > don't know. All the files that get error messages are PDF's if that helps. > There are .doc s in the file system but they don't error out. > > > > > > > -- > View this message in context:

Error when submitting PDF to Solr w/text fields using SolrJ

2015-06-18 Thread Paden
hey don't error out. -- View this message in context: http://lucene.472066.n3.nabble.com/Error-when-submitting-PDF-to-Solr-w-text-fields-using-SolrJ-tp4212704.html Sent from the Solr - User mailing list archive at Nabble.com.

Solrj Tika/Cell not using defaultField

2015-06-14 Thread Charlie Hubbard
I'm having trouble getting Solr to pay attention to the defaultField value when I send a document to Solr Cell or Tika. Here is my post I'm sending using Solrj POST /solr/collection1/update/extract?extractOnly=true&defaultField=text&wt=javabin&version=2 HTTP/1.1 When I get

Re: How can I parse the TermVectorComponent response in SolrJ

2015-06-04 Thread Majid Laali
Hi, Based on a few hours googling, I concluded that there is no class in SOLR 5.1 that can parser JSON response of The Term Vector Component. I am not sure if it is fine to create an issue in the SOLR JIRA website and make patch to address it. I would be grateful to get any advice for that.

How can I parse the TermVectorComponent response in SolrJ

2015-05-22 Thread Majid Laali
Hi, I have a java program that sends a query to solr and get the term vector of a document. Something like this: SolrQuery solrQuery = new SolrQuery(); solrQuery.setRequestHandler("/tvrh"); solrQuery.setQuery("id:" + id); solrQuery.setParam("fl", textField); solrQuery.setParam("tv.tf", "true");

Re: JARs needed to run SolrJ

2015-05-12 Thread Shawn Heisey
On 5/12/2015 12:33 PM, Steven White wrote: > Hi Everyone, > > I am trying to use SolrJ to add docs to Solr. The following line: > > HttpSolrClient solrServer = new HttpSolrClient(" > http://localhost:8983/solr";); > > Is failing with exception:

Re: JARs needed to run SolrJ

2015-05-12 Thread Emir Arnautovic
Hi Steve, You can find list of dependencies in its pom: http://central.maven.org/maven2/org/apache/solr/solr-solrj/5.1.0/solr-solrj-5.1.0.pom It would be best if you use some dependency management tool. You can use it in separate project to create all-in-one jar and than include that one in

JARs needed to run SolrJ

2015-05-12 Thread Steven White
Hi Everyone, I am trying to use SolrJ to add docs to Solr. The following line: HttpSolrClient solrServer = new HttpSolrClient(" http://localhost:8983/solr";); Is failing with exception: Exception in thread "main" java.lang.NoClassDefFoundError: org.apache.commons.l

Re: SolrJ vs. plain old HTTP post

2015-05-12 Thread Steven White
> > > > > > To close the loop on this question, I will need to enable Jetty's SSL > (the > > jetty that comes with Solr 5.1). If I do so, will SolrJ still work, can > I > > assume that SolrJ supports SSL? > > > > > Yes, SolrJ can work with

Re: Creating a new collection via solrj

2015-05-12 Thread Erick Erickson
; configuration/, for example) > > However, I did not find a solrj example describing these steps. > > If one of you could help.. > > thanks! > > Benjamin

Creating a new collection via solrj

2015-05-12 Thread Sznajder ForMailingList
Hi, I would like to create programmatically a new collection with a given Schema (the schema.xml file is in my java project under a folder configuration/, for example) However, I did not find a solrj example describing these steps. If one of you could help.. thanks! Benjamin

Re: SolrJ vs. plain old HTTP post

2015-05-11 Thread Shalin Shekhar Mangar
On Mon, May 11, 2015 at 8:20 PM, Steven White wrote: > Thanks Erik and Emir. > > > > To close the loop on this question, I will need to enable Jetty's SSL (the > jetty that comes with Solr 5.1). If I do so, will SolrJ still work, can I > assume that SolrJ supports SS

Re: SolrJ vs. plain old HTTP post

2015-05-11 Thread Steven White
Thanks Erik and Emir. Erik: The fact that SolrJ is aware of SolrCloud is enough to put it over plain old HTTP post. Emir: I looked into Solr's data import handler, unfortunately, it won't work for my need. To close the loop on this question, I will need to enable Jetty's SSL

Re: SolrJ vs. plain old HTTP post

2015-05-11 Thread Erik Hatcher
Another advantage to SolrJ is with SolrCloud (ZK) awareness, and taking advantage of some routing optimizations client-side so the cluster has less hops to make. — Erik Hatcher, Senior Solutions Architect http://www.lucidworks.com <http://www.lucidworks.com/> > On May 11, 2015, a

Re: SolrJ vs. plain old HTTP post

2015-05-11 Thread Emir Arnautovic
rt * http://sematext.com/ On 11.05.2015 14:21, Steven White wrote: Hi Everyone, If all that I need to do is send data to Solr to add / delete a Solr document, which tool is better for the job: SolrJ or plain old HTTP post? In other word, what are the advantages of using SolrJ when the need is to pus

SolrJ vs. plain old HTTP post

2015-05-11 Thread Steven White
Hi Everyone, If all that I need to do is send data to Solr to add / delete a Solr document, which tool is better for the job: SolrJ or plain old HTTP post? In other word, what are the advantages of using SolrJ when the need is to push data to Solr for indexing? Thanks, Steve

Re: /suggest through SolrJ?

2015-05-06 Thread Alessandro Benedetti
; Just had the very same problem, and I confirm that currently is quite a > > mess to manage suggestions in SolrJ ! > > I have to go with manual Json parsing. > > > > or very not nice NamedList API mess (see an example in JR Oak [1][2]). > > Regards, > Tommaso > >

SolrJ 5.1 json.facets

2015-05-02 Thread pkulksandeep
How to access resutls of 'json.facets' from solrJ? I don't see any specific API in QueryResponse. Can I use getBeans API? Thanks, Sandeep -- View this message in context: http://lucene.472066.n3.nabble.com/SolrJ-5-1-json-facets-tp4203509.html Sent from the Solr - User mailing

RE: How to start an optimize in SolrJ without waiting for it to complete?

2015-05-01 Thread Ryan, Michael F. (LNG-DAY)
ly. I think you'll need to run it on a separate thread. -Michael -Original Message- From: Shawn Heisey [mailto:apa...@elyograg.org] Sent: Friday, May 01, 2015 10:09 AM To: solr-user@lucene.apache.org Subject: Re: How to start an optimize in SolrJ without waiting for it to complete? O

Re: How to start an optimize in SolrJ without waiting for it to complete?

2015-05-01 Thread Shawn Heisey
On 5/1/2015 7:23 AM, Shawn Heisey wrote: > This is my solrj code: > > UpdateRequest req = new UpdateRequest("/" + _name + "/update"); > req.setAction(UpdateRequest.ACTION.OPTIMIZE, false, false); > UpdateResponse ur = req.process(_client); Followup. I

How to start an optimize in SolrJ without waiting for it to complete?

2015-05-01 Thread Shawn Heisey
This is my solrj code: UpdateRequest req = new UpdateRequest("/" + _name + "/update"); req.setAction(UpdateRequest.ACTION.OPTIMIZE, false, false); UpdateResponse ur = req.process(_client); The _name variable contains the name of the core, and _client is a 5.0 Solr

Re: /suggest through SolrJ?

2015-04-29 Thread Tommaso Teofili
2015-04-27 19:22 GMT+02:00 Alessandro Benedetti : > Just had the very same problem, and I confirm that currently is quite a > mess to manage suggestions in SolrJ ! > I have to go with manual Json parsing. > or very not nice NamedList API mess (see an example in JR Oak [1][2]). Rega

Re: /suggest through SolrJ?

2015-04-29 Thread Jan Høydahl
Alessandro, can you open a JIRA issue for this? -- Jan Høydahl, search solution architect Cominvent AS - www.cominvent.com > 27. apr. 2015 kl. 19.22 skrev Alessandro Benedetti > : > > Just had the very same problem, and I confirm that currently is quite a > mess to manage sugge

Re: /suggest through SolrJ?

2015-04-27 Thread Alessandro Benedetti
Just had the very same problem, and I confirm that currently is quite a mess to manage suggestions in SolrJ ! I have to go with manual Json parsing. Cheers 2015-02-02 12:17 GMT+00:00 Jan Høydahl : > Using the /suggest handler wired to SuggestComponent, the > SpellCheckResponse objects a

Re: Integrating Solr with an existing web application - and SolrJ

2015-04-27 Thread O. Olson
t; connection alive. So "open a connection" likely won't happen. You can feel > safe in relying on SolrJ or any other reasonable HTTP-based client > communicating to Solr from your web app. > > Also, I always discourage suggesters that work on "every keypress"

Re: Integrating Solr with an existing web application - and SolrJ

2015-04-27 Thread Doug Turnbull
l safe in relying on SolrJ or any other reasonable HTTP-based client communicating to Solr from your web app. Also, I always discourage suggesters that work on "every keypress". You probably want a number of keypresses and a timeout to avoid overloading your Solr servers. Or if you truly w

Integrating Solr with an existing web application - and SolrJ

2015-04-27 Thread O. Olson
at is the most popular way of integrating Solr? For e.g. do you just run Solr on the same WebServer/Application Server? 2. If you run Solr on a separate Server, how do you communicate with it from the Webserver? I was thinking of using SolrJ for this. However, I think that each time there is a

Using SolrJ to access schema.xml

2015-04-24 Thread Steven White
Hi Everyone, Per this link https://cwiki.apache.org/confluence/display/solr/Schema+API#SchemaAPI-ListFieldTypes Solr supports REST Schema API to modify to the schema. I looked at http://lucene.apache.org/solr/4_2_1/solr-solrj/index.html?overview-summary.html in hope SolrJ has Java API to allow

SolrJ Exceptions

2015-04-16 Thread Bryan Bende
I'm trying to identify the difference between an exception when Solr is in a bad state/down vs. when it is up but an invalid request was made (maybe some bad data sent in). The JavaDoc for SolrRequest process() says: *@throws SolrServerException if there is an error on the Solr server@throws IOE

Re: SolrJ commit with openSearcher=false

2015-03-31 Thread Erick Erickson
Hmmm, you really shouldn't have to do this. What have you tried to figure out why the strange node isn't getting cleaned up? Is there anything in the Solr logs that might help? Is it a Windows machine? Some of the delete semantics for Windows can leave things around. What happens if you restart th

Re: SolrJ commit with openSearcher=false

2015-03-31 Thread Shawn Heisey
On 3/31/2015 2:56 AM, vidit.asthana wrote: > Thanks for reply Shawn. I will try it out. > > The reason that I am forced to do a hard commit through code is to handle a > problem I am facing with transaction logs. > > I am forced to delete tlogs manually at regular interval and hence I want to > iss

Re: SolrJ commit with openSearcher=false

2015-03-31 Thread vidit.asthana
. -- View this message in context: http://lucene.472066.n3.nabble.com/SolrJ-commit-with-openSearcher-false-tp4196499p4196527.html Sent from the Solr - User mailing list archive at Nabble.com.

Re: SolrJ commit with openSearcher=false

2015-03-30 Thread Shawn Heisey
On 3/31/2015 12:25 AM, vidit.asthana wrote: > How can I issue a hard commit through SolrJ such that openSearcher=false? > > Also how can I issue same request through http? Will this work - > > curl > "http://localhost:8983/solr/collection1/update?commit=true&openS

SolrJ commit with openSearcher=false

2015-03-30 Thread vidit.asthana
How can I issue a hard commit through SolrJ such that openSearcher=false? Also how can I issue same request through http? Will this work - curl "http://localhost:8983/solr/collection1/update?commit=true&openSearcher=false"; -- View this message in context: http://lu

<    3   4   5   6   7   8   9   10   11   12   >