Community @ The Turning Gate

Support community for TTG plugins and products.

NOTICE

The Turning Gate's Community has moved to a new home, at https://discourse.theturninggate.net.

This forum is now closed, and exists here as a read-only archive.

  • New user registrations are disabled.
  • Users cannot create new topics.
  • Users cannot reply to existing topics.

You are not logged in.

#1 2014-12-04 20:47:26

xevigut
Member
Registered: 2013-02-01
Posts: 58

error message in "search"

I had this error message in my Search field:

Fatal error: Maximum execution time of 30 seconds exceeded in /usr/home/xevivilaregut.com/web/ttg-be/framework/dao/PdoExtended.php on line 529


My side: http://www.xevivilaregut.com/search/index.php

Offline

#2 2014-12-09 07:30:55

rod barbee
Moderator
From: Port Ludlow, WA USA
Registered: 2012-09-24
Posts: 17,830
Website

Re: error message in "search"

just bumping this. Can you enable guest access to ttg-be so Ben can take a look when he gets a chance.


Rod 
Just a user with way too much time on his hands.
www.rodbarbee.com
ttg-tips.com, Backlight 2/3 test site

Offline

#3 2014-12-09 09:04:03

Ben
Moderator
From: Melbourne, Australia
Registered: 2012-09-29
Posts: 4,399

Re: error message in "search"

The search is taking too long. This is a factor of the number of photos in the database and the efficiency of the search queries. Roughly how many albums and photos do you have?

I have made improvements to the queries in my working code that should significantly reduce the query time. However the next Publisher update is tied to the CRG CE4 release. When I have the details handy I'll post some steps to improve the search time.

Offline

#4 2014-12-10 19:38:26

Ben
Moderator
From: Melbourne, Australia
Registered: 2012-09-29
Posts: 4,399

Re: error message in "search"

Here's my tip to improve search time:

1) Login to TTG BE as full admin
2) On the TTG BE Dashboard, click 'phpLiteAdmin' under 'Special Links'
3) Enter the additional password of 'admin'
4) On the left-hand side, click 'publisher/master.sq3'
5) Click on the SQL tab
6) In the large text area, paste the following code:

drop index photo_metadata_name_index

7) Click 'Go'

I can do the above for you if you find those steps are intimidating.  In that case, please email or message me your TTG BE admin login.

An explanation of the above: Database indexes are used to speed up queries on fields that are frequently searched.  The index that we're removing was meant to speed up searches for metadata named 'caption'.  Unfortunately, in this case, the optimisation had the opposite affect, and drastically slowed down queries for captions.  I am assuming this is because indexes work best for unique values (such as the name holding email addresses), and not for repeated values, such as the name being 'caption', which are far from unique.  While each photo has a unique ID, every photo has metadata named 'caption'.  The index just doesn't work well in that case.

Note that the removal of the index will be included in the next Publisher upgrade, due in the new year.  So if you don't remove it now, it will be removed when the Publisher is updated.

Offline

Board footer

Powered by FluxBB