I'll reply to the larger question about caching of WikiTalk on 1.8 in a few 
minutes, but certainly the kind of thing that you list below is low-hanging 
fruit of the sweetest variety :-)

David

> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:flexwiki-
> [EMAIL PROTECTED] On Behalf Of Craig Andera
> Sent: Thursday, August 30, 2007 6:18 AM
> To: 'FlexWiki Users Mailing List'
> Subject: Re: [Flexwiki-users] Performance analysis
>
> > namespace.Topics.SortBy
> > { each |
> >       DateTime.Now.SpanBetween(each.LastModified)
> > }
>
> OK, I think I can see why this is so slow. The issue is that
> each.LastModified translates into a call of
> Federation.GetTopicModificationTime. But when doing a SortBy, each
> element
> is going to be compared *many time* to its neighbors, resulting in
> dozens
> and dozens of calls into the Federation, with all the security checking
> and
> whatnot that implies. Even though it's hitting cache, it's still going
> to be
> expensive.
>
> The easy fix for this is to change methods like this (on TopicInfo):
>
> [ExposedMethod(ExposedMethodFlags.Default, "Answer a DateTime
> inndicating
> when the topic was last modified")]
> public DateTime LastModified
> {
>    get
>    {
>        return Federation.GetTopicModificationTime(TopicRevision);
>    }
> }
>
> To something like this:
>
> [ExposedMethod(ExposedMethodFlags.Default, "Answer a DateTime
> inndicating
> when the topic was last modified")]
> public DateTime LastModified
> {
>    get
>    {
>        if (!_haveLastModified)
>        {
>            _lastModified =
> Federation.GetTopicModificationTime(TopicRevision);
>            _haveLastModified = true;
>        }
>
>        return _lastModified;
>    }
> }
>
> Yeah, that should help *a lot*. Freakin' awesome if it does, too,
> because
> it's dead simple and doesn't require any architectural changes. :)
>
> I'll start making some of these changes today and see what effect it
> has.
> I'm extremely optimistic.
>
>
>
> -----------------------------------------------------------------------
> --
> This SF.net email is sponsored by: Splunk Inc.
> Still grepping through log files to find problems?  Stop.
> Now Search log events and configuration files using AJAX and a browser.
> Download your FREE copy of Splunk now >>  http://get.splunk.com/
> _______________________________________________
> Flexwiki-users mailing list
> Flexwiki-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/flexwiki-users


-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/
_______________________________________________
Flexwiki-users mailing list
Flexwiki-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flexwiki-users

Reply via email to