List Info

Thread: PHP/YAZ persistent connections




PHP/YAZ persistent connections
user name
2006-03-22 08:38:54
What are the reasons for having persistent connections in
PHP/YAZ?

--
Rustam Usmanov, systems engineer
Institute of Consortia Library Information Systems,
St.Petersburg State Polytechnic University
Address:  29, Politekhnitcheskaya str., St.Petersburg,
195251, Russia
Tel/fax: +7 812 552 7654        <URL:http://www.unilib
.neva.ru/olsc/>

_______________________________________________
Yazlist mailing list
Yazlistlists.indexdata.dk
http://lists.indexdata.dk/cgi-bin/mailman/listinfo/yaz
list
PHP/YAZ persistent connections
user name
2006-03-22 09:06:29
Rustam T. Usmanov wrote:
> What are the reasons for having persistent connections
in PHP/YAZ?
Share Z39.50 sessions between users.

/ Adam

> 
> --
> Rustam Usmanov, systems engineer
> Institute of Consortia Library Information Systems,
> St.Petersburg State Polytechnic University
> Address:  29, Politekhnitcheskaya str., St.Petersburg,
195251, Russia
> Tel/fax: +7 812 552 7654        <URL:http://www.unilib
.neva.ru/olsc/>
> 
> _______________________________________________
> Yazlist mailing list
> Yazlistlists.indexdata.dk
> http://lists.indexdata.dk/cgi-bin/mailman/listinfo/yaz
list
> 


_______________________________________________
Yazlist mailing list
Yazlistlists.indexdata.dk
http://lists.indexdata.dk/cgi-bin/mailman/listinfo/yaz
list
PHP/YAZ persistent connections
user name
2006-03-22 09:37:23
On Wed, 22 Mar 2006, Adam Dickmeiss wrote:

> Rustam T. Usmanov wrote:
> > What are the reasons for having persistent
connections in PHP/YAZ?
> Share Z39.50 sessions between users.
And nothing else?

Is there any way to keep state between sequential
yaz_present() calls?
For example, 1000 records were found and we need to have
paged output by
20 records with ability to interactively retrieve next or
previous 20
records. Obvious way is to perform yaz_connect(), ... ,
yaz_search(), ...,
yaz_record() sequence of calls for every portion of records.
But it seems
to me that this solution is quite ineffective. If we could
make one
yaz_search() and N times yaz_present() within the same
connection
resource...

--
Rustam Usmanov, systems engineer
Institute of Consortia Library Information Systems,
St.Petersburg State Polytechnic University
Address:  29, Politekhnitcheskaya str., St.Petersburg,
195251, Russia
Tel/fax: +7 812 552 7654        <URL:http://www.unilib
.neva.ru/olsc/>

_______________________________________________
Yazlist mailing list
Yazlistlists.indexdata.dk
http://lists.indexdata.dk/cgi-bin/mailman/listinfo/yaz
list
PHP/YAZ persistent connections
user name
2006-03-22 09:56:32
Rustam T. Usmanov wrote:
> On Wed, 22 Mar 2006, Adam Dickmeiss wrote:
> 
> 
>>Rustam T. Usmanov wrote:
>>
>>>What are the reasons for having persistent
connections in PHP/YAZ?
>>
>>Share Z39.50 sessions between users.
> 
> And nothing else?
Well. That was not the whole story.
> 
> Is there any way to keep state between sequential
yaz_present() calls?
> For example, 1000 records were found and we need to
have paged output by
> 20 records with ability to interactively retrieve next
or previous 20
> records. Obvious way is to perform yaz_connect(), ... ,
yaz_search(), ...,
> yaz_record() sequence of calls for every portion of
records. But it seems
> to me that this solution is quite ineffective. If we
could make one
> yaz_search() and N times yaz_present() within the same
connection
> resource...

For web environements like Apache we don't know which
process is being 
used.. And so the change of same user using the same
connection and be 
able to use old results is slim.. You have a better
"hit rate" with 
Apache 2 in threaded mode.. And even better, still, if you
use 
yaz_connect cookie + yazproxy - one user will get the same
Z39.50 
connection behind the scences - regardless of process-model
for Apache.

