You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Roland Tollenaar <rw...@gmail.com> on 2011/09/24 10:07:20 UTC

matching reponse and request

Hi,

sorry for this question but I am hoping it has a quick solution.

I am sending multiple get request queries to solr but solr is not 
returning the responses in the sequence I send the requests.

The shortest responses arrive back first....

I am wondering whether I can add a tag to the request which will be 
given back to me in the response so that when the response comes I can 
connect it to re original request and handle it in the appropriate manner.

If this is possible, how?

Help appreciated!

Regards,

Roland.

Re: matching reponse and request

Posted by Roland Tollenaar <rw...@gmail.com>.
Hi Otis,

thanks again for your help. This does sound right but I am not familiar 
enough with solr to venture into applying this.

I'll need something eventually if I want to use solr but maybe 1.5 will 
have it built in for me just when I need it. :)

Thanks,

RR

Otis Gospodnetic wrote:
> Hi Roland,
> 
> Have a look at hit #1 here: http://search-lucene.com/?q=manifoldcf&fc_project=Solr
> 
> I think this is what you are after.
> 
> Otis
> ----
> Sematext :: http://sematext.com/ :: Solr - Lucene - Nutch
> Lucene ecosystem search :: http://search-lucene.com/
> 
> 
>> ________________________________
>> From: Roland Tollenaar <rw...@gmail.com>
>> To: solr-user@lucene.apache.org
>> Sent: Sunday, September 25, 2011 4:24 AM
>> Subject: Re: matching reponse and request
>>
>> Hi Otis,
>>
>> this is absolutely brilliant! I did not think it were possible.
>>
>> It opens up a new possibility.
>>
>> If I insert device ID's in this manner (as in a unique identifier of the 
>> device sending the request) , might it be possible to control (at least 
>> block or permit) the permissions of the user?
>>
>> It seems like something of the sort is possible but I only come up with 
>> this:
>>
>> http://search-lucene.com/m/Yuib11zCeYN
>>
>> No redirect to where the permissions can be set (in schema) and how the 
>> requests are identified to come from a particular user/device......
>>
>> Thanks for your help.
>>
>> Kind regards,
>>
>> Roland
>>
>>
>> Otis Gospodnetic wrote:
>>> Hi Roland,
>>>
>>> Check this:
>>>
>>> <response>
>>> <lst name="responseHeader">
>>> <int name="status">0</int>
>>> <int name="QTime">0</int>
>>> <lst name="params">
>>> <str name="indent">on</str>
>>> <str name="start">0</str>
>>> <str name="q">solr</str>
>>> <str name="foo">1</str>            <=== from &foo=1
>>> <str name="version">2.2</str>
>>> <str name="rows">10</str>
>>> </lst>
>>>   
>>> I added &foo=1 to the request to Solr and got the above back.
>>>
>>> Otis
>>> ----
>>> Sematext :: http://sematext.com/ :: Solr - Lucene - Nutch
>>> Lucene ecosystem search :: http://search-lucene.com/
>>>
>>>
>>>
>>>
>>>> ________________________________
>>>> From: Roland Tollenaar <rw...@gmail.com>
>>>> To: solr-user@lucene.apache.org
>>>> Sent: Saturday, September 24, 2011 4:07 AM
>>>> Subject: matching reponse and request
>>>>
>>>> Hi,
>>>>
>>>> sorry for this question but I am hoping it has a quick solution.
>>>>
>>>> I am sending multiple get request queries to solr but solr is not returning the responses in the sequence I send the requests.
>>>>
>>>> The shortest responses arrive back first....
>>>>
>>>> I am wondering whether I can add a tag to the request which will be given back to me in the response so that when the response comes I can connect it to re original request and handle it in the appropriate manner.
>>>>
>>>> If this is possible, how?
>>>>
>>>> Help appreciated!
>>>>
>>>> Regards,
>>>>
>>>> Roland.
>>>>
>>>>
>>>>
>>
>>

