Solrj and server shutdown

2012-09-28 Thread Marc SCHNEIDER
Hi, I'm using SolrJ along with EmbeddedServer component in a Tomcat server. I was wondering why Tomcat couldn't be gracefully shut down and discovered it was a Solr issue. When Tomcat is stopped I do call the shutdown methods of both CoreContainer and EmbeddedSolrServer instances. But this didn't

Re: Facets involving multiple fields

2012-04-13 Thread Marc SCHNEIDER
computer short_title:computer > seems like what you're asking for. > > On Thu, Apr 12, 2012 at 3:19 AM, Marc SCHNEIDER > wrote: >> Hi, >> >> Thanks for your answer. >> Let's say I have to fields : 'keywords' and 'short_title'

Re: Facets involving multiple fields

2012-04-12 Thread Marc SCHNEIDER
d into a single facet? What that means practically is not at > all obvious from your problem statement. > > Best > Erick > > On Tue, Apr 10, 2012 at 8:55 AM, Marc SCHNEIDER > wrote: >> Hi, >> >> I'd like to make a faceted search using two fields. I w

Facets involving multiple fields

2012-04-10 Thread Marc SCHNEIDER
Hi, I'd like to make a faceted search using two fields. I want to have a single result and not a result by field (like when using facet.field=f1,facet.field=f2). I don't want to use a copy field either because I want it to be dynamic at search time. As far as I know this is not possible for Solr 3

Re: Problem with facet.fields

2012-01-05 Thread Marc SCHNEIDER
Hello, Thanks a lot for your answers. Sorry I typed it wrong, it was : q=*:*&facet=true&facet.field=foo&facet.field=lom.classification.ddc.id which caused an error. That's said I added echoParms to the request and only got : lom.classification.ddc.id So multivalued URL params are not taken in a

Problem with facet.fields

2012-01-04 Thread Marc SCHNEIDER
Hi, I'm quite sure I'm missing something but I'm getting mad with this problem : If I put : q=*:*&facet=true&facet.field=lom.classification.ddc.id => I have results for facet fields If I put : q=*:*&facet=true&facet.field=lom.educational.context => I have results for facet fields But if I put :

Re: Merging results of facet fields

2012-01-04 Thread Marc SCHNEIDER
> filter) on that field instead. > > > > If there were a way to do it the way you're asking (there might be, I > don't know), there's no guarantee that the total of 23 is correct. If > there's overlap ie a document having both product and tag values of > &

Merging results of facet fields

2012-01-04 Thread Marc SCHNEIDER
Hello, I have two fields 'product' and 'tag'. Executing this query q=*:*&facet=true&facet.field=product&facet.field=tag gives me this result : 16 ... 7 ... Is there a way to group the results by value ie getting 23, regardless of the field names? Thanks in adva

Re: Solr Best Practice Configuration

2011-12-09 Thread Marc SCHNEIDER
Hi, What about using the delta-import command of the DIH? http://wiki.apache.org/solr/DataImportHandler#Using_delta-import_command If you want two have 2 separated indexes, you could play with the "swap" command. One index would be continuously updated and the other one used for the user requests

Re: Edismax and fuzzy querying

2011-12-08 Thread Marc SCHNEIDER
e.. > > Best > Erick > > On Wed, Dec 7, 2011 at 3:15 AM, Marc SCHNEIDER > wrote: > > Hello, > > > > I'm using edismax and Solr 4.0 and I'd like to add fuzzy parameters for > > some fields like this : > > > > my_field1~2 my_field2 my_f

Re: Boost Query in Edismax

2011-12-08 Thread Marc SCHNEIDER
Hi, Maybe you could have a look at this : http://wiki.apache.org/solr/DisMaxQParserPlugin#tie_.28Tie_breaker.29 Marc. On Wed, Dec 7, 2011 at 5:48 PM, John wrote: > I have a complex edismax query: > > > facet=true&facet.mincount=0&qf=title^0.08+categorysearch^0.05+abstract^0.03+body^0.1&wt=java

Edismax and fuzzy querying

2011-12-07 Thread Marc SCHNEIDER
Hello, I'm using edismax and Solr 4.0 and I'd like to add fuzzy parameters for some fields like this : my_field1~2 my_field2 my_field3 Unfortunately It doesn't work, so I tried following approaches : 1) /select?q=my_search_string~2 => of course it applies to *all* fields of my edismax query, an

Re: lower score for synonyms

2011-12-06 Thread Marc SCHNEIDER
Hello, You could create an other field and link to it the synonym analyzer. When querying set a lower boost for this field. Marc. On Tue, Dec 6, 2011 at 11:31 AM, Robert Brown wrote: > is it possible to lower the score for synonym matches? > > we setup... > > admin => administration > > but if

