Hi,

I am trying to implement a cocoon based application using solr for searching.
In particular, I would like to forward the request from my response page to
solr.  I have tried several alternatives, but none of them worked for me.

One which would seem a logical way to me is to have response page, which is
forwarded to solr with cocoon's file generator.  It works fine if I perform
queries which contain only alphanumeric characters, but it gives the following
error if I try to query for a string containing nonalphanum characters:

http://hostname/cocoon/mywebapp/response?q=a+b

java.io.IOException: Server returned HTTP response code: 505 for URL:
http://hostname/solr/select/?q=a b


The interesting thing is that if I access http://hostname/solr/select/?q=a b
directly it works.


The relevant part of my sitemap.xmap:

<map:match pattern="response">
  <map:generate
    src="http://hostname/solr/select/?q={request-param:q}";
    type="file" >
  </map:generate>
  <map:serialize type="xml"/>
</map:match>

Any ideas on how to implement a cocoon layer above solr?

thanks,
mirko

ps. I realize this question might be more of a cocoon question, but I am
posting it here because I have gotten the idea from
http://wiki.apache.org/solr/XsltResponseWriter to use cocoon on top of solr) 
So, I assume some of you have already had run into similar issues and/or knows
the solution...

Reply via email to