/ Adam

> --
> Rustam Usmanov, systems engineer
> Institute of Consortia Library Information Systems,
> St.Petersburg State Polytechnic University
> Address:  29, Politekhnitcheskaya str., St.Petersburg,
195251, Russia
> Tel/fax: +7 812 552 7654        <URL:http://www.unilib
.neva.ru/olsc/>
> 
> _______________________________________________
> Yazlist mailing list
> Yazlistlists.indexdata.dk
> http://lists.indexdata.dk/cgi-bin/mailman/listinfo/yaz
list
> 


_______________________________________________
Yazlist mailing list
Yazlistlists.indexdata.dk
http://lists.indexdata.dk/cgi-bin/mailman/listinfo/yaz
list
PHP/YAZ persistent connections
user name
2006-03-22 11:02:33
On Wed, 22 Mar 2006, Adam Dickmeiss wrote:

> For web environements like Apache we don't know which
process is being
> used.. And so the change of same user using the same
connection and be
> able to use old results is slim.. You have a better
"hit rate" with
> Apache 2 in threaded mode.. And even better, still, if
you use
> yaz_connect cookie + yazproxy - one user will get the
same Z39.50
> connection behind the scences - regardless of
process-model for Apache.

Yes, I suspected that yazproxy will help to obtain earlier
established
connection. But will it help to get rid of necessity to
repeat search?

--
Rustam Usmanov, systems engineer
Institute of Consortia Library Information Systems,
St.Petersburg State Polytechnic University
Address:  29, Politekhnitcheskaya str., St.Petersburg,
195251, Russia
Tel/fax: +7 812 552 7654        <URL:http://www.unilib
.neva.ru/olsc/>

_______________________________________________
Yazlist mailing list
Yazlistlists.indexdata.dk
http://lists.indexdata.dk/cgi-bin/mailman/listinfo/yaz
list
PHP/YAZ persistent connections
user name
2006-03-22 12:11:53
Rustam T. Usmanov wrote:
> On Wed, 22 Mar 2006, Adam Dickmeiss wrote:
> 
> 
>>For web environements like Apache we don't know
which process is being
>>used.. And so the change of same user using the same
connection and be
>>able to use old results is slim.. You have a better
"hit rate" with
>>Apache 2 in threaded mode.. And even better, still,
if you use
>>yaz_connect cookie + yazproxy - one user will get
the same Z39.50
>>connection behind the scences - regardless of
process-model for Apache.
> 
> 
> Yes, I suspected that yazproxy will help to obtain
earlier established
> connection. But will it help to get rid of necessity to
repeat search?
Yes. It matches the query against previous one . If matched,
the result 
set will be re-used.

/ Adam

> 
> --
> Rustam Usmanov, systems engineer
> Institute of Consortia Library Information Systems,
> St.Petersburg State Polytechnic University
> Address:  29, Politekhnitcheskaya str., St.Petersburg,
195251, Russia
> Tel/fax: +7 812 552 7654        <URL:http://www.unilib
.neva.ru/olsc/>
> 
> _______________________________________________
> Yazlist mailing list
> Yazlistlists.indexdata.dk
> http://lists.indexdata.dk/cgi-bin/mailman/listinfo/yaz
list
> 


_______________________________________________
Yazlist mailing list
Yazlistlists.indexdata.dk
http://lists.indexdata.dk/cgi-bin/mailman/listinfo/yaz
list
PHP/YAZ persistent connections
user name
2006-03-23 03:20:39
On Wed, Mar 22, 2006 at 01:11:53PM +0100, Adam Dickmeiss
wrote:
> Rustam T. Usmanov wrote:
> >On Wed, 22 Mar 2006, Adam Dickmeiss wrote:
> >
> >
> >>For web environements like Apache we don't
know which process is being
> >>used.. And so the change of same user using the
same connection and be
> >>able to use old results is slim.. You have a
better "hit rate" with
> >>Apache 2 in threaded mode.. And even better,
still, if you use
> >>yaz_connect cookie + yazproxy - one user will
get the same Z39.50
> >>connection behind the scences - regardless of
process-model for Apache.
> >
> >
> >Yes, I suspected that yazproxy will help to obtain
earlier established
> >connection. But will it help to get rid of
necessity to repeat search?
> Yes. It matches the query against previous one . If
matched, the result 
> set will be re-used.

