Joomla JTable $row->store() unbearably slow

This forum is for general questions about extensions for Joomla! 3.x.

Moderators: pe7er, General Support Moderators

Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Windows Defender SmartScreen Issues <-- please read this if using Windows 10.
Locked
User avatar
itwhizzkid99
Joomla! Apprentice
Joomla! Apprentice
Posts: 20
Joined: Mon Jun 27, 2011 5:24 pm
Location: London, UK
Contact:

Joomla JTable $row->store() unbearably slow

Post by itwhizzkid99 » Tue Oct 02, 2012 1:23 am

I have a wierd issue. I'm running Joomla 3.0 on WAMP for testing, and I'm trying to insert some rows into my menu table using a custom plugin.

The table only has the dummy Joomla data - i.e. less than 100 rows.

My code is very standard (see below).

I have narrowed down the issue to the $row->store(); line - if I allow this to run the system becomes unresponsive for about 60 seconds or more, with just a single insert.

If I comment out the store() line, the script runs very fast, but doesn't save the data (obviously).

Is there any easy way to speed up the store() function? I can't imagine what the problem might be. This is a brand new install of the new Joomla 3.0 & everything else runs fine.

$array = array(
'id' => $data['id'],
'menutype' => 'mymenu',
'title' => $data['title'],
'alias' => $data['alias'],
'link' => $data['link'],
'type' => 'component',
'published' => $data['published'],
'parent_id' => $data['parent'],
'level' => $data['level'],
'component_id' => 22,
'access' => $data['access'],
'language' => $data['language']
);
$row = & JTable::getInstance('menu');
if($row->bind($array)) {
$row->store();
}
$row->rebuild();

 
User avatar
TSX-Today
I've been banned!
Posts: 57
Joined: Wed Dec 19, 2012 6:56 pm
Location: Vancouver, BC, Canada
Contact:

Re: Joomla JTable $row->store() unbearably slow

Post by TSX-Today » Tue Apr 16, 2013 7:06 am

I am not sure if it is the same issue, but I had a similar problem. In my case it had to do with slow queries issues.
My SEO Website at SEO Vancouver http://www.seoinvancouver.com/
TSX Today http://www.tsx-today.com/, ranks one Page #1 in Bing and Yahoo for super competitive keyword: TSX, with over 500,000 searches per month

 

Locked

Return to “Extensions for Joomla! 3.x”