Re: matching reponse and request

Posted by Otis Gospodnetic <ot...@yahoo.com>.
Hi Roland,

Have a look at hit #1 here: http://search-lucene.com/?q=manifoldcf&fc_project=Solr

I think this is what you are after.

Otis
----
Sematext :: http://sematext.com/ :: Solr - Lucene - Nutch
Lucene ecosystem search :: http://search-lucene.com/


>________________________________
>From: Roland Tollenaar <rw...@gmail.com>
>To: solr-user@lucene.apache.org
>Sent: Sunday, September 25, 2011 4:24 AM
>Subject: Re: matching reponse and request
>
>Hi Otis,
>
>this is absolutely brilliant! I did not think it were possible.
>
>It opens up a new possibility.
>
>If I insert device ID's in this manner (as in a unique identifier of the 
>device sending the request) , might it be possible to control (at least 
>block or permit) the permissions of the user?
>
>It seems like something of the sort is possible but I only come up with 
>this:
>
>http://search-lucene.com/m/Yuib11zCeYN
>
>No redirect to where the permissions can be set (in schema) and how the 
>requests are identified to come from a particular user/device......
>
>Thanks for your help.
>
>Kind regards,
>
>Roland
>
>
>Otis Gospodnetic wrote:
>> Hi Roland,
>> 
>> Check this:
>> 
>> <response>
>> <lst name="responseHeader">
>> <int name="status">0</int>
>> <int name="QTime">0</int>
>> <lst name="params">
>> <str name="indent">on</str>
>> <str name="start">0</str>
>> <str name="q">solr</str>
>> <str name="foo">1</str>            <=== from &foo=1
>> <str name="version">2.2</str>
>> <str name="rows">10</str>
>> </lst>
>>  
>> I added &foo=1 to the request to Solr and got the above back.
>> 
>> Otis
>> ----
>> Sematext :: http://sematext.com/ :: Solr - Lucene - Nutch
>> Lucene ecosystem search :: http://search-lucene.com/
>> 
>> 
>> 
>> 
>>> ________________________________
>>> From: Roland Tollenaar <rw...@gmail.com>
>>> To: solr-user@lucene.apache.org
>>> Sent: Saturday, September 24, 2011 4:07 AM
>>> Subject: matching reponse and request
>>>
>>> Hi,
>>>
>>> sorry for this question but I am hoping it has a quick solution.
>>>
>>> I am sending multiple get request queries to solr but solr is not returning the responses in the sequence I send the requests.
>>>
>>> The shortest responses arrive back first....
>>>
>>> I am wondering whether I can add a tag to the request which will be given back to me in the response so that when the response comes I can connect it to re original request and handle it in the appropriate manner.
>>>
>>> If this is possible, how?
>>>
>>> Help appreciated!
>>>
>>> Regards,
>>>
>>> Roland.
>>>
>>>
>>>
>
>
>

Re: matching reponse and request

Posted by Roland Tollenaar <rw...@gmail.com>.
Hi Otis,

this is absolutely brilliant! I did not think it were possible.

It opens up a new possibility.

If I insert device ID's in this manner (as in a unique identifier of the 
device sending the request) , might it be possible to control (at least 
block or permit) the permissions of the user?

It seems like something of the sort is possible but I only come up with 
this:

http://search-lucene.com/m/Yuib11zCeYN

No redirect to where the permissions can be set (in schema) and how the 
requests are identified to come from a particular user/device......

Thanks for your help.

Kind regards,

Roland


