<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet href="http://feeds.feedburner.com/~d/styles/rss2full.xsl" type="text/xsl" media="screen"?><?xml-stylesheet href="http://feeds.feedburner.com/~d/styles/itemcontent.css" type="text/css" media="screen"?><rss 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:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
	<title>Pathfinder Development</title>
	
	<link>http://www.pathf.com/blogs</link>
	<description>Running commentary about agile development, user experience design and Ajax.</description>
	<pubDate>Thu, 04 Dec 2008 21:00:14 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.5.1</generator>
	<language>en</language>
			<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" href="http://feeds.feedburner.com/AgileAjax" type="application/rss+xml" /><feedburner:emailServiceId>345210</feedburner:emailServiceId><feedburner:feedburnerHostname>http://www.feedburner.com</feedburner:feedburnerHostname><item>
		<title>Firefox Plugin Malware ‘Trojan.PWS.ChromeInject.A’</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/474954217/</link>
		<comments>http://www.pathf.com/blogs/2008/12/firefox-malware/#comments</comments>
		<pubDate>Thu, 04 Dec 2008 19:09:20 +0000</pubDate>
		<dc:creator>Dietrich Kappe</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<category><![CDATA[Firefox]]></category>

		<category><![CDATA[Malware]]></category>

		<category><![CDATA[plugin]]></category>

		<category><![CDATA[Security]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1304</guid>
		<description><![CDATA[You knew it had to happen. Malware for Firefox. It happens all the time with IE (so much so that my 17-year-old niece needs a fresh install of Windows every 3 months), but Firefox has been a little less prone -- though not imune -- to malware. See the BitDefender blog post and the Infoworld [...]]]></description>
			<content:encoded><![CDATA[<p>You knew it had to happen. Malware for Firefox. It happens all the time with IE (so much so that my 17-year-old niece needs a fresh install of Windows every 3 months), but Firefox has been a little less prone -- though not imune -- to malware. See the <a href="http://www.bitdefender.co.uk/NW900-uk--BitDefender-detects-novel-approach-to-stealing-web-passwords.html" target="_blank">BitDefender blog post</a> and the <a href="http://www.infoworld.com/article/08/12/04/Firefox_users_targeted_by_rare_piece_of_malware_1.html" target="_blank">Infoworld article</a> which has a bit more detail.</p>
<p>Now Firefox 3 does contain <a href="http://www.mozilla.com/en-US/firefox/phishing-protection/" target="_blank">Malware protection</a>, but apparently this plugin is delivered via other system compromises to the filesystem, and apparently Firefox doesn't question already installed plugins.</p>
<p>BTW, the malware registers itself as <a href="https://addons.mozilla.org/en-US/firefox/addon/748" target="_blank">GreaseMonkey</a>. If you care to, you can follow the <a href="http://it.slashdot.org/it/08/12/04/1536231.shtml" target="_blank">Slashdot food fight</a> on this topic.</p>
<p>More as I find out more...</p>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=eEvxO"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=eEvxO" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=M7XJO"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=M7XJO" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=mhdUO"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=mhdUO" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=g788o"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=g788o" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=IIwDo"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=IIwDo" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/474954217" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/12/firefox-malware/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/12/firefox-malware/</feedburner:origLink></item>
		<item>
		<title>Pathfinder releases version 1 of the its Flash Platform microsite (codename Mica)</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/474889698/</link>
		<comments>http://www.pathf.com/blogs/2008/12/pathfinder-releases-version-1-of-the-its-flash-platform-microsite-codename-mica/#comments</comments>
		<pubDate>Thu, 04 Dec 2008 18:30:18 +0000</pubDate>
		<dc:creator>Sasha Dzeletovic</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<category><![CDATA[TechDev]]></category>

		<category><![CDATA[Amazon CDN]]></category>

		<category><![CDATA[Flash]]></category>

		<category><![CDATA[Flash Platform]]></category>

		<category><![CDATA[Flex]]></category>

		<category><![CDATA[microsite]]></category>

		<category><![CDATA[StageScaleMode]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1298</guid>
		<description><![CDATA[
You can see the site here. Come often as it will be updated on a regular basis.
The goal of this site is to shed more light on what is it that we do here at Pathfinder with the Flash Platform.
We would be very grateful to hear feedback about the site from any perspective.

The Site was [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.pathfinder-development.com" target="_blank"><img class="alignnone size-full wp-image-1299" title="Pathfinder Flash Platform Microsite" src="http://www.pathf.com/blogs/wp-content/uploads/2008/12/mica.jpg" alt="" width="400" height="237" /></a></p>
<p>You can see the site <a href="http://www.pathfinder-development.com" target="_blank">here</a>. Come often as it will be updated on a regular basis.</p>
<p>The goal of this site is to shed more light on what is it that we do here at Pathfinder with the Flash Platform.<br />
We would be very grateful to hear feedback about the site from any perspective.</p>
<p><span id="more-1298"></span></p>
<p>The <a href="http://www.pathfinder-development.com" target="_blank">Site</a> was developed using Flex Builder 3.</p>
<p>We were focusing on several things:</p>
<ul>
<li>Presenting our work in a manner that is fast and easy to consume</li>
<li>Fast loading times of site and content</li>
<li>Maintaining the same experience on any screen resolution, major browsers and OS’s</li>
<li>Testing SEO optimization for Flash Platform</li>
<li>Uniformity and reusability of interaction effects</li>
<li>Ease of dynamic content maintenance</li>
</ul>
<p><strong>Presenting our work in a manner that is fast and easy to consume</strong></p>
<p>We decided to present our work mostly using screen casts of apps being used. We thought that this would be the quickest way for our visitor to get a good taste of our work.</p>
<p><strong>Fast loading times of site and content</strong></p>
<p>We used Amazon's <a href="http://aws.amazon.com/cloudfront/" target="_blank">Cloud Front CDN</a> to store streaming video content.  Setting up cross domain permissions was a little tricky.  Images loaded from Cloud Front would have a slight delay loading right after initialization of the site, otherwise they acted great. We're still looking into this issue as we think that using Cloud Front is potentially a great approach for storing content like images and videos, at a substantially lower cost than <a href="http://www.akamai.com/" target="_blank">Akamai</a> or <a href="http://www.limelightnetworks.com" target="_blank">Limelight Networks</a>.</p>
<p>All content was optimized for web using Adobe Photoshop and QuickTime Pro. The Site’s interface is entirely created out of vectors, for screen resolution scalability and fast loading times. Vector content is either programatic, either imported from Adobe Illustrator as mentioned in this <a href="http://www.pathf.com/blogs/2008/11/skinning-flex-with-illustrator-cs3/" target="_blank">post</a>.</p>
<p><strong>Maintaining the same experience on any screen resolution, major browsers and OS’s</strong></p>
<p>Flash does take care a lot of this business out of the box.</p>
<p>Though this is a Flex application, we chose to use good ol’ Flash Stage resizing method:<br />
stage.scaleMode = StageScaleMode.SHOW_ALL .</p>
<p>The catch with this one is that your flash movie size (width/height) in HTML has to be 100% or the line will not work.<br />
It turned out that this was not a bad idea at all. It allowed us to focus on one layout of known proportions that will fit any screen size the same way.<br />
Plan B would have been to use the standard Flex constraints system for display objects, but in this case the results were so different (naturally) that the site would have had tremendously different appearance based on screen resolution.</p>
<p><strong>Testing SEO for Flash Platform</strong></p>
<p>As mentioned in this <a href="http://www.pathf.com/blogs/2008/07/google-learns-to-crawl-flash/" target="_blank">post</a> Google doesn’t index Flash dynamic content. We had to go back to standard SEO techniques for Flash Platform.</p>
<p>To name a couple:</p>
<ul>
<li> We embedded a lot of text content in the Flash file itself.</li>
<li> We filled the HTML wrapper as any HTML page sans the body content.</li>
</ul>
<p><strong>Uniformity and re-usability of interaction effects </strong></p>
<p>We wanted to have standard effects for particular interactions.<br />
For interaction effects we created various effect classes that would have two parameters in constructor:</p>
<ul>
<li>Targeted UIComponent</li>
<li>Function to be executed at the end of effect.</li>
</ul>
<p>All the timers and listeners for the effect are stored in the effect class.<br />
First parameter makes the effect useful work for pretty much anything.<br />
Second parameter proved useful for execution based on the effect timing.</p>
<p><strong>Ease of dynamic content maintenance</strong></p>
<p>Since there is not a whole lot of content to be maintained, we decided to have all the content catalogued in two XML files, one for the Case Studies and one for the image gallery. This has proved yet again to be the fastest and easiest way to setup and maintain small scale content.</p>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=xBdSO"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=xBdSO" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=I1eeO"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=I1eeO" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=uv1RO"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=uv1RO" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=k2Mmo"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=k2Mmo" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=AIeVo"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=AIeVo" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/474889698" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/12/pathfinder-releases-version-1-of-the-its-flash-platform-microsite-codename-mica/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/12/pathfinder-releases-version-1-of-the-its-flash-platform-microsite-codename-mica/</feedburner:origLink></item>
		<item>
		<title>Pimp my Rails: Five Plugins &amp; Gems to Make Rails Better</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/474376475/</link>
		<comments>http://www.pathf.com/blogs/2008/12/pimp-my-rails-five-plugins-gems-to-make-rails-better/#comments</comments>
		<pubDate>Thu, 04 Dec 2008 07:02:05 +0000</pubDate>
		<dc:creator>Josh Symonds</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<category><![CDATA[Ruby on Rails]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1303</guid>
		<description><![CDATA[Shamelessly dovetailing off our very own Brian Dillard's blog entry earlier this week, Pimp my jQuery, I wanted to jot down a few of my favorite Ruby on Rails tools that I would find life completely unbearable to be without. While they might seem like simple, small changes, these plugins have saved me huge amounts [...]]]></description>
			<content:encoded><![CDATA[<p>Shamelessly dovetailing off our very own <a href="http://www.pathf.com/blogs/author/brian-dillard/">Brian Dillard's</a> blog entry earlier this week, <a href="http://www.pathf.com/blogs/2008/12/pimp-my-jquery-five-plugins-to-replace-the-features-prototype-and-scriptaculous-users-expect/">Pimp my jQuery</a>, I wanted to jot down a few of my favorite Ruby on Rails tools that I would find life completely unbearable to be without. While they might seem like simple, small changes, these plugins have saved me huge amounts of time and I think the least their authors deserve are some nice shout-outs.</p>
<p><span id="more-1303"></span></p>
<ol>
<li><a href="http://terralien.com/projects/querytrace/">QueryTrace</a>. QueryTrace is a super simple plugin that shows exactly where SQL loads happen in your application. After an action is called you can check the log to see a backtrace after every SQL query, revealing where in your code it was referenced. Use this to find slow or unnecessary queries in your application.</li>
<li><a href="http://andand.rubyforge.org/">Andand</a>. Andand is a super simple gem that allows you to simply and easily prevent NoMethodErrors: that is, it helps you catch nil objects before you send methods to them. Its use is ridiculously simple: object.andand.method. If object is nil, then method will return nil, rather than raising a NoMethodError. This functionality is actually being included in the next version of Edge Rails under Object#try, but there will always be a special place in my heart for Andand.</li>
<li><a href="http://pablotron.org/software/wirble/">Wirble</a>. Wirble adds some awesome features to irb, and, therefore, to script/console. I've completely forgotten how I've managed to work with irb before I got tab completion, history, and colorized results. This should come standard with irb, in my opinion.</li>
<li><a href="http://code.google.com/p/calendardateselect/">Calendar Date Select</a>. Somehow in almost every application I'm involved in, someone ends up wanting a quick and easy way to pick a date. It doesn't get a whole lot quicker and easier than Calendar Date Select. It's simple to use and by this point I honestly should just install it in all my projects when I start them.</li>
<li><a href="http://repo.pragprog.com/svn/Public/plugins/annotate_models/">Annotate Models</a>. Annotate Models is a very simple, small plugin that adds in a new rake task: rake annotate_models. It puts the schema for your models at the top of those models, so you don't have to use SQL queries to remember the structure of your tables. It doesn't get a whole lot simpler or more useful than this.</li>
</ol>
<p>The beauty of small, easily digestable plugins and gems like these is that they're reusable in every application you do. Before you know it you'll be installing these before you even start serious work on a project. Got any gems and plugins you want added to the list? Throw them out in the comments!</p>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=W6puO"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=W6puO" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=78gNO"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=78gNO" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=SicqO"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=SicqO" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=hhZpo"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=hhZpo" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=deOio"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=deOio" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/474376475" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/12/pimp-my-rails-five-plugins-gems-to-make-rails-better/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/12/pimp-my-rails-five-plugins-gems-to-make-rails-better/</feedburner:origLink></item>
		<item>
		<title>iPhone: Using Pre-processor Directives for Device Testing</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/474032069/</link>
		<comments>http://www.pathf.com/blogs/2008/12/iphone-sim-device-preprocessor/#comments</comments>
		<pubDate>Wed, 03 Dec 2008 22:29:57 +0000</pubDate>
		<dc:creator>Ivan Moscoso</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<category><![CDATA[Disruption]]></category>

		<category><![CDATA[iPhone]]></category>

		<category><![CDATA[obj-c]]></category>

		<category><![CDATA[Testing]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1296</guid>
		<description><![CDATA[
There may be cases where a certain setting needs to be tweaked based on whether you test on the device or simulator.  It took me a while to find the pre-processor directive to detect whether or not the current build targets the iPhone device or the simulator, but with a bit of searching through [...]]]></description>
			<content:encoded><![CDATA[<p><img class="right" src="http://www.pathf.com/blogs/wp-content/uploads/2008/12/xcode-apps2.png" alt="iPhone in Dock" width="160" height="158" /><br />
There may be cases where a certain setting needs to be tweaked based on whether you test on the device or simulator.  It took me a while to find the pre-processor directive to detect whether or not the current build targets the iPhone device or the simulator, but with a bit of searching through the GTM code, I found everything I needed in "TargetConditionals.h".  An obvious place, in retrospect, but I wasn't able to find this information easily elsewhere on the web, so I mention it here in case you find it useful.</p>
<p>Here's an example of how I've used it:</p>
<pre>
#if TARGET_CPU_ARM
	// Device will hit external server over cell network
	NSString const *ROOT_URL = @"http://www.external-site.com";
#else
	// Simulator will hit local server over LAN
	NSString const *ROOT_URL = @"http://localhost:8667";
#endif
</pre>
<p>This kind of tweaking is particularly important when the device itself can not participate on the local network, but needs to access some kind of external environment (or proxy server).  Conversely, targeting the simulator to use a local 'development' server is often faster when deploying and debugging issues in your application, particularly if you are developing the server component in tandem.</p>
<p>Another example involved certain audio playback features which work fine on the device, but run into hiccups running on the simulator.  Since in this case the functionality is not critical to test, I ignore it in the simulator.</p>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=IZtKO"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=IZtKO" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=MwuxO"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=MwuxO" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=FdvJO"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=FdvJO" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=NiZpo"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=NiZpo" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=T0dKo"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=T0dKo" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/474032069" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/12/iphone-sim-device-preprocessor/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/12/iphone-sim-device-preprocessor/</feedburner:origLink></item>
		<item>
		<title>Subtle OpenGL Projection Matrix Difference Between iPhone Simulator and Device</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/472986345/</link>
		<comments>http://www.pathf.com/blogs/2008/12/subtle_opengl_projection_matrix_difference_between_iphone_simulator_and_device/#comments</comments>
		<pubDate>Tue, 02 Dec 2008 23:27:40 +0000</pubDate>
		<dc:creator>Anthony Caliendo</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1297</guid>
		<description><![CDATA[
If you are deploying to the iPhone simulator instead of to a device, you can get away with not loading the identity matrix for the projection matrix so long as you do not want to draw over any bound textures which are drawn.  However, on an iPhone device, you will notice some serious artifacting if [...]]]></description>
			<content:encoded><![CDATA[<div class="right"><a href="http://www.pathf.com/blogs/wp-content/uploads/2008/07/iphone_in_dock.jpg"><img class="alignnone size-medium wp-image-1016" src="http://www.pathf.com/blogs/wp-content/uploads/2008/07/iphone_in_dock.jpg" alt="iPhone in Dock" width="160" height="240" /></a></div>
<p>If you are deploying to the iPhone simulator instead of to a device, you can get away with not loading the identity matrix for the projection matrix so long as you do not want to draw over any bound textures which are drawn.  However, on an iPhone device, you will notice some serious artifacting if you attempt this.  The artifacts will be related to the last drawn textures, even if they were drawn from a different application (except if the phone was turned off in the interim, in which case you will get a black strobe effect).</p>
<p>This implies that the simulator loads the identity matrix automatically for <code>GL_PROJECTION</code> when loading your application, where as the iPhone itself will maintain the matrix's state between applications.</p>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=qQHQO"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=qQHQO" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=aA85O"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=aA85O" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=yJdVO"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=yJdVO" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=vKOqo"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=vKOqo" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=2LPOo"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=2LPOo" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/472986345" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/12/subtle_opengl_projection_matrix_difference_between_iphone_simulator_and_device/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/12/subtle_opengl_projection_matrix_difference_between_iphone_simulator_and_device/</feedburner:origLink></item>
		<item>
		<title>App Security: Throw Out the Org Chart!</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/472677216/</link>
		<comments>http://www.pathf.com/blogs/2008/12/app-security-organization/#comments</comments>
		<pubDate>Tue, 02 Dec 2008 17:48:11 +0000</pubDate>
		<dc:creator>Ivan Moscoso</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<category><![CDATA[authorization]]></category>

		<category><![CDATA[modeling]]></category>

		<category><![CDATA[Security]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1266</guid>
		<description><![CDATA[
"Only administrators can add users-- no exceptions!  ...except Bob in accounting, but that's because he's covering for Sally.  But only until February.  And this sort of arrangement might happen again.  But most of the time, it won't.  I mean.. ninety-nine point nine percent of the time.  But there might [...]]]></description>
			<content:encoded><![CDATA[<p><img class="right" src="http://www.pathf.com/blogs/wp-content/uploads/2008/12/org-org.png" alt="Traversing The Org Chart" width="180" height="168" /><br />
<em><b>"Only administrators can add users-- no exceptions!  ...except Bob in accounting, but that's because he's covering for Sally.  But only until February.  And this sort of arrangement might happen again.  But most of the time, it won't.  I mean.. ninety-nine point nine percent of the time.  But there might be exceptions... "</em></b>.</p>
<p>Sound like a requirement you've heard before?  How did you handle it?</p>
<p>In an earlier post, I stated that <a href="http://www.pathf.com/blogs/2008/11/designing-for-security/">all security models are idiosyncratic</a>, and that the way you go about designing for security must reflect the nuances and -isms of your organization.  You might mistake the form used to express the model (HR records, existing databases, or some XML schema) as your security model, but you risk an uphill battle getting your organization (and I mean the people here, not boxes and circles on an org chart) to accept the result.</p>
<p>All of this has less to do with how we design software and everything to do with the way people organize into groups..<br />
<span id="more-1266"></span></p>
<p>Groups and hierarchies are never fixed-- fluctuations occur, even if the rate of change varies from organization to organization.  We see this all the time in our everyday interactions-- associations can be temporal in nature, two groups may need to work together on occasion (but only, say, within a certain context).  Ownership can cut across hierarchies, and influence can shift from one group to another based on other environmental factors.</p>
<p>A well designed security model needs to accommodate for these kinds of factors (even if it means fluidity in some areas, and stringency in others).  Handling exceptions to the original security model are key, and the sooner people discuss it while building a piece of software, the better.</p>
<p>The bad news is that your IT department has chosen to see your company through a fixed lens, and will attempt to enforce the same level of stringency across the organization as a whole.  But can you blame them?  Two department heads suddenly decide to pool their resources for a period of time to make a deadline, requiring a temporary loosening of security restrictions, and suddenly the onus is on IT to work late hours dealing with the fallout.  Something which might have started as a simple conversation between two managers inadvertently puts an otherwise stable security model at risk.</p>
<p>So why do we expect rigid specifications when solving the problem of security in the first place?  After all, these specifications often reflect only a snapshot of the structure of an organization, and rarely its propensity for change.</p>
<p>Colleagues of mine cite external factors as the driving force behind the need for stringent security models in the enterprise (identity theft, liability, or a third party requirement).  I don't mean to discount the importance of these types of requirements, but the big risk here is mistaking contractual specifications (e.g. "PCI compliance" or "HIPAA compliance") for a security model.  The two are not the same thing.</p>
<p>All of this leads me to the conclusion that a contractual specification is not a substitute for a security model.</p>
<p>The former specifies an agreement between organizations in how to handle certain business transactions, while the latter dictates user roles and access rights <i>and even more importantly</i>, the process by which authorization can change based on fluctuations within the organization.</p>
<p>Before you choose a security model for your application(s), you have to understand how the organization can change.  It may be useful to look at an org chart to build a vocabulary, but in most cases you are just as well served by tossing it aside.</p>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=dQu2O"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=dQu2O" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=5sPHO"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=5sPHO" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=QkVlO"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=QkVlO" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=m2JGo"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=m2JGo" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=fBa0o"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=fBa0o" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/472677216" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/12/app-security-organization/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/12/app-security-organization/</feedburner:origLink></item>
		<item>
		<title>Pimp my jQuery: Five plugins to replace the features Prototype and Scriptaculous users expect</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/471722723/</link>
		<comments>http://www.pathf.com/blogs/2008/12/pimp-my-jquery-five-plugins-to-replace-the-features-prototype-and-scriptaculous-users-expect/#comments</comments>
		<pubDate>Mon, 01 Dec 2008 21:53:25 +0000</pubDate>
		<dc:creator>Brian Dillard</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<category><![CDATA[Javascript]]></category>

		<category><![CDATA[Javascript Libraries]]></category>

		<category><![CDATA[jQuery]]></category>

		<category><![CDATA[Prototype]]></category>

		<category><![CDATA[Scriptaculous]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1291</guid>
		<description><![CDATA[
Ajax pros, especially in the Rails world, often know the Prototype and Scriptaculous JavaScript libraries inside and out. When faced with the prospect of writing on top of the competing jQuery framework, they may quickly stumble upon seemingly missing features.
The culprit? jQuery's less-is-more approach, in which advanced or specialized features come via plugins instead of [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.pathf.com/blogs/wp-content/uploads/2008/06/ejohn-side-jquery.gif" class="right" width="74" height="74" alt="jQuery logo" title="jQuery logo" /></p>
<p>Ajax pros, especially in the Rails world, often know the <a href="http://www.prototypejs.org/">Prototype</a> and <a href="http://script.aculo.us/">Scriptaculous</a> JavaScript libraries inside and out. When faced with the prospect of writing on top of the competing <a href="http://jquery.com/">jQuery</a> framework, they may quickly stumble upon seemingly missing features.</p>
<p>The culprit? jQuery's less-is-more approach, in which advanced or specialized features come via plugins instead of the core library. The greater reliance on single-purpose plugins gives jQuery a lean footprint and a vibrant ecosystem, but they come at a cost. You often must rope in several plugins to accomplish things Prototype and Scriptaculous can do out of the box.</p>
<p>If you want to encourage your team to step out of the Prototaculous mindset, it helps to have a readymade list of plugins that approximate those libraries' core features. At this point jQuery and Prototype approach feature parity, but once Scriptaculous is in the mix, jQuery relies on multiple plugins to keep up with the Joneses. Here's a quick stab at how to trick out jQuery:</p>
<p><span id="more-1291"></span></p>
<ul>
<li><strong><a href="http://ui.jquery.com/">jQuery UI</a></strong>: jQuery's user-interface library. Some components offer effects functionality similar to Scriptaculous's, while others offer prefab UI components like the ones that are starting to roll out from <a href="http://prototype-ui.com/">Prototype UI.</a> If you're looking for tried-and-true effects such as drag-and-drop, this is where you'll find them.</li>
<li><strong><a href="http://www.decodeuri.com/jquery-fxqueues-plugin-20/">jQuery FxQueues 2.0</a></strong>: The latest version of Luciano German Panaro's effects-queue plugin. It rewires jQuery's native global effects queue with fine-grained effects queues like the ones that ship with Scriptaculous.</li>
<li><strong><a href="http://www.appelsiini.net/projects/jeditable">jEditable</a></strong>: In-place editing for the jQuery crowd. When coupled with other plugins, it offers <a href="http://www.appelsiini.net/projects/jeditable/custom.html">in-place versions of utilities ranging from time pickers to character counters</a>.</li>
<li><strong><a href="http://www.dyve.net/jquery/?autocomplete">jQuery Autocomplete</a></strong>: Dylan Verheul's much-revised solution to the original killer app of the Ajax era.</li>
<li><strong><a href="http://gsgd.co.uk/sandbox/jquery/easing/">jQuery Easing 1.3</a></strong>: Advanced animation tweening algorithms for jQuery visual effects.</li>
</ul>
<p>It's worth noting one additional feature that Scriptaculous offers: A built-in unit-testing library that can be utilized for your outside JavaScript code. Of course, several standalone JS unit-testing solutions exist out in the wild, including the well-known <a href="http://www.jsunit.net/">jsUnit</a>. Michael Grosser also offers <a href="http://code.google.com/p/jqunit/">jqUnit</a>, a jsUnit-compatible testrunner for jQuery code.</p>
<p><strong>What about you, readers? What jQuery plugins give you the most seamless transition from Prototype and Scriptaculous?</strong></p>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=MrTYO"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=MrTYO" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=lr7KO"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=lr7KO" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=ipwEO"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=ipwEO" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=X3jco"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=X3jco" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=J6Ajo"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=J6Ajo" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/471722723" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/12/pimp-my-jquery-five-plugins-to-replace-the-features-prototype-and-scriptaculous-users-expect/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/12/pimp-my-jquery-five-plugins-to-replace-the-features-prototype-and-scriptaculous-users-expect/</feedburner:origLink></item>
		<item>
		<title>Thanksgiving 2008: What We’re Thankful For (In Rails)</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/466552928/</link>
		<comments>http://www.pathf.com/blogs/2008/11/thanksgiving-2008-what-were-thankful-for-in-rails/#comments</comments>
		<pubDate>Wed, 26 Nov 2008 20:16:47 +0000</pubDate>
		<dc:creator>Noel Rappin</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<category><![CDATA[Ruby on Rails]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1290</guid>
		<description><![CDATA[





Penguin Harvest by wednesday181


Since it's Thanksgiving and all, I asked our Rails developers to briefly mention something in Rails that they are thankful for. You'll notice some common threads -- nobody consulted with anybody else as far as I know.
Anthony Caliendo
I'm thankful for the "convention over configuration" mindset, as it saves me so much time [...]]]></description>
			<content:encoded><![CDATA[<div class="right">
<a href="http://www.flickr.com/photos/amandagillispie/3019214167/"><br />
<img src="http://www.pathf.com/blogs/wp-content/uploads/2008/11/3c62fbf3-9c55-4fee-8f4f-c793b2bbe870.jpg" alt="3C62FBF3-9C55-4FEE-8F4F-C793B2BBE870.jpg" border="0" width="240" height="160" class="right"/><br />
</a><br />
<br clear="all"/><br />
<span class="right" style="font-size: smaller"><br />
<a href="http://www.flickr.com/photos/amandagillispie/3019214167/">Penguin Harvest by wednesday181</a><br />
</span>
</div>
<p>Since it's Thanksgiving and all, I asked our Rails developers to briefly mention something in Rails that they are thankful for. You'll notice some common threads -- nobody consulted with anybody else as far as I know.</p>
<h4>Anthony Caliendo</h4>
<p>I'm thankful for the "convention over configuration" mindset, as it saves me so much time and removes all the plumbing and wiring I needed to do when developing java apps just to get it running.</p>
<h4>Jason Sendelbach</h4>
<p>I am thankful that Ruby on Rails has conventions and code that reads like prose. Because of this, I can join an existing project and be an effective resource immediately.  If I am fixing a bug, I simply look at the URL to figure out where to start.  If the code is good (most of the code in Models and Helpers and not in the Controller), there are few bugs (did I mention the code was generated with TDD) and I can quickly start coding without much overview from any of the other developers.  The entire project and code is self explaining. There is almost zero ramp up time.  Thanks Rails (and Ruby).</p>
<h4>Josh Symonds</h4>
<p>Definately ActiveRecord. Particularly associations and association methods, and named scopes (because they feel like association methods but on one model).</p>
<h4>Sharad Jain</h4>
<p>I am sure ActiveRecord is the crownjewel. Outside of that, support for testing (unit, funcational) and supporting classes inside of rails are great.<br />
Standardization of how libraries are installed (gems, plugins) etc. and convention of configuration in general is also something that I am thankful for.</p>
<h4>Karthik Muthupalaniappan</h4>
<p>I think the best thing for me about Rails is it lets me worry only about how I should/can code a functional requirement of an application by taking care of most of the other configurational/operational aspects of the application</p>
<h4>John McCaffrey</h4>
<p>Thorough implementation of Regular expressions throughout ruby and rails.</p>
<h4>Noel Rappin</h4>
<p>I get to go last, so I won't repeat anybody else...</p>
<p>I honestly love the ActiveSupport library, with all its <code>2.days.ago</code> and <code>10.kilobytes</code> and even <code>array.second</code>. I'm thankful for the attitude encapsulated by all these methods -- "if I needed to this, a lot of other people probably will, and I want to make sure they don't have to write it again". It's DRY at the community level, and it's part of what makes working in Rails so satisfying.</p>
<p>Have a great holiday weekend, everybody. Thanks to all of you that read and comment.</p>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=ySRfN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=ySRfN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=L06RN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=L06RN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=xPRJN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=xPRJN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=DWS1n"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=DWS1n" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=t3YHn"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=t3YHn" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/466552928" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/11/thanksgiving-2008-what-were-thankful-for-in-rails/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/11/thanksgiving-2008-what-were-thankful-for-in-rails/</feedburner:origLink></item>
		<item>
		<title>iPhone SDK: Testing with TextMate &amp; GTM</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/466383992/</link>
		<comments>http://www.pathf.com/blogs/2008/11/iphone-sdk-testing-with-textmate-gtm/#comments</comments>
		<pubDate>Wed, 26 Nov 2008 17:30:40 +0000</pubDate>
		<dc:creator>Ivan Moscoso</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<category><![CDATA[iPhone]]></category>

		<category><![CDATA[textmate]]></category>

		<category><![CDATA[unit testing]]></category>

		<category><![CDATA[xcode]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1287</guid>
		<description><![CDATA[
Developing in Xcode, I keep my project default "SDKROOT" and Target set to the default for the iPhone device and 'Release', respectively.
That said, I have been trying out TextMate as an alternative to Xcode, thanks to all of the great things TextMate provides (I won't go into all that here, since there are already many [...]]]></description>
			<content:encoded><![CDATA[<p><img class="right" src="http://www.pathf.com/blogs/wp-content/uploads/2008/07/iphone_in_dock.jpg" alt="iPhone in Dock" width="160" height="240" /></p>
<p>Developing in Xcode, I keep my project default "SDKROOT" and Target set to the default for the iPhone device and 'Release', respectively.</p>
<p>That said, I have been trying out TextMate as an alternative to Xcode, thanks to all of the great things TextMate provides (I won't go into all that here, since there are already many great resources on the web). For those iPhone developers who are new to the Mac platform, or to TextMate for that matter, here's a quick tip (and be sure to check install Xcode bundle first).</p>
<p>First, as always, an obligatory shout-out to Google Toolbox for Mac.  I am testing my code with GTM, and set the following environment variables so that Xcode plugin for TextMate could run a build / tests accordingly.</p>
<pre>
  TM_BUILDSTYLE = "Debug"
  TM_TARGET = "Test SDKROOT=Test SDKROOT=iphonesimulator2.1"
</pre>
<p>This presumes you followed the GTM directions by creating a 'Test' target to run your tests, and also that you are targeting the 2.1 version of the iPhone simulator's firmware.  Replace that last argument with 'iphonesimulator2.2' if you are targeting the recently released 2.2 firmware.</p>
<p>With these two settings, everything works great.  I can write a bit of code, and run the build.  Xcode definitely does a lot, and has its place in development, but I feel that the ease of use in TextMate outweighs the code completion of editing files in Xcode in cases where the code that I am working with is familiar to me.</p>
<p>Wherever I am working with new API's or need to constantly refer to documentation, Xcode is still worth it, particularly after you map some essential keyboard shortcuts (but that's another post).  For familiar API's however, you can't beat the productivity gains of just coding in TextMate.</p>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=E6rfN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=E6rfN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=bc8PN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=bc8PN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=RSTsN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=RSTsN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=H266n"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=H266n" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=dKqin"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=dKqin" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/466383992" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/11/iphone-sdk-testing-with-textmate-gtm/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/11/iphone-sdk-testing-with-textmate-gtm/</feedburner:origLink></item>
		<item>
		<title>GWTQuery - JQuery-like Syntax in GWT</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/465506523/</link>
		<comments>http://www.pathf.com/blogs/2008/11/gwtquery-jquery-like-syntax-in-gwt/#comments</comments>
		<pubDate>Tue, 25 Nov 2008 22:33:16 +0000</pubDate>
		<dc:creator>Dietrich Kappe</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<category><![CDATA[GWT]]></category>

		<category><![CDATA[jQuery]]></category>

		<category><![CDATA[Tutorials]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1285</guid>
		<description><![CDATA[Many times open source projects are mute -- they have insufficient documentation. Good technical blogs can function as a sort of ad-hoc documentation. That's what I've tried to do, most recently with my series of posts on GWT and OpenSocial. Vinay, over at Web Technology I/O, often does the same. He's got a great post [...]]]></description>
			<content:encoded><![CDATA[<p>Many times open source projects are mute -- they have insufficient documentation. Good technical blogs can function as a sort of ad-hoc documentation. That's what I've tried to do, most recently with my series of posts on <a href="http://www.pathf.com/blogs/tag/opensocial/" target="_blank">GWT and OpenSocial</a>. Vinay, over at <a href="http://vinaytech.wordpress.com/" target="_blank">Web Technology I/O</a>, often does the same. He's got a <a href="http://vinaytech.wordpress.com/2008/10/03/gwtquery-jquery-in-gwt/" target="_blank">great post</a> about Ray Cromwell's <a href="http://code.google.com/p/gwtquery/" target="_blank">GwtQuery</a> (JQuery-like syntax in GWT) and how to make it work.</p>
<p>I've been tinkering with this tool as well and am going to do my own writeup, but thought I'd give you all the heads up. BTW, according to Vinay, the compiled GWT JavaScript for GwtQuery clocks in at 712 bytes!! So much for GWT bloat.</p>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=jSDlN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=jSDlN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=PmQRN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=PmQRN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=tKdLN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=tKdLN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=8nFGn"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=8nFGn" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=f0N6n"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=f0N6n" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/465506523" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/11/gwtquery-jquery-like-syntax-in-gwt/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/11/gwtquery-jquery-like-syntax-in-gwt/</feedburner:origLink></item>
		<item>
		<title>Ask the readers: How do I fire native browser events in Prototype.js?</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/464376769/</link>
		<comments>http://www.pathf.com/blogs/2008/11/ask-the-readers-how-do-i-fire-native-browser-events-in-prototypejs/#comments</comments>
		<pubDate>Mon, 24 Nov 2008 22:39:59 +0000</pubDate>
		<dc:creator>Brian Dillard</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<category><![CDATA[Javascript]]></category>

		<category><![CDATA[jQuery]]></category>

		<category><![CDATA[Prototype]]></category>

		<category><![CDATA[rails]]></category>

		<category><![CDATA[ruby]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1284</guid>
		<description><![CDATA[I've been pairing with my colleague Noel Rappin on a cool Rails project lately, which has helped me turn a bunch of conceptual knowledge into real-world experience. I'm writing Ruby code, doing things the Rails way, and hewing faithfully to test-driven development.
I'm also returning to Prototype for my JavaScript needs after almost 15 months of [...]]]></description>
			<content:encoded><![CDATA[<p>I've been pairing with my colleague Noel Rappin on a cool Rails project lately, which has helped me turn a bunch of conceptual knowledge into real-world experience. I'm writing Ruby code, doing things the Rails way, and hewing faithfully to test-driven development.</p>
<p>I'm also returning to Prototype for my JavaScript needs after almost 15 months of daily jQuery use. The framework has matured nicely while I've been away. One surprise popped up today, however: Prototype 1.6 lacks the ability to simulate native browser events. jQuery offers this in the form of <code>jQuery.trigger</code>, which can simulate both native and custom events. But Prototype's <code>Element#fire</code> supports only namespaced custom events. (<a href="http://www.nabble.com/Prototype%27s-custom-event-bubbling-td19805156s27240.html">Read this mailing-list thread for more analysis</a>.)</p>
<p>I did a couple hours of digging around today - <a href="http://scripteka.com/">including a trip to Scripteka</a> - and haven't really found a canned, cross-browser solution to this issue. I'm looking for something that offers jQuery's native event firing in a tidy little Prototype extension. Anyone know of such a tool?</p>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=5wqgN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=5wqgN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=3jt0N"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=3jt0N" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=fjRiN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=fjRiN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=9ATrn"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=9ATrn" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=7nbrn"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=7nbrn" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/464376769" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/11/ask-the-readers-how-do-i-fire-native-browser-events-in-prototypejs/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/11/ask-the-readers-how-do-i-fire-native-browser-events-in-prototypejs/</feedburner:origLink></item>
		<item>
		<title>News Rollup for the Week of November 17, 2008</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/463059549/</link>
		<comments>http://www.pathf.com/blogs/2008/11/news-rollup-for-the-week-of-november-17-2008/#comments</comments>
		<pubDate>Sun, 23 Nov 2008 19:19:03 +0000</pubDate>
		<dc:creator>Dietrich Kappe</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<category><![CDATA[Adobe AIR]]></category>

		<category><![CDATA[Amazon Web Services]]></category>

		<category><![CDATA[Cloud Computing]]></category>

		<category><![CDATA[CloudFront]]></category>

		<category><![CDATA[Web Services]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1275</guid>
		<description><![CDATA[Two major bits of news from this week:

Amazon has gone live with their new CDN (Content Delivery Network), CloudFront. Think Akamai for the rest of us. Pay as you go, hooks into S3. If you want to get a jump start on this, get yourself the latest version (0.4.5) of S3Fox, the S3 addon for [...]]]></description>
			<content:encoded><![CDATA[<p>Two major bits of news from this week:</p>
<ul>
<li>Amazon has gone live with their new CDN (<a href="http://en.wikipedia.org/wiki/Content_delivery_network" target="_blank">Content Delivery Network</a>), <a href="http://aws.amazon.com/cloudfront/" target="_blank">CloudFront</a>. Think Akamai for the rest of us. Pay as you go, hooks into S3. If you want to get a jump start on this, get yourself the latest version (0.4.5) of <a href="http://www.suchisoft.com/ext/s3fox.php" target="_blank">S3Fox</a>, the S3 addon for FireFox. Getting started is easy: sign up for CloudFront (or sign up for Amazon Web Services if you haven't already, then sign up for CloudFront), create a bucket, put content in it, make it publicly readable, create a 'distribution', enable it and map a CNAME to the cloudfront.net hostname that corresponds to the distribution. We'll be doing some testing of the Amazon CDN over the next few weeks and do a review.</li>
<li><a href="http://www.adobe.com/devnet/logged_in/rchristensen_lpolanco_air_1.5.html" target="_blank">Adobe AIR 1.5</a> has been released. Among the improvements: encrypted local database, Flash Player 10 support (no H.264 for Flash 10, though :-(), and an update to the WebKit bundled with Air. InfoQ has a nice summary of the <a href="http://www.infoq.com/news/2008/11/max-day1" target="_blank">Adobe MAX Air 1.5 buzz</a>.</li>
</ul>
<p>If you've got any news that you'd like to announce, ping us at ajax@pathf.com.</p>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=VzpyN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=VzpyN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=UejaN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=UejaN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=02qAN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=02qAN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=Yjhcn"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=Yjhcn" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=HfRUn"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=HfRUn" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/463059549" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/11/news-rollup-for-the-week-of-november-17-2008/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/11/news-rollup-for-the-week-of-november-17-2008/</feedburner:origLink></item>
		<item>
		<title>Rails ThreatDown!</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/461136635/</link>
		<comments>http://www.pathf.com/blogs/2008/11/rails-threatdown/#comments</comments>
		<pubDate>Fri, 21 Nov 2008 20:50:39 +0000</pubDate>
		<dc:creator>Noel Rappin</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<category><![CDATA[Ruby on Rails]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1283</guid>
		<description><![CDATA[





Sorry, Mr. Colbert


It may help to read this one in a Stephen Colbert deadpan voice...
You want Fear, Uncertainty, and Doubt. I'm just the fuddy-duddy for the job...
This is the ThreatDown!

Threat #5: Terse Partial Declarations!
The number five threat to the Rails community this week is this commit, reducing the amount of typing it takes to invoke [...]]]></description>
			<content:encoded><![CDATA[<div class="right">
<a href="http://www.colbertnation.com"><br />
<img src="http://www.pathf.com/blogs/wp-content/uploads/2008/11/untitled.jpg" alt="Untitled.jpg" border="0" width="287" height="190" class="right"/></p>
<p></a><br />
<br clear="all"/><br />
<span class="right" style="font-size: smaller"><br />
<a href="http://www.colbertnation.com">Sorry, Mr. Colbert</a><br />
</span>
</div>
<p>It may help to read this one in a Stephen Colbert deadpan voice...</p>
<p>You want Fear, Uncertainty, and Doubt. I'm just the fuddy-duddy for the job...</p>
<p>This is the ThreatDown!</p>
<p><span id="more-1283"></span></p>
<h3>Threat #5: Terse Partial Declarations!</h3>
<p>The number five threat to the Rails community this week is <a href="http://github.com/rails/rails/commit/130fe74d17404e5c06353526c7b20beb4019cb69">this commit</a>, reducing the amount of typing it takes to invoke a partial. You can now type this:</p>
<pre style="white-space: pre !important;">
&lt;%= render @article %&gt;
</pre>
<p>Instead of this:</p>
<pre style="white-space: pre !important;">
&lt;%= render :partial => "article", :locals => {:article => @article} %&gt;
</pre>
<p>The old way, with it's triple repetition of "article" gave me a comforting Java feeling, making me want to go and write some strongly typed getters and setters. </p>
<p>The new way reduces the need for the <code>locals</code> -- this lack of caring for locals and local conditions can only lead to greater federal control over our templates and partials. Can the Department of Partial Partials be far behind?</p>
<p>As you know, I'm not a fan of unneeded, useless, content-free, windblown verbosity. In this case, though, are we not all locals? And if we don't stand up for the locals, who will stand up for us?</p>
<h3>Threat #4: Automated Testing!</h3>
<p>The number four threat to Rails this week is automated testing. As <a href="http://blog.jayfields.com/2008/11/ubiquitous-assertion-syntax.html">Jay Fields points out on his blog</a>, testing tools across different languages suffer from a distressing lack of consistency in how they express expectations, leading to confusion on the part of test writers and maintainers.</p>
<p>I think there's one clear solution to this problem: abolish testing. Only by eliminating tests can we ensure perfect consistency. Only by removing expectations can we fulfill them. It's time to liberate our code from the constraints of our constraints and let it run free, without expectations or burdens, across the functionality landscape. Run free, code! </p>
<h3>Threat #3: Rake and Generate!</h3>
<p>Threat number three is this innocent command:</p>
<pre style="white-space: pre !important;">
rake generate controller tasks
</pre>
<p>It sure looks like that should work, right? But no... Rake comes back to me with some guff that it doesn't "know how to build task 'generate'". Hey Rake -- how hard can it be to generate -- just look a couple of directories over to your immediate right. No, not the <code>tmp</code> directory, that's too far. There, the <code>script</code> directory. </p>
<p>Figure it out, Rake, just because have a temporary brain freeze doesn't mean I like to start my day with lip from a program named after a gardening implement.</p>
<h3>Threat #2: Mythbusting!</h3>
<p>DHH has been writing a series of blog posts <a href="http://www.loudthinking.com/posts/29-the-rails-myths">busting Rails myths</a>. This is a huge threat to the Rails community.</p>
<p>Look, we had a nice little gig going here -- all kinds of people were sure that Rails just wouldn't work for anything larger than a breadbox, while those of us working on Rails just sat back and giggled.</p>
<p>Sure, there was the occasional difficulty dealing with clients who said things like "we've heard Rails can't scale", or "is it true that Rails eats puppies?". But back then, when you found a client willing to take on Rails, that had real value. </p>
<p>But now, if these myths get busted, well then, anybody will be willing and able to use Rails on all sorts of projects. Who needs that kind of headache?</p>
<h3>Threat #1: Syntactic Sugar!</h3>
<p>Clearly, the biggest threat facing Rails this week are the methods <code>Array#second</code> through <code>Array#tenth</code>. Added to Rails core back in June, it took until this week for the shock to wear off the Rails community so that we could let our outrage be known. Show your outrage on <a href="http://github.com/rails/rails/commit/22af62cf486721ee2e45bb720c42ac2f4121faf4#-P0">the commit thread</a>.</p>
<p>This is just another example of the programmer-coddling, readability-at-all-costs, complexity-for-the-sake-of-complexity mentality that makes Rails so much harder to use than Enterprise Java Beans. </p>
<p>Hey, DHH, if I wanted my programs to read like English, I'd write in AppleScript. Or Lisp. Or Wasabi, like Joel Spolsky. Or I'd just write them in English and wait for artificial intelligence to catch up.</p>
<p>My proposal: remove all these methods. And remove the bracket syntax. If you want a value from an array, you need to ask it politely and provide the memory address in hex. I think this will do:</p>
<pre style="white-space: pre !important;">
array(ff98).pretty_please_with_sugar_on_top
</pre>
<p>Late breaking update: DHH has removed sixth, seventh, eighth, ninth, and tenth. He has, however, added forty_two.</p>
<p>(You think somebody is going to take this all seriously? Sigh.)</p>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=tpb4N"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=tpb4N" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=MDIBN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=MDIBN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=dZSIN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=dZSIN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=D1Rin"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=D1Rin" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=XiQgn"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=XiQgn" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/461136635" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/11/rails-threatdown/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/11/rails-threatdown/</feedburner:origLink></item>
		<item>
		<title>Automated Deployments Rock</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/460067882/</link>
		<comments>http://www.pathf.com/blogs/2008/11/automated-deployments-rock/#comments</comments>
		<pubDate>Thu, 20 Nov 2008 22:30:17 +0000</pubDate>
		<dc:creator>Jason Sendelbach</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1281</guid>
		<description><![CDATA[I have been a developer for many moons, and have taken many systems to production.  I must say that production deployments were never on my list of things that make me warm and fuzzy.  This was due to the fact that they weren't automated, or the automation was poor.  On a recent [...]]]></description>
			<content:encoded><![CDATA[<p>I have been a developer for many moons, and have taken many systems to production.  I must say that production deployments were never on my list of things that make me warm and fuzzy.  This was due to the fact that they weren't automated, or the automation was poor.  On a recent java project, we had a series of simple sh scripts that did the work of deployment.  We deployed war files to 12 application servers and to about 60 JBoss nodes.  Before the automated scripts, a developer who typed wicked fast did all of the deployments.  Without him, deployments would have been a nightmare.</p>
<p>I learned Ruby on Rails last year, and was delighted when I found <a href="http://www.capify.org/">Capistarno</a>.  I wanted to share the things I love and hate about capistrano.<br />
<span id="more-1281"></span><br />
<strong>Nice things:</strong></p>
<ul>
<li>The deployment script is the same for each environment with a configuration file for each environment. It's really easy to see what's different in each environment.</li>
<li>The deployment can specify a SVN tag/branch. Our configurations usually fail if you don't specify a branch to avoid the old "oops i just deployed trunk to production...." type errors. (Let's just say that I almost made that mistake, and added that configuration the next day)</li>
<li>Copies a system maintenance page out, which our apache configuration uses to halt traffic to the application servers during deployment</li>
<li>We actually build our apache configuration file in our deployment script.  We can then test out new redirects and other apache specific changes.  We point apache to these conf files with symbolic links, and our last deployment step is to restart apache.  We also configure our mongrel cluster with configuration parameters, so we can easily modify these parameters by simply changing the configuration and deploying.  Of course on the projects that we have moved to passenger don't need this.</li>
<li>We have a development deployment target, so we can deploy locally, and get as close to the production environment as possible.  A coworker who develops on Windows (yuck) has had some issues matching production, as he can't run passenger (and apparently support for windows is not on the road map).   Luckily he runs VMware, so he has a Linux VM that he uses as a local development environment that alleviates most of his windows "issues."  Another nifty feature with that approach is that his rake runs like a hundred thousand times faster in linux compared to windows.</li>
<li>Symlinks are great.  If you need to rollback, you can manually switch some symlinks until you figure out what the hell happened.</li>
<li>Keeps the last n deployments.  We keep 5, and unless you do a number of screwed up deployments in a row, this usually suffices.</li>
<li>At first I hated the fact that there really is no rollback support, but after doing a few tests in staging to make sure I trusted capistrano, I found that adding rollback functionality isn't possible, as you wouldn't really be able to tell what went wrong, and programatically determine  how to fix it.  What I like about capistrano, is that it leaves the  maintenance page up, and gives you a log of the problem.  From there you can figure out what needs to be done to fix the deployment, or you can quickly change some symlinks to revert the deployment.  This is the only reason the deployment to production needs to be done by a developer and not some non-technical resource.</li>
<li>The deployment directories are standardized, so it's not difficult to go find an installation on a new project.</li>
<li>It is pretty quick to add a new application server or get a deployment to a new server in the event of hardware failure.  This helps with growth.</li>
<li>As the scripts are pretty easy to run, we can have our QA team actually do the deployments.  This keeps our developers free to geek out and not need to be nagged to deploy releases all the time.</li>
</ul>
<p><strong>! Nice things:</strong></p>
<ul>
<li>Capistrano exports from SVN, tars the export, copies it to each application server, and then does its fun symlink magic (and anything else you configure).  Luckily, it sends the system maintenance page out before it starts any of this.  So my site is down during export, tar and copy over the network.  Before I had a central deployment server, I would deploy from my laptop, and this would often be from home at night.  Luckily my crappy DSL is limited on its upload bandwidth, so deployments would take almost 3 times as long from home.  I looked into changing this, but I was getting deep into capistrano, so decided to just deal with it and use a deployment server at the office with the nice big interweb tubes.</li>
<li>The documentation is good, but the formatting on the site makes me curse it every time I find myself on their site.</li>
<li>Looking at a few of the configuration files for some of our production systems, I have noticed that the before and after configurations can be quite difficult to read through and figure out exactly what is happening and when.</li>
</ul>
<p>I must say that capistrano is not perfect, but it rocks.  In general any automation of deployment tasks is worth their weight in gold.</p>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=6UJ8N"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=6UJ8N" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=uvmON"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=uvmON" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=GWnjN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=GWnjN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=818pn"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=818pn" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=KEPun"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=KEPun" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/460067882" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/11/automated-deployments-rock/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/11/automated-deployments-rock/</feedburner:origLink></item>
		<item>
		<title>Bandwidth profiling Flex projects and more with Charles</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/459141670/</link>
		<comments>http://www.pathf.com/blogs/2008/11/bandwidth-profiling-flex-projects-and-more-with-charles/#comments</comments>
		<pubDate>Thu, 20 Nov 2008 04:25:12 +0000</pubDate>
		<dc:creator>Sasha Dzeletovic</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<category><![CDATA[TechDev]]></category>

		<category><![CDATA[amf]]></category>

		<category><![CDATA[bandwidth]]></category>

		<category><![CDATA[bandwidth profiling]]></category>

		<category><![CDATA[caching]]></category>

		<category><![CDATA[Charles]]></category>

		<category><![CDATA[Flash]]></category>

		<category><![CDATA[Flex]]></category>

		<category><![CDATA[throttling]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1268</guid>
		<description><![CDATA[Adobe Flash comes with a very useful feature for bandwidth profiling. It allows you to see how will your site/app act under certain network conditions.
Flex Builder unfortunately does not have that option so we have to look somewhere else for a solution for testing.
While there are many applications that simulate various network conditions, Charles stud [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.charlesproxy.com/index.php" target="_blank"><img class="alignleft" src="http://www.charlesproxy.com/img/logo.jpg" alt="" width="134" height="140" /></a>Adobe Flash comes with a very useful feature for bandwidth profiling. It allows you to see how will your site/app act under certain network conditions.</p>
<p>Flex Builder unfortunately does not have that option so we have to look somewhere else for a solution for testing.</p>
<p>While there are many applications that simulate various network conditions, <a href="http://www.charlesproxy.com/index.php" target="_blank">Charles</a> stud up as the most practical for Flex developers, in my opinion.</p>
<p><span id="more-1268"></span></p>
<p>First thing that I liked about <a href="http://www.charlesproxy.com/index.php" target="_blank">Charles</a> is the ease of configuration. And you can configure a few things that are precious when developing a Flex app.</p>
<p>1. Charles supports <strong>No Caching</strong> per location. This means that you can block caching for your app that you are testing while keeping it on for other internet content that you as a Flex developer are always searching for reference. When does this comes in handy? Anytime your is loading dynamic content and especially for multimedia projects.</p>
<p>2. Charles supports <strong>Throttling</strong>. Works the same as Flash bandwidth profiler but also enables you to throttle specific locations. So you can set your network bandwidth to a desired speed and see if your user experience holds up.</p>
<p>3. As Charles shows you HTTP headers and <strong>AMF0 &amp; AMF3 content </strong>being sent back and forward, it is extremely useful for checking data integrity. Basically, it shows you content of any data being passed through the network that has to do with your application and more. I am a great fan of AMF3 and this feature is a life saver when you are trying to debug AMF3 related issues.</p>
<p>Having all these wonderful features, it is also easy to use and takes about a minute to install and start using.</p>
<p>There is also a fully featured free version that is limited only by you being able to use it 30 min at a time. Not that it is too much of a trouble, but for convinience of developing I recomend getting the licence that is moderately priced.</p>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=W3lbN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=W3lbN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=GGUJN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=GGUJN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=ClqYN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=ClqYN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=BPB2n"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=BPB2n" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=7RjJn"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=7RjJn" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/459141670" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/11/bandwidth-profiling-flex-projects-and-more-with-charles/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/11/bandwidth-profiling-flex-projects-and-more-with-charles/</feedburner:origLink></item>
		<item>
		<title>iPhone SDK: UIViewController Testing &amp; TDD</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/458461282/</link>
		<comments>http://www.pathf.com/blogs/2008/11/iphone-view-testing-td/#comments</comments>
		<pubDate>Wed, 19 Nov 2008 04:47:02 +0000</pubDate>
		<dc:creator>Ivan Moscoso</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<category><![CDATA[agile]]></category>

		<category><![CDATA[code]]></category>

		<category><![CDATA[Design]]></category>

		<category><![CDATA[iPhone]]></category>

		<category><![CDATA[Testing]]></category>

		<category><![CDATA[UIViewController]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1276</guid>
		<description><![CDATA[
Unfortunately there are not enough examples out there on how to test view controllers with the iPhone SDK.  My hope is to remedy that a bit by sharing some techniques I have been using to tackle the problem, particularly in keeping with the spirit of TDD along the way.
First, If you have not already [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.pathf.com/blogs/wp-content/uploads/2008/07/iphone_in_dock.jpg"><img class="alignnone size-medium wp-image-1016" style="float:right;padding:10px" title="iPhone in Dock" src="http://www.pathf.com/blogs/wp-content/uploads/2008/07/iphone_in_dock.jpg" alt="iPhone in Dock" width="160" height="240" /></a></p>
<p>Unfortunately there are not enough examples out there on how to test view controllers with the iPhone SDK.  My hope is to remedy that a bit by sharing some techniques I have been using to tackle the problem, particularly in keeping with the spirit of TDD along the way.</p>
<p>First, If you have not already done so, configure your project to use <a title="Google Toolbox for Mac" href="http://code.google.com/p/google-toolbox-for-mac/" target="_blank">GTM</a>.  This is a bit of a no-brainer as it currently stands.  Until Apple comes up with something better, GTM is the way to go.  It works as advertised, and is a credit to the folks at Google for providing this toolkit.</p>
<p>Now then, many tutorials on the web seem to imply that one should test somewhere in the middle by suggesting to add a few outlets to your controller, fire up IB and wire up your view to your view controller before you even start to think about testing any of it.</p>
<p>Testing controller logic means working under the assumption that you have wired up your view components correctly to match the controller's actions and outlets.  Wire up an element to the wrong action (or worse, forget to wire it up at all) and you can easily learn to rely too heavily on manual testing.  While this might be acceptable for small one-off applications, within a team of developers practicing <a href="http://www.extremeprogramming.org/rules/collective.html">collective code ownership</a>, this kind of error can cost real money over time.  "Thanks for caring, but I'd rather have a unit test."</p>
<p>Now then, let's take a look at some code!</p>
<p><span id="more-1276"></span></p>
<p>I have been taking an alternate approach to creating my views and view controllers by writing the test first and then wiring up my components to pass the test.  As a result, I'm starting to see other cool ways of tackling the problem while minimizing the amount of code required to get the system under test.</p>
<p>The following is a short method from one of my controller tests which allows me to assert that a UIButton is properly wired up to the right action on a controller (sorry for the screenshots, I'm having problem with syntax highlighting today):</p>
<div style="center;"><img src="http://www.pathf.com/blogs/wp-content/uploads/2008/11/assert-selector-wired1.png" border="0" alt="assert_selector_wired.png" width="543" height="225" /></div>
<p>The controller in the above code snippet is an instance variable referencing the controller under test.  While it's possible to move this logic into a macro, I liked keeping it as a method.  See "actionsForTarget:forControlEvent:" for more information on the second assertion-- this should work with any UIControl as long as you understand which UIControlEvents to accept.  Here's a sample unit test which uses the helper method above:</p>
<div style="center;"><img src="http://www.pathf.com/blogs/wp-content/uploads/2008/11/assert-selector-wired-usage.png" border="0" alt="assert_selector_wired_usage.png" width="543" height="183" /></div>
<p>This varies from other examples I have seen on the web in that I don't actually 'fire' an event through the UIButton at all.  Technically that approach exercises more of the system, but in this case, if I am confident that the button is wired up to the correct action, that's good enough for me.  I would rather invoke the controller logic directly within the test than make the test code longer than it needs to be.</p>
<p>This approach to unit testing avoids mocking, or creating custom categories to get at, say, the internals of UIEvent.  Surely there is a time and place for mocks, but so far I have found the SDK to allow me just enough in most cases without requiring me to be too clever.  And while I think other approaches are worthwhile in their own way, in a team environment I am less apt to mock out the internals of a system if it means making the tests harder for others to read or follow along.  Clean tests are their own reward!</p>
<p>Let me know if you find this approach useful, or how you go about testing that your view and view controllers play nicely.  I'm still looking for better ways, and plan to talk a lot more about iPhone SDK testing in the future.</p>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=cmrUN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=cmrUN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=U3i0N"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=U3i0N" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=BayuN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=BayuN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=Rdann"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=Rdann" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=hP1kn"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=hP1kn" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/458461282" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/11/iphone-view-testing-td/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/11/iphone-view-testing-td/</feedburner:origLink></item>
		<item>
		<title>Icons are evil; so are menus - unless you do them right</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/457686691/</link>
		<comments>http://www.pathf.com/blogs/2008/11/icons-are-evil-so-are-menus-unless-you-do-them-right/#comments</comments>
		<pubDate>Tue, 18 Nov 2008 22:37:35 +0000</pubDate>
		<dc:creator>Brian Dillard</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<category><![CDATA[UXD]]></category>

		<category><![CDATA[Confluence]]></category>

		<category><![CDATA[Firefox]]></category>

		<category><![CDATA[Flock]]></category>

		<category><![CDATA[User Experience]]></category>

		<category><![CDATA[user interface]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1270</guid>
		<description><![CDATA[Menus and dropdowns seem like attractive design choices because they conserve screen real estate while providing users access to a potentially large number of commands. But if you resist the easy out of menus and dropdowns, you may find that your applications become far more usable.
Survey the software you use for yourself, both browser- and [...]]]></description>
			<content:encoded><![CDATA[<p>Menus and dropdowns seem like attractive design choices because they conserve screen real estate while providing users access to a potentially large number of commands. But if you resist the easy out of menus and dropdowns, you may find that your applications become far more usable.</p>
<p>Survey the software you use for yourself, both browser- and desktop-based. Think about which applications provide the most invisible, effortless interfaces. I doubt it will be the ones that hide commands in complex menus and dropdown systems.</p>
<p>For some negative examples, let's look at Firefox and its more social cousin, Flock. Each app offers an advanced bookmark management mechanism, but the usability of that mechanism suffers in each due to over-reliance on cryptic menus.</p>
<p><span id="more-1270"></span></p>
<p>Here's Firefox:</p>
<p><a href="http://www.pathf.com/blogs/wp-content/uploads/2008/11/firefox.jpg"><img title="Firefox" src="http://www.pathf.com/blogs/wp-content/uploads/2008/11/firefox.jpg" alt="Firefox" width="300" height="185" /></a></p>
<p>Can you guess which bookmark management options are going to appear under each menu? Where, for example, would the command for adding a separator live? What about sorting your bookmarks? Can't figure it out? Welcome to the world of evil icons.</p>
<p>For comparison, here's Flock, the social browser derived from Firefox:</p>
<p><a href="http://www.pathf.com/blogs/wp-content/uploads/2008/11/flock.jpg"><img title="Flock" src="http://www.pathf.com/blogs/wp-content/uploads/2008/11/flock.jpg" alt="Flock" width="300" height="160" /></a></p>
<p>Clearly, Flock provides friendlier menus; at least they've got text labels. With enough trial-and-error training, you'll probably be able to teach yourself which command lives under which menu.</p>
<p>Here's another example, this time from the webapp world: Confluence, the popular enterprise wiki package. Older versions of Confluence offered the by-now-familiar star icon. Click it, and a page would be added to your favorites. More recent versions, however, hide the "add favorite" option in one of several dropdown menus. Can you guess which?</p>
<p><a href="http://www.pathf.com/blogs/wp-content/uploads/2008/11/confluence-hidden.jpg"><img class="alignnone size-medium wp-image-1273" title="Confluence 1" src="http://www.pathf.com/blogs/wp-content/uploads/2008/11/confluence-hidden.jpg" alt="Confluence 1" width="300" height="64" /></a></p>
<p>If you guessed the "Add" menu, for "add to favorites," you're wrong. It's under the "Tools" menu. Welcome to the world of evil menus.</p>
<p><a href="http://www.pathf.com/blogs/wp-content/uploads/2008/11/confluence.jpg"><img title="Confluence" src="http://www.pathf.com/blogs/wp-content/uploads/2008/11/confluence.jpg" alt="Confluence" width="189" height="300" /></a></p>
<p>So where does that leave us? Must every single command available in an interface exist as an always-visible text link within the browser viewport? Of course not. But there are some best practices in choosing how to build our menus:</p>
<ul>
<li>Icons are great, but they should either be universally recognizable (such as a star or trash can) or paired with a text label.</li>
<li>Menu groupings should be intuitive. Use care in choosing the top-level labels and don't group disparate items under the same menu.</li>
<li>For frequently accessed functionality, consider leaving it as a dedicated clickable item on the page. There's nothing wrong with a mixture of icons and menus, the former for the most popular features and the latter for everything else.</li>
</ul>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=ExnfN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=ExnfN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=bRRNN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=bRRNN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=Lv47N"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=Lv47N" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=XJJmn"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=XJJmn" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=JKHOn"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=JKHOn" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/457686691" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/11/icons-are-evil-so-are-menus-unless-you-do-them-right/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/11/icons-are-evil-so-are-menus-unless-you-do-them-right/</feedburner:origLink></item>
		<item>
		<title>The Truth About Designing For Security</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/457401026/</link>
		<comments>http://www.pathf.com/blogs/2008/11/designing-for-security/#comments</comments>
		<pubDate>Tue, 18 Nov 2008 17:49:39 +0000</pubDate>
		<dc:creator>Ivan Moscoso</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<category><![CDATA[architecture]]></category>

		<category><![CDATA[Design]]></category>

		<category><![CDATA[Security]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1261</guid>
		<description />
			<content:encoded><![CDATA[<p><img class="right" src="/blogs/wp-content/uploads/2008/11/85543900_e0019d7864.jpg" alt="\" width="300" height="225" /><br />
Security is an area of concern where value and cost are often difficult to estimate.  While big mistakes made early on in many areas of an application may prove difficult to correct, this is especially true for security, since its specifications often model a direct reflection of an organizational structure.</p>
<p>And all too often, dysfunctional organizations create dysfunctional security requirements.</p>
<p>It is common knowledge then that a failure to account for security from the start can prove much more costly in the end.  However, over-engineering security needs can require so much effort that your team may not have enough time left over to actually build the very features you are trying to secure.</p>
<p>I find the following two points very useful to keep in mind when participating in discussions concerning security regardless of the application, but especially when working under the assumption that a new application needs the same kind of security model as the old application:</p>
<ul>
<li><strong>All security models are idiosyncratic</strong></li>
<li><strong>Never underestimate the cost of being flexible</strong></li>
</ul>
<p>These two items work as polar opposites of each other:  a flexible system can accommodate many types of organizations, but not without the added cost of training, installation, documentation or maintenance.  On the other hand, a static model is cheap to build, but rarely captures the nuances of an organization's structure, particularly as business needs evolve over time.<br />
<span id="more-1261"></span></p>
<p>Years ago I worked on a small part of the security infrastructure for a public-facing site.  The security model included a fairly complex, "lattice-based" authorization scheme:  User roles were arranged in hierarchies.  Access to resources could only be determined by understanding both the hierarchy and the security level at each step in the hierarchy.  Resources were configured with different "security levels" along the way.  Half of the information needed to answer the question of access control was stored in a database, and the other half in code.  Because of this, user management was left in the hands of development, and only after that proved to be a clear bottleneck were we given the opportunity to build a front-end management interface for non-developers to manage user access rights.</p>
<p>The system was flexible, but a coordinated mess.  Several developers spent a significant effort to keep things going, and it still took a few hours with a whiteboard to explain problems or inconsistencies in the model.  A simpler, role-based authorization would have sufficed.  In retrospect, the idea of role hierarchies was never justified, and could have been done away completely if just a little bit of the front-end interface had been designed in tandem with the original security specification.</p>
<p>I wish this were an isolated case, but we hear these types of stories time and again.  The lesson I take from it is that, in trying to be flexible, an organization can overshoot its needs.  In this case, the security model covered the nuances of the organization, but at an ever-widening cost measured in development time, maintenance, training, documentation, review, etc.</p>
<hr /><a href="http://www.flickr.com/photos/generated/85543900/">('spiritual lattice' by jared)</a></p>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=T7yZN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=T7yZN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=gREdN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=gREdN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=EQfxN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=EQfxN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=ykien"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=ykien" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=QLcJn"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=QLcJn" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/457401026" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/11/designing-for-security/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/11/designing-for-security/</feedburner:origLink></item>
		<item>
		<title>GWT, Gadgets and OpenSocial, Part 2</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/456513935/</link>
		<comments>http://www.pathf.com/blogs/2008/11/gwt-gadgets-and-opensocial-part-2/#comments</comments>
		<pubDate>Mon, 17 Nov 2008 23:15:03 +0000</pubDate>
		<dc:creator>Dietrich Kappe</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<category><![CDATA[Google Gadgets]]></category>

		<category><![CDATA[GWT]]></category>

		<category><![CDATA[iGoogle]]></category>

		<category><![CDATA[OpenSocial]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1262</guid>
		<description><![CDATA[Note: It is assumed that you know your way around GWT and Eclipse for purposes of this tutorial.
While developing OpenSocial applications can be a bit tricky, getting set up to develop can be a real pain in the neck. For this installment of OpenSocial and GWT, I'm going to go through the basics of setting [...]]]></description>
			<content:encoded><![CDATA[<p><a href='http://www.pathf.com/blogs/wp-content/uploads/2008/11/hellogadget.png'><img src="http://www.pathf.com/blogs/wp-content/uploads/2008/11/hellogadget.png" alt="" title="hellogadget" width="300" height="286" class="alignright size-medium wp-image-1264" style="float:right;padding:10px" /></a><strong>Note:</strong> It is assumed that you know your way around GWT and Eclipse for purposes of this tutorial.</p>
<p>While developing OpenSocial applications can be a bit tricky, getting set up to develop can be a real pain in the neck. For this installment of OpenSocial and GWT, I'm going to go through the basics of setting up a simple Hello World gadget with iGoogle. We'll get into the details of signing up for other OpenSocial containers, testing, and so on, later. Right now we're just going to do the basics.</p>
<p>So, what do you need to build a Google Gadget with GWT for iGoogle? You need the following:</p>
<ol>
<li> The <a href="http://code.google.com/webtoolkit/" target="_blank">Google Web Toolkit</a></li>
<li>The <a href="http://code.google.com/docreader/#p=gwt-google-apis&amp;s=gwt-google-apis&amp;t=GadgetsGettingStarted" target="_blank">GWT Google Gadget API</a></li>
<li>An account on <a href="http://www.google.com/ig" target="_blank">iGoogle</a></li>
<li>Access to the <a href="http://www.google.com/ig/sandbox" target="_blank">iGoogle sandbox</a></li>
<li>Some public server space so you can serve up your gadget to iGoogle</li>
</ol>
<p><span id="more-1262"></span></p>
<p>Pretty much everything else is self explanatory, but the sandbox can be a little bit confusing. Let's talk a little bit about the iGoogle sandbox. It's an experimental space where you can test things out without polluting your regular iGoogle account. Eventually you'll want several accounts in order to test. But every journey starts with a single step.</p>
<p>First, you need to sign up for iGoogle. I'll assume this isn't your first rodeo and you've done this before. Once you've got your iGoogle access, you'll want to go over to <a href="http://code.google.com/apis/igoogle/docs/gs.html" target="_blank">this page</a> to sign up for the developer sandbox and add the developer tools to your space.</p>
<p>When developing, make sure that there's a message towards the top left of the page that says "Welcome to the iGoogle Developer sandbox." If you don't see that message, you're not in the sandbox. If you have to, navigate to <a href="http://www.google.com/ig/sandbox" target="_blank">http://www.google.com/ig/sandbox</a>. You may have to "sign up" again to drop into the sandbox.</p>
<p>Once there, you can add those developer tools. Just clicking <a href="http://www.google.com/ig/sharetab?atr=Developer%20Tools&amp;n_32=url%3Dhttp://hosting.gmodules.com/ig/gadgets/file/107532026754505494237/updates.xml&amp;n_32=url%3Dhttp://hosting.gmodules.com/ig/gadgets/file/105542374478112771668/sandbox-friends.xml&amp;n_32=url%3Dhttp://hosting.gmodules.com/ig/gadgets/file/107532026754505494237/sandboxProfileEditor.xml&amp;n_32=url%3Ddeveloper.xml" target="_blank">this link</a> will get you started.</p>
<p>The developer widgets are:</p>
<ul>
<li>My Gadgets: let's you set inlining and caching on the Gadgets on your page from a handy interface</li>
<li>Sandbox Profile Editor: let's you modify your profile in the sandbox so you can test a few things out.</li>
<li>Sadbox Friends: lets you view and edit who your friends are. Important for OpenSocial applications.</li>
<li>Updates:shows activities posted to your friends while interacting with the gadget.</li>
</ul>
<p><strong>The Hello World Gadget</strong></p>
<p>In this part we're not doing anything OpenSocial related. We're just setting up a Google Gadget. That's a necessary first step for the OpenSocial stuff.</p>
<p>Let's get started. In my example I'll be working in <code>~/src/HelloGadget</code>. Create a <code>lib</code> directory and put the <code>gwt-gadgets.jar</code> library file from the GWT Gadgets API project in it. Next, we run the GWT <code>projectCreator</code> to create our ant and Eclipse files:</p>
<pre>./projectCreator -ant HelloGadget -eclipse HelloGadget -out ~/src/HelloGadget/ -addToClassPath ~/src/HelloGadget/lib/gwt-gadgets.jar
Created directory /Users/dkappe/src/HelloGadget/src
Created directory /Users/dkappe/src/HelloGadget/test
Created file /Users/dkappe/src/HelloGadget/HelloGadget.ant.xml
Created file /Users/dkappe/src/HelloGadget/.project
Created file /Users/dkappe/src/HelloGadget/.classpath</pre>
<p>Now we create a simple sample application using the <code>applicationCreator</code> tool:</p>
<pre>./applicationCreator -eclipse HelloGadget -out ~/src/HelloGadget/ -addToClassPath ~/src/HelloGadget/lib/gwt-gadgets.jar com.pathf.demo.app.gwt.client.HelloGadget
Created directory /Users/dkappe/src/HelloGadget/src/com/pathf/demo/app/gwt
Created directory /Users/dkappe/src/HelloGadget/src/com/pathf/demo/app/gwt/client
Created directory /Users/dkappe/src/HelloGadget/src/com/pathf/demo/app/gwt/public
Created file /Users/dkappe/src/HelloGadget/src/com/pathf/demo/app/gwt/HelloGadget.gwt.xml
Created file /Users/dkappe/src/HelloGadget/src/com/pathf/demo/app/gwt/public/HelloGadget.html
Created file /Users/dkappe/src/HelloGadget/src/com/pathf/demo/app/gwt/public/HelloGadget.css
Created file /Users/dkappe/src/HelloGadget/src/com/pathf/demo/app/gwt/client/HelloGadget.java
Created file /Users/dkappe/src/HelloGadget/HelloGadget.launch
Created file /Users/dkappe/src/HelloGadget/HelloGadget-shell
Created file /Users/dkappe/src/HelloGadget/HelloGadget-compile</pre>
<p>You now have a nice little application that you can run using the hosted mode script <code>HelloGadget-shell</code> in the <code>src/HelloGadget</code> directory. Congratulations, you have a sample GWT application.</p>
<p>But we want a Google Gadget. In order to make it a gadget, we have to change the code a bit. First, import the project into Eclipse. Then open the <code>HelloGadget.gwt.xml</code> and add the following inherit statement.</p>
<pre class="xml"><span style="color: #009900;"><span style="color: #808080; font-style: italic;">&lt;!-- Other module inherits                                      --&gt;</span></span>
	  <span style="color: #009900;"><span style="color: #808080; font-style: italic;">&lt;!-- Inherit Google Gadgets API --&gt;</span></span>
	  <span style="color: #009900;"><span style="font-weight: bold; color: black;">&lt;inherits</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;com.google.gwt.gadgets.Gadgets&quot;</span> <span style="font-weight: bold; color: black;">/&gt;</span></span></pre>
<p>Now let's open up the <code>HelloGadget.java</code> file. We're going to change it around a bit so it can be a gadget. The critical part of the original looks like this.</p>
<pre class="java5"><span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">class</span> HelloGadget <span style="color: #000000; font-weight: bold;">implements</span> EntryPoint <span style="color: #66cc66;">&#123;</span>
&nbsp;
  <span style="color: #808080; font-style: italic;">/**
   * This is the entry point method.
   */</span>
  <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #993333;">void</span> onModuleLoad<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&#123;</span></pre>
<p>We change our class to extend <code>Gadget</code> and change the <code>onModuleLoad</code> method to <code>init</code>.</p>
<pre class="java5">@ModulePrefs<span style="color: #66cc66;">&#40;</span>title = <span style="color: #ff0000;">&quot;HelloGadget&quot;</span>, author = <span style="color: #ff0000;">&quot;Dietrich Kappe&quot;</span>, author_email = <span style="color: #ff0000;">&quot;dkappe@gmail.com&quot;</span>, height = <span style="color: #cc66cc;">300</span>, description = <span style="color: #ff0000;">&quot;A simple gadget.&quot;</span><span style="color: #66cc66;">&#41;</span>
<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">class</span> HelloGadget <span style="color: #000000; font-weight: bold;">extends</span> Gadget&lt;UserPreferences&gt; <span style="color: #66cc66;">&#123;</span>
&nbsp;
	<span style="color: #808080; font-style: italic;">/**
	 * This is the entry point method.
	 */</span>
	@<a href="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Override.html"><span style="color: #aaaadd; font-weight: bold;">Override</span></a>
	<span style="color: #000000; font-weight: bold;">protected</span> <span style="color: #993333;">void</span> init<span style="color: #66cc66;">&#40;</span>UserPreferences preferences<span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&#123;</span></pre>
<p>You have to also import the following three classes:</p>
<pre class="java5"><span style="color: #000000; font-weight: bold;">import</span> com.<span style="color: #006600;">google</span>.<span style="color: #006600;">gwt</span>.<span style="color: #006600;">gadgets</span>.<span style="color: #006600;">client</span>.<span style="color: #006600;">Gadget</span>;
<span style="color: #000000; font-weight: bold;">import</span> com.<span style="color: #006600;">google</span>.<span style="color: #006600;">gwt</span>.<span style="color: #006600;">gadgets</span>.<span style="color: #006600;">client</span>.<span style="color: #006600;">UserPreferences</span>;
<span style="color: #000000; font-weight: bold;">import</span> com.<span style="color: #006600;">google</span>.<span style="color: #006600;">gwt</span>.<span style="color: #006600;">gadgets</span>.<span style="color: #006600;">client</span>.<span style="color: #006600;">Gadget</span>.<span style="color: #006600;">ModulePrefs</span>;</pre>
<p><strong>Running the Darned Thing</strong></p>
<p>Done! Well, not quite. While changing the <code>EntryPoint</code> to a <code>Gadget</code> was pretty straightforward, we now need a container to run the thing. Mind you, it will still run in it's current form in hosted mode, but all of those things it's expecting from iGoogle are not going to happen. So it's time to inject it into iGoogle.</p>
<p>Go ahead and compile the code using the shell command <code>HelloGadget-compile</code>. The resulting compiled JavaScript and sundries is under the <code>www</code> directory in your projects home. If you take a look, you'll see a new file that you likely haven't seen before, namely <code>com.pathf.demo.app.gwt.client.HelloGadget.gadget.xml</code>. This is the gadget manifest. Essentially, this is what your gadget container needs to load to display the app. Many of the parameters are set by the parameters to the <code>@ModulePrefs</code> annotation.</p>
<p>Bundle this app up and upload it to your publicly available server. In my case, I've uploaded the app <a href="http://www.pathf.com/sites/pfd/test/HelloGadget/com.pathf.demo.app.gwt.client.HelloGadget.gadget.xml">here</a>. This is the link to the XML file. You can now go to the sandbox and, using the My Gadgets gadget, add it to your sandbox.</p>
<p><a href='http://www.pathf.com/blogs/wp-content/uploads/2008/11/mygadgets.png'><img src="http://www.pathf.com/blogs/wp-content/uploads/2008/11/mygadgets.png" alt="" title="mygadgets" width="300" height="230" class="alignnone size-medium wp-image-1265" /></a></p>
<p>You can tweak some of the settings having to do with caching of he Gadget resources with the MyGadgets gadgets, but more on that later. Next time we'll set up our simple Gadget in various other containers and perform something a little bit more useful with it (but only a little).</p>
<p>As always, comments and questions are welcome.</p>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=7OgXN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=7OgXN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=kIA1N"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=kIA1N" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=op7eN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=op7eN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=npBin"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=npBin" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=TFZCn"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=TFZCn" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/456513935" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/11/gwt-gadgets-and-opensocial-part-2/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/11/gwt-gadgets-and-opensocial-part-2/</feedburner:origLink></item>
		<item>
		<title>Has Many has_many: A Refactoring Story</title>
		<link>http://feeds.feedburner.com/~r/AgileAjax/~3/453128110/</link>
		<comments>http://www.pathf.com/blogs/2008/11/has-many-has_many-a-refactoring-story/#comments</comments>
		<pubDate>Fri, 14 Nov 2008 17:23:09 +0000</pubDate>
		<dc:creator>Noel Rappin</dc:creator>
		
		<category><![CDATA[Agile Ajax]]></category>

		<category><![CDATA[Ruby on Rails]]></category>

		<guid isPermaLink="false">http://www.pathf.com/blogs/?p=1260</guid>
		<description><![CDATA[




Image is a Pieceless Puzzle, from Ceaco


Lately I've been working on a revision of one of my first Pathfinder projects, an internal agile management tool. Along with adding and rearranging some features, I'm also taking the opportunity to modernize some of the Rails 1.2 era code up to new Rails 2.1 and 2.2 features. 
Note [...]]]></description>
			<content:encoded><![CDATA[<div class="right">
<a href="<strong></strong>"><img src="http://www.pathf.com/blogs/wp-content/uploads/2008/11/ceaco.jpg" alt="Ceaco Pieceless Puzzle" border="0" width="228" height="344" class="right"/><img src="" alt="" border="0" width="" height="" class="right"/><br />
</a><br />
<br clear="all"/><br />
<span class="right" style="font-size: smaller"><br />
<a href="http://www.ceaco.com/ceaco/index.php?category=Pieceless%20Puzzles">Image is a Pieceless Puzzle, from Ceaco</a><br />
</span>
</div>
<p>Lately I've been working on a revision of one of my first Pathfinder projects, an internal agile management tool. Along with adding and rearranging some features, I'm also taking the opportunity to modernize some of the Rails 1.2 era code up to new Rails 2.1 and 2.2 features. </p>
<p>Note 1: I don't always (or often) recommend a wholesale update of working code when updating features. But this was a large enough feature change that cleaning up the code is worth the effort. </p>
<p>Note 2: When the time comes for you to perform a major refactoring like this remember that your tests have all the institutional memory about how the application should work. What I actually did was create a new blank project, and copy test files one by one. For each file, I commented all the tests, then uncomment them one at a time, rearranging the test as needed to match the new data model. Sometimes I take the new code directly from the previous version, sometimes I rewrite using a newer or better idiom. This gives me the benefits of test-driven design in my big refactor, while still preserving all the functional specification in my tests. (This seems to work better on models than controller/views, I'll probably have a fuller report next week).</p>
<p><span id="more-1260"></span></p>
<p>There was one particular design decision in the original code that had always bothered me, but I could never think of a better solution. </p>
<p>In this system, the basic unit is the story. A story can belong to several other different entities in the system -- one or more users, an application, a specific iteration, and so on. Each of those entities, obviously has a <code>has_many</code> relationship with stories, and each one has a mostly-common set of functionality needed from that relationship -- how many stories have been done, how many are left, how many stories were done last week, and so on.</p>
<p>My original design placed all those common methods in a <code>StoryGroup</code> module. Each class that used stories had a declaration like this:</p>
<pre style="white-space: pre !important;">
class Application &lt; ActiveRecord::Base
  include StoryGroup
  has_many :stories
  ## and so on
end
</pre>
<p>Within the story group, there were a lot of methods that performed calculations and called back to class methods of Story, in part, that might look like this...</p>
<pre style="white-space: pre !important;">
Module StoryGroup
  def remaining_expected_hours
    Story.expected_hour_total(remaining_stories)
  end 

  def remaining_tasks
    stories.select{ |each| !each.complete? }
  end
end

Class Story
  def self.expected_hour_total(story_list)
    if story_list.blank? then return 0 end
    story_list.to_a.sum(&:expected_hours)
  end
end
</pre>
<p>Honestly, I can't quite recreate the rationale for having the <code>expected_hour_total</code> method as a class method of <code>Story</code>. I think it's because there was a usage within the <code>Story</code> class before there was a need for it among the <code>StoryGroup</code> classes.</p>
<p>I have two main problems with the structure of the old code. First, having to include the module and declare the <code>has_many</code> relationship always struck me as kind of dodgy. Second, calling back to a class method of <code>Story</code> that takes a list of stories as an argument is really ugly looking, and the class methods kind of gunk up the <code>Story</code> class with a lot of calculations that don't necessarily belong there.</p>
<p>Everything works in the old version, but I was pretty sure there was a cleaner way. In the new version I solve both problems (I think). The first problem is solved by taking a page from your basic <code>acts_as</code> plugin. The second problem is solved with named scopes. Named scopes are particularly helpful here, since they apply to both <code>Story</code> as a class and to any <code>has_many :stories</code> associations. As a result, all the common story functionality is easier and clearer to describe.</p>
<p>The new <code>StoryGroup</code> functionality is a module, now placed in the config/initializers directory. This seems a bit verbose, but most of it is the standard boilerplate for an ActiveRecord plugin -- the main functionality will be in the <code>InstanceMethods</code> submodule</p>
<pre style="white-space: pre !important;">
module ActiveRecord
  module HasManyStories

    def self.included(base)
      base.extend(ClassMethods)
    end

    module ClassMethods
      def has_many_stories
        has_many :stories
        include ActiveRecord::HasManyStories::InstanceMethods
      end
    end

    module InstanceMethods
      def remaining_expected_hours
        stories.uncompleted.sum(:expected_hours)
      end
    end

  end
end
ActiveRecord::Base.send(:include, ActiveRecord::HasManyStories)
</pre>
<p>On initialization, the <code>has_many_stories</code> method is added to <code>ActiveRecord::Base</code>. Any ActiveRecord class that calls the method, then gets all the instance methods included within it (I've left out common class methods, because they are not needed for this example)</p>
<p>Adding the story relationship and the common methods is now down to a single line within the class:</p>
<pre style="white-space: pre !important;">
class Application &lt; ActiveRecord::Base
  has_many_stories
end
</pre>
<p>In the new module, the <code>remaining_expected_hours</code> method has changed, now calling the named scope <code>stories.uncompleted</code> rather than a class method. The scope definition itself is straightforward.</p>
<pre style="white-space: pre !important;">
class Stories
  named_scope :uncompleted,
      :conditions => {:state => ["new", "in_progress", "blocked"]}
end
</pre>
<p>As an added bonus, using the scope and appending <code>sum</code> to the scope now does the calculation in the database, which should be faster than the earlier version, which was calculating the sum in Ruby.</p>
<p>I like this cleanup. The individual methods within <code>StoryGroup</code> are now significantly simpler. The named scopes they depend on are also simpler and less distracting in the class then the previous class methods. Because the scopes are compossible, it's much easier to add calculations to the various slices of stories that the system needs.</p>
<p><strong>UPDATE:</strong> to clarify something pointed out in comments. Yes, it would be possible to put all the instance methods in the <code>HasManyStories</code> module as class methods of <code>Story</code>. They would be polymorphic with associations in the same way that named scopes are. I admit I didn't really consider that option in my refactor. I'm conflicted about it -- it's clearly simpler, since it avoids the tricksy module load, but a lot of the methods in <code>HasManyStories</code> seem odd if placed as class methods of <code>Story</code>, that's part of why I wanted to move them in the first place...</p>
<p>What do you think? Have you had a similar problem? Is there a better way to solve it?</p>
<p><hr>
<a href="http://www.pathf.com/">Pathfinder is a software development firm. Hire us to build complex software that's easy to use.</a>
</p>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~f/AgileAjax?a=Hg7bN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=Hg7bN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=dTUPN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=dTUPN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=QKVgN"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=QKVgN" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=vhv7n"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=vhv7n" border="0"></img></a> <a href="http://feeds.feedburner.com/~f/AgileAjax?a=Ue5xn"><img src="http://feeds.feedburner.com/~f/AgileAjax?i=Ue5xn" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/AgileAjax/~4/453128110" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.pathf.com/blogs/2008/11/has-many-has_many-a-refactoring-story/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.pathf.com/blogs/2008/11/has-many-has_many-a-refactoring-story/</feedburner:origLink></item>
	</channel>
</rss>
