Re: Patch problems solr 1.4 - solr-2010

2011-05-05 Thread roySolr
Hello,

thanks for the answers, i use branch 1.4 and i have succesfully patch
solr-2010.

Now i want to use the collate spellchecking. How does my url look like. I
tried this but
it's not working(It's the same as solr without solr-2010).

http://localhost:8983/solr/select?q=man unitetspellcheck.q=man
unitetspellcheck=truespellcheck.build=truespellcheck.collate=truespellcheck.collateExtendedResult=truespellcheck.maxCollations=10spellcheck.maxCollationTries=10

I get the collapse man united as suggestion. Man is good spelled, but not
in this phrase. It must
be manchester united and i want that solr requerying the collapse and only
give the suggestion
if it gives some results. How can i fix this??

--
View this message in context: 
http://lucene.472066.n3.nabble.com/Patch-problems-solr-1-4-solr-2010-tp2898443p2902546.html
Sent from the Solr - User mailing list archive at Nabble.com.


RE: Patch problems solr 1.4 - solr-2010

2011-05-05 Thread Dyer, James
There is still a functionality gap in Solr's spellchecker even with Solr-2010 
applied.  If a user enters a word that is in the dictionary, solr will never 
try to correct it.  The only way around this is to use 
spellcheck.onlyMorePopular.  The problem with this approach is 
onlyMorePopular causes the spellchecker to assume *every* word in the query 
is a misspelling and it won't even consider the original terms in building 
collations.  What is needed is a hybrid option that will try to build 
collations using combinations of original terms, corrected terms and more 
popular terms.  To my knowledge, there is no way to get the spellchecker to do 
that currently.

On the other hand, if you're pretty sure man is not in the dictionary, try 
upping spellcheck.count to something higher than the default (20 maybe?)...

James Dyer
E-Commerce Systems
Ingram Content Group
(615) 213-4311


-Original Message-
From: roySolr [mailto:royrutten1...@gmail.com] 
Sent: Thursday, May 05, 2011 3:24 AM
To: solr-user@lucene.apache.org
Subject: Re: Patch problems solr 1.4 - solr-2010

Hello,

thanks for the answers, i use branch 1.4 and i have succesfully patch
solr-2010.

Now i want to use the collate spellchecking. How does my url look like. I
tried this but
it's not working(It's the same as solr without solr-2010).

http://localhost:8983/solr/select?q=man unitetspellcheck.q=man
unitetspellcheck=truespellcheck.build=truespellcheck.collate=truespellcheck.collateExtendedResult=truespellcheck.maxCollations=10spellcheck.maxCollationTries=10

I get the collapse man united as suggestion. Man is good spelled, but not
in this phrase. It must
be manchester united and i want that solr requerying the collapse and only
give the suggestion
if it gives some results. How can i fix this??

--
View this message in context: 
http://lucene.472066.n3.nabble.com/Patch-problems-solr-1-4-solr-2010-tp2898443p2902546.html
Sent from the Solr - User mailing list archive at Nabble.com.


RE: Patch problems solr 1.4 - solr-2010

2011-05-04 Thread Dyer, James
I just did a clean check out on the 1.4.1 branch and then applied the latest 
(10/22/2010) version of SOLR-2010_141.patch and it applied cleanly.  

I noticed from the listing you sent that any new files it removes trailing 
crs from the text.  Maybe its not doing this for you on files that need to be 
modified?  So maybe try running dos2unix on the patch file before trying to 
apply it?  With that said, I use eclipse/subclipse to interact with svn so I've 
not tried applying this patch from a command line.

I also want to bring to your attention that we found a nasty bug when we went 
to production that can cause OOMs if a user enters a query with several 
misspelled words.  See SOLR-2462 for a description of the problem and a patch.  
This patch will not apply to 1.4.1 cleanly, but if you tell your svn client to 
ignore 1 leading path name segment, you can get it to apply the change to 
PossibilityIterator.java, which is all that is necessary to fix the bug.

James Dyer
E-Commerce Systems
Ingram Content Group
(615) 213-4311


-Original Message-
From: roySolr [mailto:royrutten1...@gmail.com] 
Sent: Wednesday, May 04, 2011 6:53 AM
To: solr-user@lucene.apache.org
Subject: Patch problems solr 1.4 - solr-2010

Hello,