A little bit more. The result set will be re-used if client
of yazproxy does
not use character set negotiation (tag - negotiaton-charset
in config file).
I see, there are ways to make better behaviour yazproxy, but
it not fixed
still.

Oleg

> 
> / Adam
> 
> >
> >--
> >Rustam Usmanov, systems engineer
> >Institute of Consortia Library Information Systems,
> >St.Petersburg State Polytechnic University
> >Address:  29, Politekhnitcheskaya str.,
St.Petersburg, 195251, Russia
> >Tel/fax: +7 812 552 7654        <URL:http://www.unilib
.neva.ru/olsc/>
> >
> >_______________________________________________
> >Yazlist mailing list
> >Yazlistlists.indexdata.dk
> >http://lists.indexdata.dk/cgi-bin/mailman/listinfo/yaz
list
> >
> 
> 
> _______________________________________________
> Yazlist mailing list
> Yazlistlists.indexdata.dk
> http://lists.indexdata.dk/cgi-bin/mailman/listinfo/yaz
list

-- 
Oleg Kolobov                              | oleg (at)
lib.tpu.ru

_______________________________________________
Yazlist mailing list
Yazlistlists.indexdata.dk
http://lists.indexdata.dk/cgi-bin/mailman/listinfo/yaz
list
PHP/YAZ persistent connections
user name
2006-03-23 06:15:44
Oleg Kolobov wrote:
> On Wed, Mar 22, 2006 at 01:11:53PM +0100, Adam
Dickmeiss wrote:
> 
>>Rustam T. Usmanov wrote:
>>
>>>On Wed, 22 Mar 2006, Adam Dickmeiss wrote:
>>>
>>>
>>>
>>>>For web environements like Apache we don't
know which process is being
>>>>used.. And so the change of same user using
the same connection and be
>>>>able to use old results is slim.. You have a
better "hit rate" with
>>>>Apache 2 in threaded mode.. And even better,
still, if you use
>>>>yaz_connect cookie + yazproxy - one user
will get the same Z39.50
>>>>connection behind the scences - regardless
of process-model for Apache.
>>>
>>>
>>>Yes, I suspected that yazproxy will help to
obtain earlier established
>>>connection. But will it help to get rid of
necessity to repeat search?
>>
>>Yes. It matches the query against previous one . If
matched, the result 
>>set will be re-used.
> 
> 
> A little bit more. The result set will be re-used if
client of yazproxy does
> not use character set negotiation (tag -
negotiaton-charset in config file).
> I see, there are ways to make better behaviour
yazproxy, but it not fixed
> still.
Yep. There is a similar problem with authentication. Have a
working 
yazproxy that matches authenticiation now (not offcial).
Working on 
getting the charset working too (so that clients all using
same charset 
share same connections..).

/ Adam

> 
> Oleg
> 
> 
>>/ Adam
>>
>>
>>>--
>>>Rustam Usmanov, systems engineer
>>>Institute of Consortia Library Information
Systems,
>>>St.Petersburg State Polytechnic University
>>>Address:  29, Politekhnitcheskaya str.,
St.Petersburg, 195251, Russia
>>>Tel/fax: +7 812 552 7654        <URL:http://www.unilib
.neva.ru/olsc/>
>>>
>>>_______________________________________________
>>>Yazlist mailing list
>>>Yazlistlists.indexdata.dk
>>>http://lists.indexdata.dk/cgi-bin/mailman/listinfo/yaz
list
>>>
>>
>>
>>_______________________________________________
>>Yazlist mailing list
>>Yazlistlists.indexdata.dk
>>http://lists.indexdata.dk/cgi-bin/mailman/listinfo/yaz
list
> 
> 


_______________________________________________
Yazlist mailing list
Yazlistlists.indexdata.dk
http://lists.indexdata.dk/cgi-bin/mailman/listinfo/yaz
list
[1-8]

about | contact  Other archives ( Real Estate discussion Medical topics )