Re: mysolr python client

2011-12-01 Thread Marc SCHNEIDER
Hi Marco, Great! Maybe you can add it on the Solr wiki? ( http://wiki.apache.org/solr/IntegratingSolr). Regards, Marc. On Thu, Dec 1, 2011 at 10:42 AM, Jens Grivolla wrote: > On 11/30/2011 05:40 PM, Marco Martinez wrote: > >> For anyone interested, recently I've been using a new Solr client fo

Re: indexing FTP documet with solrj

2011-10-05 Thread Marc SCHNEIDER
Hello, To crawl the document you can use Apache Tika before sending the content to Solr (via Solrj). Regards, Marc. On Wed, Oct 5, 2011 at 1:16 AM, Chris Hostetter wrote: > > : I want to index some document with solrj API's but the URL of theses > : documents is FTP, > : How to set username an

Re: Testing Solr Search results

2011-09-05 Thread Marc SCHNEIDER
Hi, It depends what you want to test. If you want to check that your fields behave like they should (for example make sure that the content of a field containing accents can be retrieved) they you can write unit tests using a Solr client API like solrj. You insert sample data and then you programma

Re: Updating fields in an existing document

2011-07-22 Thread Marc SCHNEIDER
Yes that's it if you add twice the same document (ie with the same id) it will replace it. On Thu, Jul 21, 2011 at 7:46 PM, Benson Margulies wrote: > A followup. The wiki has a whole discussion of the 'update' XML > message. But solrj has nothing like it. Does that really exist? Is > there a reas

Re: commit time and lock

2011-07-22 Thread Marc SCHNEIDER
Hello, Pierre, can you tell us where you read that? "I've read here that optimization is not always a requirement to have an efficient index, due to some low level changes in lucene 3.xx" Marc. On Fri, Jul 22, 2011 at 2:10 PM, Pierre GOSSE wrote: > Solr will response for search during optimizat

Question about optimization

2011-06-24 Thread Marc SCHNEIDER
Hi, I saw this in the Solr wiki : "An un-optimized index is going to be *at least* 10% slower for un-cached queries." Is this still true? I read somewhere that recent versions of Lucene where less sensitive to un-ptimized indexed than is the past... Having 50 000 new (or updated) documents coming

Re: Getting query fields in a custom SearchHandler

2011-06-08 Thread Marc SCHNEIDER
Fri, Jun 3, 2011 at 9:15 AM, Marc SCHNEIDER wrote: > Hi all, > > I wrote my own SearchHandler and therefore overrided the handleRequestBody > method. > This method takes two input parameters : SolrQueryRequest and > SolrQueryResponse objects. > The thing I'd like to do is t

Re: Solr Field name restrictions

2011-06-06 Thread Marc SCHNEIDER
Hi, Using Solr 3.1 I'm getting errors when trying to sort on fields containing dashes in the name... So that's true stay away from dashes if you can. Marc. On Sun, Jun 5, 2011 at 3:46 PM, Erick Erickson wrote: > I'd stay away from dashes too. It's too easy for the query parsers > to mistake the

Getting query fields in a custom SearchHandler

2011-06-03 Thread Marc SCHNEIDER
Hi all, I wrote my own SearchHandler and therefore overrided the handleRequestBody method. This method takes two input parameters : SolrQueryRequest and SolrQueryResponse objects. The thing I'd like to do is to get the query fields that are used in my request. Of course I can use req.getParams().g

Re: solrj, boost and schema.xml

2011-05-17 Thread Marc SCHNEIDER
self with normal XML parsing techniques. > > At least that's my understanding... > > Best > Erick > > On Tue, May 17, 2011 at 3:01 AM, Marc SCHNEIDER > wrote: > > Hi, > > > > I defined fields in my schema.xml using the boost attribute. > > Now I&#

Re: Problem about Solrj

2011-05-17 Thread Marc SCHNEIDER
Hi, What is the error exactly? Did you look at the logs? Regards, Marc. 2011/5/17 > Dear all, >   > I have a problem about using solrj. > From Solrj I learned that following code would delete all indexes from solr > and it really did. >   >    SolrServer server = getSolrServer(); >    UpdateRe

solrj, boost and schema.xml

2011-05-17 Thread Marc SCHNEIDER
Hi, I defined fields in my schema.xml using the boost attribute. Now I'm using Solrj to index my documents so after having created a SolrInputDocument I use the addField method. A boost parameter can be provided. But how can I read the boost value I defined in schema.xml for that field so that I c

Format date before indexing it

2011-05-05 Thread Marc SCHNEIDER
Hi, I have to index records that have fields containing date. This date can be : "2011", "2011-05", "2015-05-01". Trailing characters also can be slashes. I'd like to convert theses values into a valid date for Solr. So my question is : what is the best way to achieve this? 1) Use solr.DateField

Re: Solrj and display which Solr version is used

2011-04-06 Thread Marc SCHNEIDER
esponseBody)); > >} catch (Exception e) { > e.printStackTrace(); > } finally { > // Release the connection. > method.releaseConnection(); >} > } > > On Tue, Apr 5, 2011 at 5:46 AM, Marc SCHNEIDER > wrote: > > > Hi, > > > > I'm wondering how to find out which version of Solr is currently running > > using the Solrj library? > > > > Thanks, > > Marc. > > >

Solrj and display which Solr version is used

2011-04-05 Thread Marc SCHNEIDER
Hi, I'm wondering how to find out which version of Solr is currently running using the Solrj library? Thanks, Marc.

Re: Transform a SolrDocument into a SolrInputDocument

2011-03-22 Thread Marc SCHNEIDER
Ok that's perfectly clear. Thanks a lot for all your answers! Marc. On Mon, Mar 21, 2011 at 4:34 PM, Gora Mohanty wrote: > On Mon, Mar 21, 2011 at 8:33 PM, Marc SCHNEIDER > wrote: > > Hi Erick, > > > > Thanks for your answer. > > I'm a quite newbie to S

Re: Transform a SolrDocument into a SolrInputDocument

2011-03-21 Thread Marc SCHNEIDER
to be aware of. > > Best > Erick > > On Mon, Mar 21, 2011 at 10:20 AM, Marc SCHNEIDER > wrote: > > Hi Péter, > > > > I'm not sure to understand your answer. A SolrInputDocument always > contains > > only stored fields, so I don't see th

Re: Transform a SolrDocument into a SolrInputDocument

2011-03-21 Thread Marc SCHNEIDER
Hi Ahmet, That did it, thanks a lot! Marc. On Mon, Mar 21, 2011 at 3:03 PM, Ahmet Arslan wrote: > > Is there a fastest way to do that? I mean transforming a > > SolrDocument into a > > SolrInputDocument? > > Does these static methods help? > > org.apache.solr.client.solrj.util.ClientUtils.toS

Re: Transform a SolrDocument into a SolrInputDocument

2011-03-21 Thread Marc SCHNEIDER
it is working from the original > source, because it is possible, that not all fields are stores, and > the original content of the not stored fields is not inside the Solr > document. > > Péter > > 2011/3/21 Marc SCHNEIDER : > > Hello, > > > > I'd l

Transform a SolrDocument into a SolrInputDocument

2011-03-21 Thread Marc SCHNEIDER
Hello, I'd like to know the fastest way (code lines) to update a field of a document. So my idea was: 1) Get a SolrDocument 2) Add all fields of the SolrDocument to a new SolrInputDocument 3) Update the field in SolrInputDocument 4) Add SolrInputDocument to the server and commit it Is there a fas

Re: adding a document using curl

2011-03-04 Thread Marc SCHNEIDER
Hi, Could you please post exactly what you tried? Regards, On Thu, Mar 3, 2011 at 12:31 PM, Ken Foskey wrote: > > I have read the various pages and used Curl a lot but i cannot figure out > the correct command line to add a document to the example Solr instance. > > I have tried a few things h

Re: Solr multi cores or not

2011-02-18 Thread Marc SCHNEIDER
how that works out. I > guess, if we have to run queries across the cores, I may have to just > run separate queries. > > -Original Message- > From: Marc SCHNEIDER [mailto:marc.schneide...@gmail.com] > Sent: Friday, February 18, 2011 8:01 AM > To: solr-user@lucene.

Re: Solr multi cores or not

2011-02-18 Thread Marc SCHNEIDER
Hi, It depends on what kind of data you are indexing between your multiple applications. If app1 has many fields to be indexed and app2 too and if theses fields are differents then it would probably be better to have multi cores. If you have a lot of common fields between app1 and app2 then one in

Re: Sharing a schema with multiple cores

2011-02-10 Thread Marc SCHNEIDER
Ok I found the solution: First of all schema is an attribute of the core tag so it becomes: Also make sure the conf directory in your classpath or relative to the path from where you are launching solr. It is NOT relative to solr.xml path. Marc. On Thu, Feb 10, 2011 at 2:48 PM, Marc SCHNEIDER

Sharing a schema with multiple cores

2011-02-10 Thread Marc SCHNEIDER
Hi, I'm using Solr 1.4.1 and trying to share a schema among two cores. Here is what I did : solr.xml : conf/schema.xml conf/schema.xml Then in my solr.home (where solr.xml lives) I created a conf directory and put schema.x