Re: MasonHQ node caching, and other bugs

"Jonathan Swartz" <[email protected]>
Newsgroups gmane.comp.web.mason.devel
Message-ID <[email protected]>
> This posting is related to usage of MasonHQ. My appologies if this is the
> wrong forum.
>
> I'm building a Wiki web site based upon the MasonHQ code. Besides being a
> little slow, it works pretty well. But I found a few bugs; one particular
> is causing much grief.

Hi Soren, sorry for the delayed response...

> 1) Content caching.
>
> When editing a page, especially when editing a page that has just been
> updated, I often find myself editing old content. The edit.html loads old
> content into the form. A few reloads will cycle between various revisions
> of the page. The page is not cached by a proxy server. Tracking through
> the code, I end up on lib/MHQ/Wiki/Node.pm in the latest_version()
> subroutine. This piece of code does not return the latest version, but
> instead whatever is cached in ... in apache I guess.
>
>    sub latest_version
>    {
>      my ($self) = @_;
>      unless (defined($self->{_latest_version})) {
>        ($self->{_latest_version}) =
>          $self->versions(version_id=>$self->latest_version_id);
>      }
>      return $self->{_latest_version};
>    }

It is caching in the Node object itself, which should be recreated every
request. So I don't think this is the problem.

I've never encountered the problem you are having on the masonhq.com site,
and I do often edit pages that have just been updated.

Are you still having this problem? If so, after editing and saving a page,
check the node entry database to see if it has been updated. If not, then
for some reason your query isn't being committed to the database. (Are you
using a database with transactions?)

>
> 2) Slowness, internal server error.
>
> Starting up apache takes a lot of time. And new instances have to be
> spawned often, so the site is generally pretty slow. Keeping
>
>    MaxRequestsPerChild 10
>
> in conf/httpd-prod.conf.src generally works, but is slow. Increasing the
> number results in frequent internal server errors.

Internal server errors should be matched with errors in the logs...what are
the errors?

>
> 3) Links to local files.
>
> The might be a restriction in Kwiki more than MasonHQ. But there seem to
> be no syntax for linking to local files.
>
> I guess I can create new rules in lib/MHQ/CGI/Kwiki/Formatter.pm for this
> purpose?

Yup.

>
> 4) Bugs and documentation
>
> I have fixed a few other bugs in the code, as well as kept an installation
> journal that is more accurate than the one provided. Is there somewhere to
> send patches and docs updates?
>

Please post them to this list, and I'll try to get to them with more haste
than before. :)

A better installation journal would be great. Actually this should probably
be put on the wiki and linked from http://masonhq.com/?SourceForThisSite, so
that it can be easily updated.

Thanks!
Jon



-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.