[ic] Very slow [search-region] page

marco m.mescoli at omnib.it
Wed Sep 14 06:43:36 UTC 2011


Il 14/09/2011 08:24, Stefan Hornburg (Racke) ha scritto:
> On 09/13/2011 09:33 PM, Sam Batschelet wrote:
>>
>> On Sep 13, 2011, at 12:03 PM, marco wrote:
>>
>>> An old page with minivend search become very slow. The query is from
>>> only one mysql table products (159 fields and about 6000 records).
>>>
>>> The first result page 1..10 items is quick (3s):
>>> url=cgi-bin/elcat/carr.html?mv_arg=&id=3nqtfXVE&anag=&tecn=&stor=&prez=1&stop=1
>>>
>>>
>>> All the other subpages 11 .. 20, 21..30 etc etc are very slow (16s)
>>> each:
>>> url=cgi-bin/elcat/scan/MM=2a79e8aa45e82fb7361be8a2c995622a:10:19:10.html?mv_more_ip=1&mv_nextpage=carr&mv_arg=&id=3nqtfXVE&field_tf=&field_tf_val=&coord=&reverse=&order_to=&substring=&anag=&tecn=&stor=&prez=1&stop=1
>>>
>>>
>>> If i put 60 items for page i get "Internal Server Error", the
>>> error.log of interchange say:elcat - hammered pid 12644 running 300
>>> seconds
>>> and without errors on catalogue error.log
>>
>> Not sure on the query load time but check out Jobs MaxLifetime located
>> in your interchange.cfg file. Increasing this value will allow the
>> query to run for a longer time.
>>
>> http://www.icdevgroup.org/docs/confs/Jobs.html
>
> Jobs MaxLifetime is only for Interchange jobs (e.g. run by interchange
> --runjobs=...). PIDcheck is for normal Interchange requests,
> but I doubt that users are patient enough to wait for that long.
>
> Marco, please post the body of your search-region to give us a better
> chance to help you with this problem.
>
> Regards
> Racke
>

Ok :-)

[if !scratch port_search]
   [search-region more=1
     search="
     st=db
     ml=[scratch per_pag]
     [if cgi coord]
       co=yes
       sf=[scratch field_tf]
       se=[cgi field_tf_val]
     [else]
     co=no
     [/else]
     [/if]
     [if cgi substring eq 'yes']
     su=yes
     [/if]
     os=1
     sf=elcar
     se=S
     os=1
     sf=ELC_CODICE_CT
     se=VFS

     tf=[scratch field_tf] [if scratch field_tf],[/if] [if scratch 
field_tf eq 'ELC_CODICE_CLI']ELC_NOTE_DES ,[/if] ELC_PORTATA:rn ,ELC_ANNO:rn
     to=[scratch reverse][scratch order_to]
   "]
[else]
   [search-region more=1
     search="
     st=db
     ml=[scratch per_pag]
     co=yes

     sf=ELC_PORTATA
     se=[scratch min]
     op=ge
     nu=1
     ne=no

     sf=ELC_PORTATA
     se=[scratch max]
     op=le
     nu=1
     ne=no

     os=1
     sf=elcar
     se=S
     os=1
     sf=ELC_CODICE_CT
     se=VFS

     tf=ELC_PORTATA:rn ,ELC_ANNO:rn
   "]
[/else][/if]

[link-template]<a href="$URL$&id=[data session id]&field_tf=[cgi 
field_tf]&field_tf_val=[cgi field_tf_val]&coord=[cgi coord]&reverse=[cgi 
reverse]&order_to=[cgi order_to]&substring=[cgi substring]&anag=[cgi 
anag]&tecn=[cgi tecn]&stor=[cgi stor]&prez=[cgi 
prez]&stop=1">$ANCHOR$</a>[/link-template]

-- 
Marco "Fino alla bara sinpara"
Marco "Up to demise we rise"



More information about the interchange-users mailing list