<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Alex Little &#187; performance</title>
	<atom:link href="http://alexlittle.net/blog/tag/performance/feed/" rel="self" type="application/rss+xml" />
	<link>http://alexlittle.net/blog</link>
	<description></description>
	<lastBuildDate>Wed, 01 Feb 2012 17:46:37 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Scaling</title>
		<link>http://alexlittle.net/blog/2006/09/28/scaling/</link>
		<comments>http://alexlittle.net/blog/2006/09/28/scaling/#comments</comments>
		<pubDate>Thu, 28 Sep 2006 07:49:51 +0000</pubDate>
		<dc:creator>Alex</dc:creator>
				<category><![CDATA[Web dev & programming]]></category>
		<category><![CDATA[block]]></category>
		<category><![CDATA[moodle]]></category>
		<category><![CDATA[msg]]></category>
		<category><![CDATA[performance]]></category>

		<guid isPermaLink="false">http://alexlittle.net/blog/2006/09/28/scaling/</guid>
		<description><![CDATA[Had a bit of a nightmare the last couple of days! When we moved the MSG Block over to the &#8216;live&#8217; server, we started to find that things weren&#8217;t working very well &#8211; the Moodle site was incredibly slow, this obviously(!) turned out to be a problem with the MSG block slowing things down with [...]]]></description>
			<content:encoded><![CDATA[<p>Had a bit of a nightmare the last couple of days! When we moved the MSG Block over to the &#8216;live&#8217; server, we started to find that things weren&#8217;t working very well &#8211; the Moodle site was incredibly slow, this obviously(!) turned out to be a problem with the MSG block slowing things down with the number of requests being made keeping peoples presence status up to date. And this was with relatively few users&#8230;</p>
<p>So I&#8217;ve had to make fairly big changes over the last day or so to the MSG block to reduce the amount of communication between the Moodle and MSG servers. The way I&#8217;ve got around this is to create a database table for the MSG block to cache users presence for a minute or so and only to update the presence when the cache has expired. The obvious downside of this is that user&#8217;s presence doesn&#8217;t appear quite so &#8216;live&#8217; on the browser page. There&#8217;s also a kind of natural limit to how long the cache should be set to &#8211; as if it&#8217;s too long it defeats the point of having the live updates via AJAX and the presences only refreshed when the whole page is refreshed (and no AJAX). At the moment I have the cache set to 1 minute, which seems ok for now, but  we may have to make this even longer if performance drops again.</p>
<p>I would have preferred to have kept this cache in memory rather than database table (which keeps needing to be read and updated), but apparently this is a bit tricky to do in PHP &#8211; see the posting I made on the Moodle forums at: <a href="http://moodle.org/mod/forum/discuss.php?d=54994">http://moodle.org/mod/forum/discuss.php?d=54994</a></p>
]]></content:encoded>
			<wfw:commentRss>http://alexlittle.net/blog/2006/09/28/scaling/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Improving performance</title>
		<link>http://alexlittle.net/blog/2006/09/22/improving-performance/</link>
		<comments>http://alexlittle.net/blog/2006/09/22/improving-performance/#comments</comments>
		<pubDate>Fri, 22 Sep 2006 08:46:40 +0000</pubDate>
		<dc:creator>Alex</dc:creator>
				<category><![CDATA[Web dev & programming]]></category>
		<category><![CDATA[msg]]></category>
		<category><![CDATA[performance]]></category>

		<guid isPermaLink="false">http://alexlittle.net/blog/2006/09/22/improving-performance/</guid>
		<description><![CDATA[Spent the last couple of days trying to improve the performance of the MSG Moodle block &#8211; seems to be going ok, though some of the things I&#8217;ve tried actually make things worse (when they ought to improve!) so spent a bit of time going back and forwards with the code base! We&#8217;ve found that [...]]]></description>
			<content:encoded><![CDATA[<p>Spent the last couple of days trying to improve the performance of the MSG Moodle block &#8211; seems to be going ok, though some of the things I&#8217;ve tried actually make things worse (when they ought to improve!) so spent a bit of time going back and forwards with the code base!</p>
<p>We&#8217;ve found that if the content-length is set in the returned XML (back to the AJAX in MSG block) then this prevents too many open connections building up on the browsing PC. Though I seem to be having problems setting the content length in PHP &#8211; if I do (eg):</p>
<p>header(&#8220;Content-Length: 100&#8243;);</p>
<p>then this just seems to be ignored (even if I send no other headers) &#8211; so I&#8217;m a bit confused as to what&#8217;s going on here. PHP appears to randomly decide whether a response is going to have a content-length or it&#8217;s going to have a &#8216;chunked&#8217; transfer-encoding&#8230;.</p>
<p>Also would like to arrange some time over the next couple of weeks when we can properly load test the the MSG Block (and MSG itself) and see how it&#8217;ll cope (or not!).</p>
]]></content:encoded>
			<wfw:commentRss>http://alexlittle.net/blog/2006/09/22/improving-performance/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

<!-- Dynamic page generated in 1.290 seconds. -->
<!-- Cached page generated by WP-Super-Cache on 2012-02-08 19:28:17 -->

