Closed (fixed)
Project:
Apache Solr Search
Version:
7.x-1.x-dev
Component:
Code
Priority:
Major
Category:
Support request
Assigned:
Reporter:
Created:
3 Sep 2010 at 11:43 UTC
Updated:
14 Oct 2011 at 02:11 UTC
Jump to comment: Most recent file
Comments
Comment #1
robertdouglass commentedI cannot reproduce this bug on my local setup. If I index a node with the word testøåæxxx, I can search for this word in the title, in the body text, and even get spelling suggestions for words including these characters. Maybe share a bit more about your environment. Is the whole stack operating on UTF8? Do you have the mbstring libraries installed for PHP?
Comment #2
damien tournoud commentedThat said, why is there a utf8_decode() in there?
EDIT: ok, I understand now that the patch is reversed.
Comment #3
damien tournoud commentedComment #4
robertdouglass commentedI believe there is a bug here because you cannot search for the example word on Drupal.org.
http://drupal.org/search/apachesolr_search/test%C3%B8%C3%A5%C3%A6xxx
Yet the node is discoverable through the text in the comment:
http://drupal.org/search/apachesolr_search/%22whole%20stack%20operating%...
Comment #5
robertdouglass commentedOh, take it back. It was just a quirk of Drupal.org that it didn't show up the first time. Now it does.
Comment #6
Daemon_Byte commentedYeh I was wondering if it was perhaps just my set-up as I would have thought such a thing wouldn't have gone undetected. We have a lot of nodes in drupal with utf8 characters, the apachesolr module and yes mb_strings is installed. I am not sure why the patch fixes my installation however I will post examples of the solr url the module generates both before and after the patch tomorrow.
Comment #7
Daemon_Byte commentedThe URL is looking correct today but it is still not searching without the decode. I can't figure out why the utf8 characters get messed up.
This is the response I get from solr without the patch
This is the response I get from solr with the patch
Comment #8
wmostrey commentedRobert, are you running Solr on Tomcat?
Comment #9
Daemon_Byte commentedYeh it was running under tomcat 6 but recently it has moved to tomcat 7.
Comment #10
wmostrey commentedThen you probably simply need to set up Tomcat correctly: Configuring Tomcat to provide UTF-8 support for Solr
In summary, adjust server.xml:
URIEncoding="UTF-8"to the correct ConnectoruseBodyEncodingForURIfrom that ConnectorComment #11
Daemon_Byte commentedOh of course! I forgot to change that when I set up 7. That explains everything, thanks :)
Comment #12
LiuShaz commentedURIEncoding="UTF-8"- works only with GET method, POST method works not properly!!!Apache Solr Integration 6.x-1.5 -> Drupal_Apache_Solr_Service.php
Why I can't administer
apachesolr_search_post_thresholdvalue?apachesolr_search_post_threshold (by default 4000) = maxHttpHeaderSize (in tomcat server.xml, by default 8192)
Comment #13
LiuShaz commentedAfter lot hours of hard debugging I found small mistake! More details in .patch file.
Comment #14
anavarreSubscribe
Comment #15
nick_vhI tried to reproduce this issue on the D7 version and so far I can't seem to reproduce it. If someone else can confirm this patch works then we might be able to confirm? To enforce the POST submission of the search request you can simply change the little check in the Drupal_Apache_Solr_Service.php
Comment #16
pwolanin commentedthis issue to a dup of this one: #1289400: [Drupal_Apache_Solr_Service] Wrong encoding with Greek when it gets send with _sendRawPost insted of _sendRawGet
Comment #17
dropbydrop commented+1
Comment #19
pwolanin commentedcommitted fix to 6.x-1.x and 6.x-2.x.
Here's the corresponding 7.x-1.x fix.
Comment #20
pwolanin commentedcommitted