Time taken to open ticket history

RT 3.8.4

Does anyone have any suggestions on how to improve the time taken for RT to display ticket history. Depending on the number of entries on the ticket it can take 6-30seconds to render the ticket.

I’ve had a look in the mysql logs for slow queries and can’t see any (though it’s only logging ones that take longer than 1s so maybe it’s doing lots and lots of faster ones that can still be optimised).

I’ve put some debug logging in and all the time is going in ShowHistory, so I guess in the loop that loops over all the various transactions and things to display for that ticket.

Any suggestions or tweaks that people have done would be great, before I start investigating what’s going on at a lower level.

Thanks,

Justin

Justin Hayes
Orbis Support Manager
justin.hayes@orbisuk.com

Hi Justin,

The last time I looked at this problem, the slow step is simply
preparing all of the transactions for the web. The biggest gains
were made by pruning the list of displayed transactions to the
bare minimum, by default. Then have a button to allow seeing
all of the transactions, if needed.

Regards,
KenOn Thu, Jun 03, 2010 at 09:27:45AM +0100, Justin Hayes wrote:

RT 3.8.4

Does anyone have any suggestions on how to improve the time taken for RT to display ticket history. Depending on the number of entries on the ticket it can take 6-30seconds to render the ticket.

I’ve had a look in the mysql logs for slow queries and can’t see any (though it’s only logging ones that take longer than 1s so maybe it’s doing lots and lots of faster ones that can still be optimised).

I’ve put some debug logging in and all the time is going in ShowHistory, so I guess in the loop that loops over all the various transactions and things to display for that ticket.

Any suggestions or tweaks that people have done would be great, before I start investigating what’s going on at a lower level.

Thanks,

Justin

Ken,

Is there a patch out there that does this? Hiding some of the extraneous
txns is something I was thinking of doing as well.

Thanks,
Brian

Hi Justin,

The last time I looked at this problem, the slow step is simply
preparing all of the transactions for the web. The biggest gains
were made by pruning the list of displayed transactions to the
bare minimum, by default. Then have a button to allow seeing
all of the transactions, if needed.

Regards,
KenOn Thu, Jun 03, 2010 at 09:27:45AM +0100, Justin Hayes wrote:

RT 3.8.4

Does anyone have any …

Discover RT’s hidden secrets with RT Essentials from O’Reilly Media.
Buy a copy at http://rtbook.bes

Hi,

just try out my extension:

ChrisAm 08.06.2010 01:31, schrieb Brian D:

Ken,

Is there a patch out there that does this? Hiding some of the
extraneous txns is something I was thinking of doing as well.

Thanks,
Brian

On Jun 7, 2010 4:53 PM, “Kenneth Marshall” <ktm@rice.edu mailto:ktm@rice.edu> wrote:

Hi Justin,

The last time I looked at this problem, the slow step is simply
preparing all of the transactions for the web. The biggest gains
were made by pruning the list of displayed transactions to the
bare minimum, by default. Then have a button to allow seeing
all of the transactions, if needed.

Regards,
Ken

On Thu, Jun 03, 2010 at 09:27:45AM +0100, Justin Hayes wrote:

RT 3.8.4

Does anyone have any …

Discover RT’s hidden secrets with RT Essentials from O’Reilly Media.
Buy a copy at http://rtbook.bes

Discover RT’s hidden secrets with RT Essentials from O’Reilly Media.
Buy a copy at http://rtbook.bestpractical.com

You’d want to prune at the DB query level though I’d have thought? Otherwise it still has to loop over everything to decide whether or not to show things.

I’m already doing this (my Display doesnt show quite a lot compared to History) but there’s not much speed difference.

Perhaps I’m pruning at too high a level in the code?

Thanks,

Justin

Justin Hayes
Orbis Support Manager
justin.hayes@orbisuk.comOn 7 Jun 2010, at 21:53, Kenneth Marshall wrote:

Hi Justin,

The last time I looked at this problem, the slow step is simply
preparing all of the transactions for the web. The biggest gains
were made by pruning the list of displayed transactions to the
bare minimum, by default. Then have a button to allow seeing
all of the transactions, if needed.

Regards,
Ken

On Thu, Jun 03, 2010 at 09:27:45AM +0100, Justin Hayes wrote:

RT 3.8.4

Does anyone have any suggestions on how to improve the time taken for RT to display ticket history. Depending on the number of entries on the ticket it can take 6-30seconds to render the ticket.

I’ve had a look in the mysql logs for slow queries and can’t see any (though it’s only logging ones that take longer than 1s so maybe it’s doing lots and lots of faster ones that can still be optimised).

I’ve put some debug logging in and all the time is going in ShowHistory, so I guess in the loop that loops over all the various transactions and things to display for that ticket.

Any suggestions or tweaks that people have done would be great, before I start investigating what’s going on at a lower level.

Thanks,

Justin

I’m using a SkipTransation callback in ShowHistory that does something like

<%init>
my $ttype;
$ttype = $Transaction->Type;
$$skip = 1 if (($_SkipSystemMessages) && ((($Transaction->Creator eq RT->Config->Get(‘SystemUserID’))
&& ($Transaction->Type ne ‘Status’)
&& ($Transaction->Type ne ‘Comment’)) || (($Transaction->Creator eq RT->Config->Get(‘CronUserID’))
&& (($Transaction->Type ne ‘Give’)
&& ($Transaction->Type ne ‘Correspond’))) || ($Transaction->Type eq ‘CustomField’) || ($Transaction->Type eq ‘Set’
&& $Transaction->Field eq ‘TimeWorked’)) );
my $type = $Transaction->Type;
</%init>

But I guess it’s too late at this point for performance reasons, as we’re already processing the entry?

Justin

Justin Hayes
Orbis Support Manager
justin.hayes@orbisuk.comOn 7 Jun 2010, at 21:53, Kenneth Marshall wrote:

Hi Justin,

The last time I looked at this problem, the slow step is simply
preparing all of the transactions for the web. The biggest gains
were made by pruning the list of displayed transactions to the
bare minimum, by default. Then have a button to allow seeing
all of the transactions, if needed.

Regards,
Ken

On Thu, Jun 03, 2010 at 09:27:45AM +0100, Justin Hayes wrote:

RT 3.8.4

Does anyone have any suggestions on how to improve the time taken for RT to display ticket history. Depending on the number of entries on the ticket it can take 6-30seconds to render the ticket.

I’ve had a look in the mysql logs for slow queries and can’t see any (though it’s only logging ones that take longer than 1s so maybe it’s doing lots and lots of faster ones that can still be optimised).

I’ve put some debug logging in and all the time is going in ShowHistory, so I guess in the loop that loops over all the various transactions and things to display for that ticket.

Any suggestions or tweaks that people have done would be great, before I start investigating what’s going on at a lower level.

Thanks,

Justin