I want to patch my solr installation(1.4.1) with
solr-2010.(https://issues.apache.org/jira/browse/SOLR-2010)

I need this feature:
Only return collations that are guaranteed to result in hits if re-queried 

Now i try the following code:

wget
https://issues.apache.org/jira/secure/attachment/12457683/SOLR-2010_141.patch
-O - | patch -p0  --dry-run

I get the following error message:

--13:51:35-- 
https://issues.apache.org/jira/secure/attachment/12457683/SOLR-2010_141.patch
Resolving issues.apache.org... 140.211.11.121
Connecting to issues.apache.org|140.211.11.121|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 55846 (55K) [text/x-patch]
Saving to: `STDOUT'

100%[]
55,846  59.3K/s   in 0.9s

13:51:37 (59.3 KB/s) - `-' saved [55846/55846]

(Stripping trailing CRs from patch.)
patching file src/common/org/apache/solr/common/params/SpellingParams.java
Hunk #1 FAILED at 81.
1 out of 1 hunk FAILED -- saving rejects to file
src/common/org/apache/solr/common/params/SpellingParams.java.rej
(Stripping trailing CRs from patch.)
patching file
src/java/org/apache/solr/handler/component/SpellCheckComponent.java
Hunk #1 FAILED at 24.
Hunk #2 FAILED at 141.
Hunk #3 FAILED at 155.
Hunk #4 FAILED at 214.
Hunk #5 FAILED at 252.
Hunk #6 FAILED at 262.
6 out of 6 hunks FAILED -- saving rejects to file
src/java/org/apache/solr/handler/component/SpellCheckComponent.java.rej
(Stripping trailing CRs from patch.)
patching file src/java/org/apache/solr/spelling/PossibilityIterator.java
(Stripping trailing CRs from patch.)
patching file src/java/org/apache/solr/spelling/RankedSpellPossibility.java
(Stripping trailing CRs from patch.)
patching file src/java/org/apache/solr/spelling/SpellCheckCollation.java
(Stripping trailing CRs from patch.)
patching file src/java/org/apache/solr/spelling/SpellCheckCollator.java
(Stripping trailing CRs from patch.)
patching file src/java/org/apache/solr/spelling/SpellCheckCorrection.java
(Stripping trailing CRs from patch.)
patching file
src/solrj/org/apache/solr/client/solrj/response/SpellCheckResponse.java
Hunk #1 FAILED at 31.
Hunk #2 FAILED at 45.
Hunk #3 FAILED at 108.
Hunk #4 FAILED at 210.
4 out of 4 hunks FAILED -- saving rejects to file
src/solrj/org/apache/solr/client/solrj/response/SpellCheckResponse.java.rej
(Stripping trailing CRs from patch.)
patching file
src/test/org/apache/solr/client/solrj/response/TestSpellCheckResponse.java
Hunk #1 FAILED at 23.
Hunk #2 FAILED at 109.
2 out of 2 hunks FAILED -- saving rejects to file
src/test/org/apache/solr/client/solrj/response/TestSpellCheckResponse.java.rej
(Stripping trailing CRs from patch.)
patching file src/test/org/apache/solr/spelling/SpellCheckCollatorTest.java
(Stripping trailing CRs from patch.)
patching file
src/test/org/apache/solr/spelling/SpellPossibilityIteratorTest.java
(Stripping trailing CRs from patch.)
patching file src/test/test-files/solr/conf/schema.xml
Hunk #1 FAILED at 19.
Hunk #2 FAILED at 50.
Hunk #3 FAILED at 100.
Hunk #4 FAILED at 408.
Hunk #5 FAILED at 427.
Hunk #6 FAILED at 453.
Hunk #7 FAILED at 535.
7 out of 7 hunks FAILED -- saving rejects to file
src/test/test-files/solr/conf/schema.xml.rej
(Stripping trailing CRs from patch.)
patching file src/test/test-files/solr/conf/solrconfig.xml
Hunk #1 FAILED at 29.
Hunk #2 FAILED at 116.
Hunk #3 FAILED at 340.
Hunk #4 FAILED at 396.
4 out of 4 hunks FAILED -- saving rejects to file
src/test/test-files/solr/conf/solrconfig.xml.rej


--
View this message in context: 
http://lucene.472066.n3.nabble.com/Patch-problems-solr-1-4-solr-2010-tp2898443p2898443.html
Sent from the Solr - User mailing 

RE: Patch problems solr 1.4 - solr-2010

2011-05-04 Thread Dyer, James
I also should mention that solr-2010 is incorporated in Solr 3.1, so if you can 
upgrade you won't need a patch.  Note, however, that you will still want to 
apply the fix in solr-2462 regardless of the version as this fix hasn't been 
committed anywhere.

James Dyer
E-Commerce Systems
Ingram Content Group
(615) 213-4311


-Original Message-
From: roySolr [mailto:royrutten1...@gmail.com] 
Sent: Wednesday, May 04, 2011 6:53 AM
To: solr-user@lucene.apache.org
Subject: Patch problems solr 1.4 - solr-2010

Hello,

I want to patch my solr installation(1.4.1) with
solr-2010.(https://issues.apache.org/jira/browse/SOLR-2010)

I need this feature:
Only return collations that are guaranteed to result in hits if re-queried 

Now i try the following code:

wget
https://issues.apache.org/jira/secure/attachment/12457683/SOLR-2010_141.patch
-O - | patch -p0  --dry-run

I get the following error message:

--13:51:35-- 
https://issues.apache.org/jira/secure/attachment/12457683/SOLR-2010_141.patch
Resolving issues.apache.org... 140.211.11.121
Connecting to issues.apache.org|140.211.11.121|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 55846 (55K) [text/x-patch]
Saving to: `STDOUT'

100%[]
55,846  59.3K/s   in 0.9s

13:51:37 (59.3 KB/s) - `-' saved [55846/55846]

(Stripping trailing CRs from patch.)
patching file src/common/org/apache/solr/common/params/SpellingParams.java
Hunk #1 FAILED at 81.
1 out of 1 hunk FAILED -- saving rejects to file
src/common/org/apache/solr/common/params/SpellingParams.java.rej
(Stripping trailing CRs from patch.)
patching file
src/java/org/apache/solr/handler/component/SpellCheckComponent.java
Hunk #1 FAILED at 24.
Hunk #2 FAILED at 141.
Hunk #3 FAILED at 155.
Hunk #4 FAILED at 214.
Hunk #5 FAILED at 252.
Hunk #6 FAILED at 262.
6 out of 6 hunks FAILED -- saving rejects to file
src/java/org/apache/solr/handler/component/SpellCheckComponent.java.rej
(Stripping trailing CRs from patch.)
patching file src/java/org/apache/solr/spelling/PossibilityIterator.java
(Stripping trailing CRs from patch.)
patching file src/java/org/apache/solr/spelling/RankedSpellPossibility.java
(Stripping trailing CRs from patch.)
patching file src/java/org/apache/solr/spelling/SpellCheckCollation.java
(Stripping trailing CRs from patch.)
patching file src/java/org/apache/solr/spelling/SpellCheckCollator.java
(Stripping trailing CRs from patch.)
patching file src/java/org/apache/solr/spelling/SpellCheckCorrection.java
(Stripping trailing CRs from patch.)
patching file
src/solrj/org/apache/solr/client/solrj/response/SpellCheckResponse.java
Hunk #1 FAILED at 31.
Hunk #2 FAILED at 45.
Hunk #3 FAILED at 108.
Hunk #4 FAILED at 210.
4 out of 4 hunks FAILED -- saving rejects to file
src/solrj/org/apache/solr/client/solrj/response/SpellCheckResponse.java.rej
(Stripping trailing CRs from patch.)
patching file
src/test/org/apache/solr/client/solrj/response/TestSpellCheckResponse.java
Hunk #1 FAILED at 23.
Hunk #2 FAILED at 109.
2 out of 2 hunks FAILED -- saving rejects to file
src/test/org/apache/solr/client/solrj/response/TestSpellCheckResponse.java.rej
(Stripping trailing CRs from patch.)
patching file src/test/org/apache/solr/spelling/SpellCheckCollatorTest.java
(Stripping trailing CRs from patch.)
patching file
src/test/org/apache/solr/spelling/SpellPossibilityIteratorTest.java
(Stripping trailing CRs from patch.)
patching file src/test/test-files/solr/conf/schema.xml
Hunk #1 FAILED at 19.
Hunk #2 FAILED at 50.
Hunk #3 FAILED at 100.
Hunk #4 FAILED at 408.
Hunk #5 FAILED at 427.
Hunk #6 FAILED at 453.
Hunk #7 FAILED at 535.
7 out of 7 hunks FAILED -- saving rejects to file
src/test/test-files/solr/conf/schema.xml.rej
(Stripping trailing CRs from patch.)
patching file src/test/test-files/solr/conf/solrconfig.xml
Hunk #1 FAILED at 29.
Hunk #2 FAILED at 116.
Hunk #3 FAILED at 340.
Hunk #4 FAILED at 396.
4 out of 4 hunks FAILED -- saving rejects to file
src/test/test-files/solr/conf/solrconfig.xml.rej


--
View this message in context: 
http://lucene.472066.n3.nabble.com/Patch-problems-solr-1-4-solr-2010-tp2898443p2898443.html
Sent from the Solr - User mailing list archive at Nabble.com.


Re: Patch problems solr 1.4 - solr-2010

2011-05-04 Thread Shawn Heisey

On 5/4/2011 8:50 AM, Dyer, James wrote:

I also should mention that solr-2010 is incorporated in Solr 3.1, so if you can 
upgrade you won't need a patch.  Note, however, that you will still want to 
apply the fix in solr-2462 regardless of the version as this fix hasn't been 
committed anywhere.


Found and fixed a problem with the patch against 3.1.  I have a fresh 
checkout of 3.1, with the 3x patch for SOLR-2469 applied.  The patch 
currently in SOLR-2462 will not apply cleanly.  I increased fuzz and 
ignored whitespace, which allowed it to apply, but then the build failed.


[javac] 
/opt/ncindex/src/lucene_solr_3_1/solr/src/java/org/apache/solr/spelling/SpellCheckCollator.java:80: 
cannot find symbol

[javac] symbol  : variable params
[javac] location: class org.apache.solr.spelling.SpellCheckCollator
[javac] 
params.set(CommonParams.TIME_ALLOWED, 50);


The fuzz and whitespace options added the new line to the wrong place -- 
before params was even defined/declared (whatever Java calls that).  I 
moved it to the right location according to the patch, and now it works.


I'll try to come up with a patch that works against 3.1 to put in the 
issue.  If that doesn't work out, I'll at least put a comment in it.


Thanks,
Shawn