Otis Gospodnetic wrote:
> Hi Roland,
> 
> Check this:
> 
> <response>
> <lst name="responseHeader">
> <int name="status">0</int>
> <int name="QTime">0</int>
> <lst name="params">
> <str name="indent">on</str>
> <str name="start">0</str>
> <str name="q">solr</str>
> <str name="foo">1</str>            <=== from &foo=1
> <str name="version">2.2</str>
> <str name="rows">10</str>
> </lst>
>  
> I added &foo=1 to the request to Solr and got the above back.
> 
> Otis
> ----
> Sematext :: http://sematext.com/ :: Solr - Lucene - Nutch
> Lucene ecosystem search :: http://search-lucene.com/
> 
> 
> 
> 
>> ________________________________
>> From: Roland Tollenaar <rw...@gmail.com>
>> To: solr-user@lucene.apache.org
>> Sent: Saturday, September 24, 2011 4:07 AM
>> Subject: matching reponse and request
>>
>> Hi,
>>
>> sorry for this question but I am hoping it has a quick solution.
>>
>> I am sending multiple get request queries to solr but solr is not returning the responses in the sequence I send the requests.
>>
>> The shortest responses arrive back first....
>>
>> I am wondering whether I can add a tag to the request which will be given back to me in the response so that when the response comes I can connect it to re original request and handle it in the appropriate manner.
>>
>> If this is possible, how?
>>
>> Help appreciated!
>>
>> Regards,
>>
>> Roland.
>>
>>
>>

Re: matching reponse and request

Posted by Otis Gospodnetic <ot...@yahoo.com>.
Hi Roland,

Check this:

<response>
<lst name="responseHeader">
<int name="status">0</int>
<int name="QTime">0</int>
<lst name="params">
<str name="indent">on</str>
<str name="start">0</str>
<str name="q">solr</str>
<str name="foo">1</str>            <=== from &foo=1
<str name="version">2.2</str>
<str name="rows">10</str>
</lst>
 
I added &foo=1 to the request to Solr and got the above back.

Otis
----
Sematext :: http://sematext.com/ :: Solr - Lucene - Nutch
Lucene ecosystem search :: http://search-lucene.com/




>________________________________
>From: Roland Tollenaar <rw...@gmail.com>
>To: solr-user@lucene.apache.org
>Sent: Saturday, September 24, 2011 4:07 AM
>Subject: matching reponse and request
>
>Hi,
>
>sorry for this question but I am hoping it has a quick solution.
>
>I am sending multiple get request queries to solr but solr is not returning the responses in the sequence I send the requests.
>
>The shortest responses arrive back first....
>
>I am wondering whether I can add a tag to the request which will be given back to me in the response so that when the response comes I can connect it to re original request and handle it in the appropriate manner.
>
>If this is possible, how?
>
>Help appreciated!
>
>Regards,
>
>Roland.
>
>
>

Re: matching reponse and request

Posted by Roland Tollenaar <rw...@gmail.com>.
Hi,

actually your are right in the sense that this should be sorted out a 
layer level lower. I.e. server-client connection level. Done that as well.

Thanks for the response.

Regards,

Roland

rkuris wrote:
> I don't think you can do this.
> 
> If you are sending multiple GET requests, you are doing it across different
> HTTP connections.  The web service has no way of knowing these are related.
> 
> One solution would be to pass a spare, unused parameter to your request,
> like sequenceId=NNN and get the response to echo that back.  Then at least
> you can tell which one is coming back and fix the order up in your program.
> 
> 
> --
> View this message in context: http://lucene.472066.n3.nabble.com/matching-reponse-and-request-tp3363976p3364816.html
> Sent from the Solr - User mailing list archive at Nabble.com.
> 

Re: matching reponse and request

Posted by rkuris <sw...@gmail.com>.
I don't think you can do this.

If you are sending multiple GET requests, you are doing it across different
HTTP connections.  The web service has no way of knowing these are related.

One solution would be to pass a spare, unused parameter to your request,
like sequenceId=NNN and get the response to echo that back.  Then at least
you can tell which one is coming back and fix the order up in your program.


--
View this message in context: http://lucene.472066.n3.nabble.com/matching-reponse-and-request-tp3363976p3364816.html
Sent from the Solr - User mailing list archive at Nabble.com.