Re: Customizing solr with my lucene
What is the query parsed to? Add &debugQuery=true to your Solr request and let us know what the query parses to. As for whether upgrading a Lucene library is sufficient... depends on what Solr version you're starting with (payload support is already in all recent versions of Solr's Lucene JARs) and what has changed in Lucene since, and whether you're expecting an existing index to work or rebuilding it from scratch. Erik On Apr 14, 2009, at 7:51 AM, mirage1987 wrote: hey, I am trying to modify the lucene code by adding payload functionality into it. Now if i want to use this lucene with solr what should i do. I have added this to the lib folder of solr.war replacing the old lucene..Is this enough?? Plus i am also using a different schema than the default shema.xml used by solr.(Added some fields and removed some of the previous ones). The problem i am facing is that now the solr is not returning results but the lucene individually is for the same query. Could you help me on this...ny ideas n suggestions?? -- View this message in context: http://www.nabble.com/Customizing-solr-with-my-lucene-tp23038007p23038007.html Sent from the Solr - User mailing list archive at Nabble.com.
Re: Customizing solr with my lucene
Hi, Well let me exaplin the scenario in detail. I have my lucene.jar that i need to work with Solr. So i started by adding the lucene.jar to the WEB_INF directory of solr.war,added my schema.xml in conf dir and restarted the solr server. Now i run my program , add a doc into it. The doc is added successfully as shown by the stats. But when i query it through the browser no results are returned. I tried out with various terms in *:* shows the doc. Am i missing sumthin here. Is there a way i can view the posting list of the solr (lucene) and see weather my terms has been indexed or not. So let's say my doc has an entry like University of Southern California and i search for "california" no results from solr But wen i do it on my lucene without solr results are shown. I also tried the debug query into my queries as u suggested. Here is what i getThis is very much the way i have modified my lucene so query parsing seems correct − 0 0 − true on 0 name:california 10 2.2 − name:california name:california BoostingTermQuery(value:california) value:california OldLuceneQParser − 0.0 − 0.0 − 0.0 − 0.0 − 0.0 − 0.0 − 0.0 − 0.0 − 0.0 − 0.0 − 0.0 − 0.0 − 0.0 Erik Hatcher wrote: > > What is the query parsed to? Add &debugQuery=true to your Solr > request and let us know what the query parses to. > > As for whether upgrading a Lucene library is sufficient... depends on > what Solr version you're starting with (payload support is already in > all recent versions of Solr's Lucene JARs) and what has changed in > Lucene since, and whether you're expecting an existing index to work > or rebuilding it from scratch. > > Erik > > On Apr 14, 2009, at 7:51 AM, mirage1987 wrote: > >> >> hey, >> I am trying to modify the lucene code by adding payload >> functionality >> into it. >> Now if i want to use this lucene with solr what should i do. >> I have added this to the lib folder of solr.war replacing the old >> lucene..Is >> this enough?? >> Plus i am also using a different schema than the default shema.xml >> used by >> solr.(Added some fields and removed some of the previous ones). >> The problem i am facing is that now the solr is not returning >> results but >> the lucene individually is for the same query. >> Could you help me on this...ny ideas n suggestions?? >> -- >> View this message in context: >> http://www.nabble.com/Customizing-solr-with-my-lucene-tp23038007p23038007.html >> Sent from the Solr - User mailing list archive at Nabble.com. > > > -- View this message in context: http://www.nabble.com/Customizing-solr-with-my-lucene-tp23038007p23096895.html Sent from the Solr - User mailing list archive at Nabble.com.
Re: Customizing solr with my lucene
Hey Erik, I also checked the index using luke and the index shows that the terms are indexed as they should have been. So that implies that something is wrong with the querying only and the results are not getting retrieved.(As i said earlier even the parsed query is the way it should be according to the changes i have made to lucene.) Any ideas you have on this. Why this could be happening. One more thing... tried to query the solr index using luke ...but still no resultsmay be the index is not stored correctlycould it be changes in the lucene api???should i revert to an older version of solr??? -- View this message in context: http://www.nabble.com/Customizing-solr-with-my-lucene-tp23038007p23098700.html Sent from the Solr - User mailing list archive at Nabble.com.
Re: Customizing solr with my lucene
Just check your schema.xmlRegards, Allahbaksh On Fri, Apr 17, 2009 at 7:56 PM, mirage1987 wrote: > > Hey Erik, > I also checked the index using luke and the index shows that > the terms are indexed as they should have been. So that implies that > something is wrong with the querying only and the results are not getting > retrieved.(As i said earlier even the parsed query is the way it should be > according to the changes i have made to lucene.) > Any ideas you have on this. Why this could be happening. > > One more thing... tried to query the solr index using luke ...but still no > resultsmay be the index is not stored correctlycould it be changes > in the lucene api???should i revert to an older version of solr??? > > > > -- > View this message in context: > http://www.nabble.com/Customizing-solr-with-my-lucene-tp23038007p23098700.html > Sent from the Solr - User mailing list archive at Nabble.com. > > -- Allahbaksh Mohammedali Asadullah, Software Engineering & Technology Labs, Infosys Technolgies Limited, Electronic City, Hosur Road, Bangalore 560 100, India. (Board: 91-80-28520261 | Extn: 73927 | Direct: 41173927. Fax: 91-80-28520362 | Mobile: 91-9845505322.
Re: Customizing solr with my lucene
Hi, Here's the schema.xml i am using. id value I can't figure out the error. Do u see any probs with the current schema. The schema is defined as such because i have implemented the my own analyzer an tokenizer into the lucene index writer. So if solr calls the index writer then there should be no prob.Similarly i have made my changes to the lucene query parser so i want the default lucene query handling. So basically i intend to use the solr just to directly call my lucene. Is it possible or would i have to change the solr code?? One more prob i faced. I want to use dynamic fields="*" but it doesn't seem to work. As when i remove fieldName="name" from the above list no content error is reported (as my input file has name fields and dynamic field doesn't seem to catch it) Any ideas on this. Thanx. Allahbaksh Asadullah-2 wrote: > > Just check your schema.xmlRegards, > Allahbaksh > > On Fri, Apr 17, 2009 at 7:56 PM, mirage1987 wrote: > >> >> Hey Erik, >> I also checked the index using luke and the index shows that >> the terms are indexed as they should have been. So that implies that >> something is wrong with the querying only and the results are not getting >> retrieved.(As i said earlier even the parsed query is the way it should >> be >> according to the changes i have made to lucene.) >> Any ideas you have on this. Why this could be happening. >> >> One more thing... tried to query the solr index using luke ...but still >> no >> resultsmay be the index is not stored correctlycould it be >> changes >> in the lucene api???should i revert to an older version of solr??? >> >> >> >> -- >> View this message in context: >> http://www.nabble.com/Customizing-solr-with-my-lucene-tp23038007p23098700.html >> Sent from the Solr - User mailing list archive at Nabble.com. >> >> > > > -- > Allahbaksh Mohammedali Asadullah, > Software Engineering & Technology Labs, > Infosys Technolgies Limited, Electronic City, > Hosur Road, Bangalore 560 100, India. > (Board: 91-80-28520261 | Extn: 73927 | Direct: 41173927. > Fax: 91-80-28520362 | Mobile: 91-9845505322. > > -- View this message in context: http://www.nabble.com/Customizing-solr-with-my-lucene-tp23038007p23133779.html Sent from the Solr - User mailing list archive at Nabble.com.
Re: Customizing solr with my lucene
I'm not sure what is going on. I don't quite understand what you're doing to Lucene that requires replacing the JAR file, but of course that is quite a red flag for why things aren't working. Of course there is a concern of index compatibility, so be sure you're starting with no index and reindexing from scratch when trying a different Lucene build inside Solr, and you have to know what you're doing with solr.war manipulation to ensure you've got the right version there. And there may be dependencies on the other Lucene related JARs like all the contribs, so you might need to replace those in lock step fashion also. Erik On Apr 17, 2009, at 10:26 AM, mirage1987 wrote: Hey Erik, I also checked the index using luke and the index shows that the terms are indexed as they should have been. So that implies that something is wrong with the querying only and the results are not getting retrieved.(As i said earlier even the parsed query is the way it should be according to the changes i have made to lucene.) Any ideas you have on this. Why this could be happening. One more thing... tried to query the solr index using luke ...but still no resultsmay be the index is not stored correctlycould it be changes in the lucene api???should i revert to an older version of solr??? -- View this message in context: http://www.nabble.com/Customizing-solr-with-my-lucene-tp23038007p23098700.html Sent from the Solr - User mailing list archive at Nabble.com.
Re: Customizing solr with my lucene
Well guys the problem is now solved and evrythin's working perfectly fine.:-) Thankyou all for your help. The problem was indeed with the config files (schema and solrconfig). I rewrote my files from scratch and now everythin's seems to be working. The debug query option was quite helpful in making me understand solr works and help me made the required changes to my lucene code and api. -- View this message in context: http://www.nabble.com/Customizing-solr-with-my-lucene-tp23038007p23181503.html Sent from the Solr - User mailing list archive at Nabble.com.