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

<channel>
	<title>Cleveland, Curveballs and Common Sense &#187; programming</title>
	<atom:link href="http://www.jimmysawczuk.com/tag/programming/feed" rel="self" type="application/rss+xml" />
	<link>http://www.jimmysawczuk.com</link>
	<description>Putting 2 and 2 together since 1987.</description>
	<lastBuildDate>Wed, 22 May 2013 02:37:29 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.5.1</generator>
		<item>
		<title>Developing asychronously</title>
		<link>http://www.jimmysawczuk.com/2011/12/developing-asychronously.html</link>
		<comments>http://www.jimmysawczuk.com/2011/12/developing-asychronously.html#comments</comments>
		<pubDate>Mon, 05 Dec 2011 14:24:43 +0000</pubDate>
		<dc:creator>Jimmy Sawczuk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[github]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[software]]></category>
		<category><![CDATA[work]]></category>

		<guid isPermaLink="false">http://www.jimmysawczuk.com/?p=1926</guid>
		<description><![CDATA[These days, it&#8217;s not hard to find a Silicon Valley startup that claims, not so modestly, that it&#8217;s changing the world. And while it&#8217;s true that some startups are doing just that, the not-well-kept secret is that most of them aren&#8217;t doing anything productive, much less profitable, but still somehow find ways to get funding. [...]]]></description>
				<content:encoded><![CDATA[<p><a href="http://www.jimmysawczuk.com/wp-content/uploads/2011/12/github.jpg"><img src="http://www.jimmysawczuk.com/wp-content/uploads/2011/12/github-e1322880034851-550x335.jpg" alt="" title="Github" width="550" height="335" class="aligncenter size-large wp-image-1927" /></a></p>
<p>These days, it&#8217;s not hard to find a Silicon Valley startup that claims, not so modestly, that it&#8217;s changing the world. And while it&#8217;s true that some startups are doing just that, the not-well-kept secret is that most of them aren&#8217;t doing anything productive, much less profitable, but still somehow find ways to get funding. But one startup, Github, is unique: not only is it changing the world, but it&#8217;s changing the way startups change the world. Github&#8217;s <a href="https://github.com/about">about page</a> claims it hosts over two million repositories, which include the likes of the <a href="http://github.com/facebook">Facebook SDKs</a>, the <a href="http://github.com/jquery/jquery">popular JavaScript framework jQuery</a>, and the <a href="https://github.com/TTimo/doom3.gpl">open-source release of Doom 3</a>. It was even the primary home to arguably the most important open-source project ever, <a href="http://github.com/torvalds/linux">the Linux kernel</a>, when its usual home was compromised earlier this summer. </p>
<p>And while Github is making a huge difference in how people write, store and track their source code, it&#8217;s also starting to affect how people <i>develop software</i>. This is an important distinction, and failing to optimize the processes and philosophies that you and your team take while developing software can lead to productivity losses just as severe as bad developers or bad bugs. </p>
<p><span id="more-1926"></span></p>
<p>Github&#8217;s most notable employee who has talked about their process is <a href="http://zachholman.com/">Zach Holman</a>, who has <a href="http://zachholman.com/posts/how-github-works">written a few blog posts</a> as well as <a href="http://zachholman.com/talk/how-github-uses-github-to-build-github">given a talk</a> on the subject. His overarching thesis is that optimizing your development process is much like optimizing a piece of software you write: minimize the your blocks by making them asynchronous. This means:</p>
<ul>
<li><b>no meetings</b>, which require developers to <i>synchronously</i> stop what they&#8217;re doing, walk to the conference room, and meet about stuff which may or may not involve them for an indefinite amount of time,</li>
<li><b>no deadlines</b>, which sometimes require developers to <i>synchronously</i> stop what they&#8217;re doing to work on something more pressing,
<li><b>no pings</b>, which distract developers and pull them away from what they&#8217;re working on,</li>
<li><b>no hours</b>, which require developers to start and stop synchronously, and sometimes starts or stops them at suboptimal times, and</li>
<li><b>no managers</b>, who in the best case scenario, try to schedule developers so that they&#8217;re working as asynchronously as possible, but in the worst case, simply get in the way.</li>
</ul>
<p>There&#8217;s not a whole lot of &#8220;radical&#8221; in these ideas, at least not as far as I, a developer, am concerned. I know I work best when I&#8217;m uninterrupted and on my own schedule, and am happiest when I feel autonomous, or that I&#8217;m not depending on anyone else or waiting on anyone else for me to do my job. But hand this list to most traditional businessmen (or software managers) and they&#8217;ll have a different impression.</p>
<h3>Why it works for Github</h3>
<ul>
<li><b>Github works for themselves.</b> As a developer, it&#8217;s pretty rare to work for a company that produces products for end-users, as opposed to a company that produces products for clients. Companies that produce products for clients not only have to do what the clients ask them to do (or risk not getting paid), but clients come from the enterprise, 20th-century world of business, which means spec sheets, pings, hours, meetings and deadlines. On the other hand, companies that produce products for end-users might solicit feedback, and they might even listen to that feedback, but in the end, they&#8217;re making product decisions based on their own interests.
<p>Github is in the unique position of not only producing products for end-users, but they&#8217;re producing products for <i>developers</i>. This distinction means the user base is very narrow, meaning that Github can stay focused on providing features for almost all their users at once, rather than features for business users here and home users over here. Additionally, not every feature has to have the smoothest edges right off the bat, so features can be released, tried, tested, and if they don&#8217;t work, can be put to bed. And since there&#8217;s no direct client relationships, there doesn&#8217;t have to be any deadlines except internal ones, and really, that&#8217;s just a choice.</li>
<li><b>Github is full of really smart people who are all driving towards a similar goal.</b> By creating a product that&#8217;s popular and well-liked by developers, Github has their choice of talent to hire. Not only can they find really smart developers, but they can (and do) find developers who have resonant beliefs to the rest of the company. Hiring developers like this means everyone can settle into their role and figure out how they can contribute best on their own, without a manager getting involved. If Github interviews a potential hire who doesn&#8217;t want to work really hard, and is only in it for the money, they can pass on him, assured that there are more desirable developers eager to take his place. Not all companies have this flexibility, because not all companies are in the position of having a really cool job to offer.
<p>And to be clear, that similar goal isn&#8217;t &#8220;making money&#8221; or &#8220;building value for an exit&#8221;. Github was founded to solve a problem of sharing code between friends, and today, their goal is simply to make developers&#8217; lives easier by removing as many headaches that used to come from version control, issue tracking, and code reviews, as possible. If some employees&#8217; goals were to simply make as much money as possible, then they&#8217;d fight with the more idealist employees who are trying to make a better product over what features need prioritized, and when they need them done (for example: a better ad-serving platform instead of fixing bugs with the code review process).</li>
</ul>
<h3>What the rest of us can do</h3>
<p>It&#8217;s true that we won&#8217;t be abolishing software managers any time soon, nor will most of us be able to eradicate deadlines. But that wasn&#8217;t Zach&#8217;s point in his talks; his point was that Github&#8217;s methods are just an aggressive way of tackling the headaches and blocks that developers face every day. Most of us can&#8217;t take the same amount of steps that Github has, but there are certainly lessons from Github&#8217;s approach that we can apply.</p>
<ul>
<li><b>Software managers&#8217; main goal should be to minimize developer interruptions to maximize their productivity.</b> Joel Spolsky <a href="http://www.joelonsoftware.com/articles/DevelopmentAbstraction.html">writes</a> that developers should be solely focused on developing as much as possible, because the little interruptions add up and eventually lead to lost productivity, most of which can be avoided.
<p>Github sees software managers as getting in the way of the developers, but if you have to have them around (and you do, because most software teams require some management in order to get much done), then they should be trying to get themselves in the way of all the interruptions they can. This means intercepting pings which aren&#8217;t urgent but will knock the developer out of the zone anyway, making sure that each developer is working on something and isn&#8217;t waiting on anyone else, and in the best case, acting as sort of a surrogate developer that can interact with the rest of the company while the developers do their thing on their own time.
</li>
<li><b>Software development processes should be as simple as possible.</b> Many of the headaches that come with software development are a result of the meta tasks: source control, bug tracking, deploying code, etc. Github&#8217;s rule (anything in the <code>master</code> branch is deployable) is simple enough to remember but powerful enough to let developers work on stuff without a fear of breaking anything. Rule #2 in <a href="http://www.joelonsoftware.com/articles/fog0000000043.html">The Joel Test</a> is that developers should be able to make a build in one step, reducing the complexity and chance for human error when deploying code. Github uses their own issue tracking every day, so if something with bug tracking isn&#8217;t simple enough, they know about it quickly, and if they need to deploy code, all they need to do is ask their friendly neighborhood Hubot.
<p>The fact is that software development is not only complex, but it&#8217;s done by humans. Errors and mistakes are going to happen. But they should be avoided where they can, and software development processes are often way more complex than they need to be.</li>
<li><b>Developers should be encouraged to work on their own stuff on the side.</b> This has done wonders for Google, whose 20% time policy is now legendary for the products it&#8217;s incubated in its lifetime. Github&#8217;s policy is seemingly even more liberal, encouraging developers to work on whatever they want to work on just about whenever they want to work on it, even if it doesn&#8217;t turn into anything. This has led to a culture of automation, autonomy, and fun. Automation makes the software development cycle faster and more foolproof; autonomy and fun make developers happy and easier to retain. Keeping developers on a tight leash and not allowing them to experiment and innovate is a bad idea, and will only lead to turnover. The best solution is to encourage as much experimentation as you can afford.</li>
</ul>
<p>While Github might still be a <i>little</i> ahead of the times with some of their ideas, the truth is that most of them are just common sense. And although their recipe to success might not work for your company, adopting some of their principles and ideas can only help.</p>
<hr />
<i>Oh by the way, I have a Github! Check me out at <a href="https://github.com/jimmysawczuk">github.com/jimmysawczuk</a> or on Bitbucket, Github&#8217;s mercurial cousin (pun intended) at <a href="https://bitbucket.org/jimmysawczuk">bitbucket.org/jimmysawczuk</a>.</i></p>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmysawczuk.com/2011/12/developing-asychronously.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>LESS is more</title>
		<link>http://www.jimmysawczuk.com/2011/11/less-is-more.html</link>
		<comments>http://www.jimmysawczuk.com/2011/11/less-is-more.html#comments</comments>
		<pubDate>Thu, 24 Nov 2011 07:29:16 +0000</pubDate>
		<dc:creator>Jimmy Sawczuk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[less]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[tutorial]]></category>
		<category><![CDATA[work]]></category>

		<guid isPermaLink="false">http://www.jimmysawczuk.com/?p=1893</guid>
		<description><![CDATA[We recently finished up the latest major version of a project at work, a web application that allows our clients to view Facebook Page analytics that we generate and empower them to craft their future social media strategy. The project has seen a couple iterations, but for this one, in an effort to make the [...]]]></description>
				<content:encoded><![CDATA[<p><a href="http://www.jimmysawczuk.com/wp-content/uploads/2011/11/default_less.png"><img src="http://www.jimmysawczuk.com/wp-content/uploads/2011/11/default_less-550x320.png" alt="" title="Textmate with some LESS code" width="550" height="320" class="aligncenter size-large wp-image-1895" /></a></p>
<p>We recently finished up the latest major version of a project <a href="http://www.louddoor.com">at work</a>, a web application that allows our clients to view Facebook Page analytics that we generate and empower them to craft their future social media strategy. The project has seen a couple iterations, but for this one, in an effort to make the whole thing simpler, we reworked most of it from the ground up, including a brand new user interface.</p>
<p>But while CSS is a very powerful tool, this web app was going to require a lot of it, using features from every version of CSS. And while &#8220;graceful degradation&#8221; was our methodology to some degree, the last version of this product didn&#8217;t support any browser except Chrome (because of time constraints) and it was made clear that this time, we would need to support all major browsers. This would mean hundreds of rules, nested rules, exceptions to rules, and fixes for The Browser That Shall Not Be Named.</p>
<p>So in an effort to simplify our CSS develop/test/deploy cycle, we decided to employ <a href="http://www.lesscss.org">LESS</a>, an extended CSS with support for nesting, variables, imports, and expressions.</p>
<p><span id="more-1893"></span></p>
<h3>LESS vs. Sass</h3>
<p>I should first mention that we did look at LESS&#8217;s main competitor, <a href="http://sass-lang.com/">Sass</a> (sometimes known as SCSS). Sass has many of the same features, like nesting, variables, mix-ins, etc. The main difference between the two is the compiler: Sass&#8217;s compiler is a Ruby gem (ew!), and LESS&#8217;s compiler is a Node.js package. This might just seem like a personal taste at first, but the fact that LESS&#8217;s compiler is Node.js means it&#8217;s a version of Javascript, which means it can be run in the browser, which means compilation can happen on the fly, on the client side. This is great for development, although not necessarily a good idea for deployment, but we&#8217;ll get into that later. </p>
<p>In the end though, the biggest reason LESS won out for us was that its syntax isn&#8217;t a superset of CSS, like Sass. This makes writing LESS feel way more natural, like an improved version of CSS, rather than a whole new language.</p>
<h3>Getting started</h3>
<p>So what does LESS look like? At its most basic form, it&#8217;s just CSS: any valid CSS is also valid LESS.</p>
<p><script src="https://gist.github.com/1390718.js?file=CSS_pre_less.css"></script></p>
<p>But this isn&#8217;t very interesting, so we&#8217;ll improve it to something that makes the switch to LESS a little more worth our while.</p>
<p><script src="https://gist.github.com/1390718.js?file=less_initial.less"></script></p>
<p>Hopefully that code is a lot easier on the eyes. When it&#8217;s compiled, it produces the exact same CSS code as above, but rather than having to spell out each level of cascading CSS on each line so it makes sense to browsers, we can nest them in a way which makes sense to developers, with proper scope.</p>
<p>But we can make it even better.</p>
<p><script src="https://gist.github.com/1390718.js?file=less_with_functions.less"></script></p>
<p>And now you should start to see some of the power behind LESS. By making a <code>border-radius</code> function, we can avoid having to write vendor prefixes more than once. In addition, you&#8217;ll notice I wrote the same function twice (overloaded it), so we can choose to call <code>border-radius</code> with one argument if all the radii are the same, or four if they&#8217;re different. LESS&#8217;s mix-ins do much the same thing: you invoke it in a selector, some LESS takes its place, only mix-ins don&#8217;t have arguments.</p>
<p>Another cool thing about LESS is how you can do imports. We used this extensively in our project, by breaking up our style into a bunch of different LESS files and then writing one wrapper file that imported every LESS stylesheet it needed. The main difference here is that in LESS, imports don&#8217;t require an additional HTTP request; they&#8217;re simply loaded in and compiled (like the way PHP handles includes) and served or output as one big file. This is a nice feature to reduce pageload times, but it comes with a tradeoff, as you don&#8217;t necessarily need to load every single style you define for the entire site for every single page. Our technique was to load the styles that were part of the template as one <code>&lt;link&gt;</code>, and the styles that were specific to that page as another. (Potential gotcha: The Browser That Shall Not Be Named&#8217;s <a href="http://www.thecssdiv.co.uk/2009/08/28/another-weird-ie6-bug/">4096 selectors &#8220;feature&#8221;</a>.) Our project, as I look at the code right now, has about twenty LESS files which compile to only six CSS files, so we get the flexibility and organization of working with a lot of files, but the speed of loading a small amount of files.</p>
<h3>Developing/testing/deploying</h3>
<p>I haven&#8217;t even talked about variables, expressions or some of the useful built-in functions, but <a href="http://www.lesscss.org">the official site</a> does a nice job covering those so I won&#8217;t. What I&#8217;d like to talk about is how we used LESS in our development process and how we deploy it in a fast, low-friction way.</p>
<p>Including a LESS stylesheet in your HTML is pretty simple:</p>
<p><script src="https://gist.github.com/1390718.js?file=less_compile_js.html"></script></p>
<p>And this is fine for developing and testing. And it&#8217;d be fine for deployment, except it&#8217;s relying on the client to render the stylesheet correctly, and as we know, relying on users is never a good idea. This method didn&#8217;t work at all for some of our LESS sheets in The Browser That Shall Not Be Named, and even if a user is using Chrome, a rogue extension or the user&#8217;s disabling of Javascript might prevent this style from rendering. And in the best case, the Javascript renderer is slow because it has to run Javascript and <i>then</i> render the CSS, instead of just loading a static CSS file and rendering that.</p>
<p>So the preferred solution for deployment is compilation to static CSS files, and referencing those from the HTML. LESS has a command-line compiler, which you can install from the Node.js package manager (you can use these commands on a Mac, you&#8217;ll need different ones if you&#8217;re on Linux, and if you&#8217;re on Windows you&#8217;ll have to get crazy and use an installer):</p>
<p><script src="https://gist.github.com/1390718.js?file=install_lessc.bash"></script></p>
<p>And then, to compile a LESS file, you simply run one or both of these commands (shown here for Mac or Linux, but something similar should work on Windows):</p>
<p><script src="https://gist.github.com/1390718.js?file=lessc_compilation.bash"></script></p>
<p>The former command produces minified CSS and writes it to a file, while the latter produces inflated CSS.</p>
<h3>Speeding up the workflow</h3>
<p>So this is good, and it&#8217;s relatively simple. Having to install Node.js is sort of a pain, but it&#8217;s not that hard and you only need to do it on your development machines. The problem is remembering to do it. The workflow, right now, to push a simple style update, is to edit the LESS file, compile it to the CSS files, add them if necessary, commit, push and deploy; there&#8217;s a lot of room for human error.</p>
<p>I wasn&#8217;t happy with this, so I set about automating as much of the workflow as I could. I ended up writing a recursive LESS compiler/adder that knew which LESS files needed to be CSS files, and which were just components and so they didn&#8217;t need to be compiled separately.</p>
<p><script src="https://gist.github.com/1390718.js?file=less_compiler.php"></script></p>
<p>This compiler makes a few assumptions:</p>
<ol>
<li>That you can run PHP from the command line.</li>
<li>That you have <b>lessc</b> installed and in your PATH.</li>
<li>That your project uses Mercurial (this is fairly easily avoided/changed).</li>
<li>That the directory you run the compiler from is in a directory with two child directories, <b>less</b> and <b>css</b>, which are where your LESS files reside and where your CSS files will be compiled to.</li>
<li>That you (or the user that&#8217;s running the script) have permission to write to <b>css</b>.
</ol>
<p>It&#8217;s not the prettiest thing, and I plan to improve it, but for now, it works. If you review the code you&#8217;ll notice that it skips files that start with an _ (underscore), so your convention, if you wish to use this compiler, should be that your output files <i>should not</i> start with an underscore, while your includes or helpers <i>should</i> start with an underscore. It also adds files to your Mercurial repository if needed; if you use Git, you should be able to make the change.</p>
<p>To make sure this runs when it&#8217;s supposed to, I set up a pre-commit hook in my Mercurial repository to automatically compile everything:</p>
<p><script src="https://gist.github.com/1390718.js?file=hooks.hgrc"></script></p>
<p>This is a far-from-perfect solution, as it adds time and sometimes compiles unnecessarily, but it&#8217;s sort of tough to determine dependencies, so I figured it was good enough for now.</p>
<p>And finally, I wrote a function that lets you pass in the extension-less style you want to load, and depending on if the site is running in production or development mode, load the minified CSS file via <code>&lt;link&gt;</code> or load the LESS file via <code>&lt;link&gt;</code> as well as <code>less.js</code>.</p>
<p><script src="https://gist.github.com/1390718.js?file=load_stylesheet.php"></script></p>
<h3>Conclusions</h3>
<p>So the final workflow is pretty simple, for me, the developer: make a change to the LESS stylesheet, commit, push, deploy. All of the stuff in the middle is automatic, and until browsers start supporting some form of extended CSS natively (there&#8217;s talk of this happening), it&#8217;s about as good as it gets. </p>
<p>As a hobby project, I&#8217;ve started thinking about developing a LESS compiler in C or C++ which doesn&#8217;t depend on Node.js, because a) dependencies are a buzzkill, and b) writing compilers is fun. With a working, fast, non-dependent compiler, you can move the compilation from a commit on the developer&#8217;s machine (what we&#8217;re at now) to the server and do a just-in-time compilation, with caching, sort of like how <a href="http://code.google.com/p/minify/">minify</a> works now.</p>
<p>Hopefully this has helped a) convince you to check out LESS (or Sass, if you&#8217;re into that sort of thing), b) given you an idea of the problems and hurdles you might face, and c) given you an idea on how to overcome them. I know I don&#8217;t do many technical blog posts, but I&#8217;d like to start doing more of them and I&#8217;d like your feedback on what I could do better. Just leave me a comment, send me a tweet, or drop me a line. Thanks for reading, and happy Thanksgiving!</p>
<hr />
<i>Use Textmate? Here&#8217;s a <a href="https://github.com/appden/less.tmbundle">LESS bundle</a> for syntax coloring.</i></p>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmysawczuk.com/2011/11/less-is-more.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Codenamed &#8220;The Experiment&#8221;</title>
		<link>http://www.jimmysawczuk.com/2011/08/codenamed-the-experiment.html</link>
		<comments>http://www.jimmysawczuk.com/2011/08/codenamed-the-experiment.html#comments</comments>
		<pubDate>Thu, 11 Aug 2011 04:24:56 +0000</pubDate>
		<dc:creator>Jimmy Sawczuk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[meta]]></category>
		<category><![CDATA[opensource]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.jimmysawczuk.com/?p=1698</guid>
		<description><![CDATA[Welcome to the new Cleveland, Curveballs and Common Sense, codenamed &#8220;The Experiment&#8221;! Go ahead and take a look around, then come on back and I&#8217;ll show you around. Last year, around this time, I started thinking about redesigning my blog. I was working on implementing a WordPress theme from scratch at work; with Stephen Stanton [...]]]></description>
				<content:encoded><![CDATA[<div id="attachment_1717" class="wp-caption alignleft" style="width: 360px"><a href="http://www.jimmysawczuk.com/wp-content/uploads/2011/08/14.png"><img src="http://www.jimmysawczuk.com/wp-content/uploads/2011/08/14-350x264.png" alt="" title="Version 4.0" width="350" height="264" class="size-medium wp-image-1717" /></a><p class="wp-caption-text">New look, same brilliant writing! ... Oh, don't make that face. It's not like you were paying for it.</p></div>
<p>Welcome to the new <b>Cleveland, Curveballs and Common Sense</b>, codenamed &#8220;The Experiment&#8221;! Go ahead and take a look around, then come on back and I&#8217;ll show you around.</p>
<p>Last year, around this time, I started thinking about redesigning my blog. I was working on implementing a WordPress theme from scratch at work; with <a href="http://www.louddoor.com/team.html">Stephen Stanton</a> (and his boss Josh Laney) providing the graphics and creative vision, all I had to do was write the code that powered a new WordPress site for our Chasing Trophy Whitetails brand. On my end, there were some neat technical things with the theme like an HTML5 image gallery and automatic generation of OpenGraph tags. It seemed pretty fun and pretty easy at the time, and so I quickly became eager to write a theme for my own blog and transfer some of that new knowledge over.</p>
<p>But it&#8217;s not even close to that easy: it takes skill and talent to create and execute a WordPress theme design, and so I flustered for almost a year, coming up with various ideas but nothing good enough to make me want to switch.</p>
<p><span id="more-1698"></span></p>
<p>The change came with <a href="http://www.grantland.com">Grantland</a>, a Bill Simmons-led sports site that launched in July. My first impressions of the site were incredibly positive, and as I thought about it, I realized that the reason I liked the site so much is that the content was very much the star. Article pages are simple and clean, and they make articles easy to read on every device I want: my iPad, my iPod, and my computers. Even the footnotes (which, in Bill Simmons&#8217; fashion of writing, are must-reads and really add a lot to the article) are reformatted appropriately depending on your device and its orientation. So I started thinking: could I come up with a design that maybe isn&#8217;t as flashy as some others out there, but would perhaps make articles I write more attractive to look at and easier to read?</p>
<p>So the experiment here was to determine if I could visualize, design, implement and deploy an attractive, if simple, theme without any creative help whatsoever. Over the last couple weekends I&#8217;ve spent a couple sleepless nights coming up with a new theme, and to be honest, I&#8217;m really pretty happy with what I came up with.</p>
<p>All of the design (except the typography) was done by yours truly, with some structural inspiration from <a href="http://wordpress.org/extend/themes/lightword">Lightword</a>, the theme that graced this site for the last two years. I chose the typography based on what was easy to read and free, and so the two fonts I chose are available in <a href="http://code.google.com/apis/webfonts/">the Google Font API</a>.</p>
<p>I wrote a couple custom widgets: <b>On BitBucket</b> and <b>Ballpark Resumé</b>. <b>Ballpark Resumé</b> is pretty basic right now, but I hope to have time to make it better at some point, and maybe add graphics of some sort to liven up the list a bit. For right now, it&#8217;s just a better formatted link list with rankings. The <b>On BitBucket</b> widget I&#8217;m a bit more proud of, as it queries the BitBucket API for the user&#8217;s (my) activity on the site, and then my code formats the feed into a prettier list (with similar appearance to the Twitter widget right above it &#8211; I use the <a href="http://timeago.yarp.com/">TimeAgo</a> jQuery plugin to generate the relative timestamps). I hope to leverage the BitBucket API further when I get around to rewriting the <a href="http://www.jimmysawczuk.com/projects">projects page</a>, which I didn&#8217;t get to this time.</p>
<p>Here are a couple other highlights:</p>
<ul>
<li><b><a href="#search">Search</a>.</b> The search field starts as dark gray, brightens up when you hover over it, and gets bigger and brightens up more when you focus.</li>
<li><b><a href="http://www.jimmysawczuk.com/contact">About Me</a>.</b> I did get around to reformatting this page, and I&#8217;m pretty happy with the way it came out. (I knew I bought that widescreen camera for a reason.)</li>
<li><b>The social widgets.</b> One of the goals with my redesign was to make the site more <a href="http://ogp.me/">OpenGraph</a> friendly, so now each post gets the right tags automatically instead of Facebook having to guess at them. The social widgets that now appear on the left hand side of the post move with you as you scroll, if you&#8217;re on a single post (the movement is a little glitchy right now, I&#8217;m working on it).</li>
<li><b>Comments.</b> It&#8217;s not that I was too <i>lazy</i> to write a comments form and skin, it&#8217;s that I was&#8230; well, okay, I was too lazy. But the <a href="http://developers.facebook.com/docs/reference/plugins/comments/"><code>fb:comments</code></a> social plugin has been implemented by some major sites, including <a href="http://www.techcrunch.com">TechCrunch</a>, and I&#8217;ll be darned if I&#8217;m not a follower. So I use Facebook for comments, although I believe you can comment through other channels if you want (and I think there&#8217;s a way to turn on anonymous commenting, I&#8217;ll look into that).</li>
</ul>
<p>I have a couple other things I&#8217;d like to work on, including a new projects page, optimizing the JavaScript and CSS and better support for all the non-Chrome browsers. But I thought I&#8217;d rather release this now, 98% complete, rather than waiting six months when I finally get around to these issues. </p>
<p>As with most other things I&#8217;m working on on my own right now, I&#8217;ve <a href="http://code.jimmysawczuk.com/blog-wordpress-theme">open-sourced my theme on BitBucket</a>. The code&#8217;s not in great, reusable condition right now but I do hope to improve it over time.</p>
<p>As I said, I&#8217;m pretty happy with what I came up with, but I&#8217;m always eager to hear feedback, good or bad. So <a href="#comments">leave a comment</a>, <a href="http://www.twitter.com/JimmySawczuk">tweet me</a> or <a href="mailto:blogredesign@jimmysawczuk.com">send me an e-mail</a> with your feedback. Thanks, as always, for reading! I&#8217;ll get back to your regularly scheduled content in the next post.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmysawczuk.com/2011/08/codenamed-the-experiment.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>A challenger appears</title>
		<link>http://www.jimmysawczuk.com/2011/08/a-challenger-appears.html</link>
		<comments>http://www.jimmysawczuk.com/2011/08/a-challenger-appears.html#comments</comments>
		<pubDate>Mon, 01 Aug 2011 13:41:20 +0000</pubDate>
		<dc:creator>Jimmy Sawczuk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[facebook]]></category>
		<category><![CDATA[google]]></category>
		<category><![CDATA[opensource]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[technology]]></category>

		<guid isPermaLink="false">http://www.jimmysawczuk.com/?p=1664</guid>
		<description><![CDATA[If you look on my company&#8217;s team page, you&#8217;ll find my picture captioned &#8220;Overrater&#8221;. I take this caption somewhat in stride, because being involved in developing many of the analytic algorithms at our office means that I&#8217;m spending a lot of my days &#8220;rating&#8221; client&#8217;s Facebook Pages and presences. The reason the caption is there [...]]]></description>
				<content:encoded><![CDATA[<p><a href="http://www.jimmysawczuk.com/wp-content/uploads/2011/07/google_plus_logo.jpg"><img src="http://www.jimmysawczuk.com/wp-content/uploads/2011/07/google_plus_logo-e1311460792823.jpg" alt="" title="Google+ logo" width="310" height="306" class="aligncenter size-full wp-image-1665" /></a></p>
<p>If you look on <a href="http://www.louddoor.com/team.html" target="_blank">my company&#8217;s team page</a>, you&#8217;ll find my picture captioned &#8220;Overrater&#8221;. I take this caption somewhat in stride, because being involved in developing many of the analytic algorithms at our office means that I&#8217;m spending a lot of my days &#8220;rating&#8221; client&#8217;s Facebook Pages and presences. The reason the caption is there though, is that I have a strong tendency to not be impressed with things most people seem to like (&#8220;Shark Week&#8221;, &#8220;Avatar&#8221;, &#8220;Top Gun&#8221;, college football, to name a few) and call them overrated.</p>
<p>Which brings me to Google&#8217;s new, much touted social network called, simply: Google Plus. Google+ isn&#8217;t Google&#8217;s first entry into the social arena, but it&#8217;s their newest and inarguably their strongest. And while Google enjoyed excellent early reviews as well as an <a href="http://mashable.com/2011/07/12/google-10-million/">early influx of 10 million enthusiastic users</a>, my impressions of Google+ are much less enthusiastic. My initial impressions of what&#8217;s wrong with Google+, after the break.</p>
<p><span id="more-1664"></span></p>
<h3>New interface, same network</h3>
<p>One thing that Google+ certainly got right was its interface, which is, in a word, slick. The News Feed page is well laid out, the Circles page uses some HTML5 magic to enable drag-and-drop circle management, the Profile page is attractive and informative, and Hangouts and group video chatting are well put-together and unique.</p>
<p>But it&#8217;s not original. And this is what Google needs to be concerned about: <i>there isn&#8217;t anything Facebook couldn&#8217;t replicate, if they wanted to, within a month</i>. And until Google+ has more of your friends than Facebook, which is no modest feat, most users are willing to put up with some feature differences and deficiencies in order to reach more of their friends. The same theory applies to Android vs. iPhone, at least early on: most early adopters picked iPhone because, despite the fact that it was on AT&#038;T, there were more apps and the platform was more mature.</p>
<p>In order to prove this fact, I set out to replicate Google+&#8217;s Circles interface using the Facebook friend lists API. I was able to do this pretty easily, and most of my development time was eaten up in a) synchronizing Javascript Facebook API calls properly, and b) revamping the user interface after deciding that a straight rip of Google&#8217;s Circles interface would choke under a large amount of friends. All told, I&#8217;ve probably sank about 8-10 hours of work into my copy, and I&#8217;ve <a href="http://apps.facebook.com/better_lists/" target="_blank">deployed it here</a> and <a href="http://code.jimmysawczuk.com/facebook-circles" target="_blank">open-sourced it here</a> (update: this link is now fixed). The entire app is HTML, CSS and JavaScript, so feel free to grab a copy, install it on a server somewhere, and try it out for yourself. As I noted in the disclaimer, I only really tested the app on Chrome, but it <i>should</i> work in Firefox, Safari, etc., with IE being a bit of a long shot.</p>
<p>In the end, I feel like I came up with a pretty good lists manager, which shows that if someone at Facebook feels like it, they could make a much better lists manager than they have right now, in a short amount of time (and friend lists on Facebook, are, more or less, Circles on Google+). The same goes for every Google+ feature; no Google+ feature is paradigm-altering, it&#8217;s just a fresh take on an old idea.</p>
<h3>No brand love</h3>
<p>Make no mistake, part of the reason Facebook&#8217;s growth really exploded in 2009 was the introduction of Pages. For the first time, brands could have a legitimate presence on Facebook, and could graduate from the role of black sheep in the advertising blocks. As brands rushed to make their presence known in this new channel, they were quick to pollenate their page with fans of their traditional media advertisements, by including lines such as &#8220;Find us on Facebook&#8221; on a TV ad or the Facebook URL on a print ad. As those advertising pushes got more incentivized, non-Facebook users were convinced to join Facebook by the promise of free stuff, like sweepstakes entries, free coupons, etc.</p>
<p>This is an underrated factor in Facebook&#8217;s growth, but shouldn&#8217;t be forgotten. And the fact that Google+ failed to launch with not only a robust solution for brands, but that they launched with a <a href="http://www.huffingtonpost.com/2011/07/25/google-plus-deleting-accounts_n_908818.html">controversial</a> restriction against everyone except genuine, single users is a <i>huge</i> barrier to adoption. </p>
<h3>Limited platform</h3>
<p>The biggest reason Facebook&#8217;s growth exploded is that in 2007, Facebook launched a platform which enabled developers to develop applications for Facebook. Google+&#8217;s initial platform, while existent, certainly isn&#8217;t as substantial as Facebook&#8217;s and doesn&#8217;t allow the embedding of apps within the canvas like Facebook does &#8211; it simply integrates sharing links with your website, like Facebook&#8217;s social plugins. This is fine for now, but it&#8217;s not going to help Google grow the service as much as it&#8217;d like. In the future, Google has announced plans to keep games separate from the rest of Google+. But there&#8217;s a miscalculation here: Google+ users aren&#8217;t typically interested in games, at least not ones on their social network. So really, it remains to be seen how much even a platform will help growth.</p>
<h3>Tumbleweeds</h3>
<p>But perhaps the biggest problem with Google+ is that while a lot of people have accounts, but after the initial excitement, there&#8217;s really just <a href="http://techcrunch.com/2011/07/27/google-minus/">not a whole lot of activity</a>. Thus, users aren&#8217;t logging in every day, and the service becomes forgotten. One of the main reasons Facebook has succeeded the way it has is that, even early on, it has had exceptional retention. The lack of that retention is what&#8217;s hurting Google+ now.</p>
<p>There are a couple ways this can be addressed. First, figure out a fix for the people with multiple Google accounts (Google Apps for your Domain users) so they don&#8217;t see this screen:</p>
<p><a href="http://www.jimmysawczuk.com/wp-content/uploads/2011/07/google_plus_error.png"><img src="http://www.jimmysawczuk.com/wp-content/uploads/2011/07/google_plus_error-550x110.png" alt="" title="GAFYD Google Plus Error" width="500" class="aligncenter size-large wp-image-1682" /></a></p>
<p>Second, integrate Google+ with what is probably Google&#8217;s second-most precious asset right now: Google Chrome. To me, this is something that should have been done from the start, as it would have been a more compelling product and one that Facebook couldn&#8217;t have replicated directly, at least not using Google Chrome (it wouldn&#8217;t surprise me if Facebook was building a browser of their own based on Chromium, Google Chrome&#8217;s open source brother). As a Chrome user, it&#8217;d also keep Google+ in my face all day, almost forcing more activity and more awareness.</p>
<hr />
<p>I&#8217;ve heard the argument that &#8220;Google+ isn&#8217;t competing with Facebook; they&#8217;re two separate products.&#8221; The problem is: the general public won&#8217;t see it that way. Most people don&#8217;t have two social network accounts, and even less have three. With Facebook, Twitter, and now Google+, the social networking field is getting crowded. Google getting 10 million users doesn&#8217;t impress me anymore; they&#8217;ve done that in the past with Wave and Buzz. Google&#8217;s big problem is that it doesn&#8217;t just need 10 million users; it just needs what Facebook has: 130 of your closest friends. </p>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmysawczuk.com/2011/08/a-challenger-appears.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Learn the code. Love the code. Be the code.</title>
		<link>http://www.jimmysawczuk.com/2011/04/learn-the-code-love-the-code-be-the-code.html</link>
		<comments>http://www.jimmysawczuk.com/2011/04/learn-the-code-love-the-code-be-the-code.html#comments</comments>
		<pubDate>Mon, 18 Apr 2011 13:06:37 +0000</pubDate>
		<dc:creator>Jimmy Sawczuk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[mcjournal]]></category>
		<category><![CDATA[nostalgia]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[work]]></category>

		<guid isPermaLink="false">http://www.jimmysawczuk.com/?p=1486</guid>
		<description><![CDATA[When I was born, my Uncle Jim (who has since passed away), who was a newspaper columnist, wrote me a letter welcoming me to the world and introducing me to my family. It was a neat idea (and a tradition I plan to continue), and in the letter, he predicted that because of my genetic [...]]]></description>
				<content:encoded><![CDATA[<div id="attachment_1508" class="wp-caption aligncenter" style="width: 510px"><a href="http://www.jimmysawczuk.com/wp-content/uploads/2011/04/me.jpg"><img src="http://www.jimmysawczuk.com/wp-content/uploads/2011/04/me-550x410.jpg" alt="" title="Me" width="500" class="size-large wp-image-1508" /></a><p class="wp-caption-text">Just another day at the office.</p></div>
<p>When I was born, my Uncle Jim (who has since passed away), who was a newspaper columnist, wrote me a letter welcoming me to the world and introducing me to my family. It was a neat idea (and a tradition I plan to continue), and in the letter, he predicted that because of my genetic makeup, I&#8217;d be an All-American, All-Academic starting linebacker for the Ohio State Buckeyes.</p>
<p>My parents, who probably read the letter the night it was written as opposed to discovering it buried in family photos years later, probably read the letter and chuckled. Given the fact that my parents are both computer programmers, I can imagine one of them saying, &#8220;there&#8217;s no way that kid&#8217;s not a programmer.&#8221; (I&#8217;m not sure what this says about my sister, who will probably cure cancer one day but can&#8217;t defragment a hard drive to save her life.)</p>
<p>And if one of them said that, they were right. I&#8217;ve been fascinated with computers since I was in elementary school, launched my first website back when Albert Belle was slugging home runs for the Indians, started writing programs in middle school, wrote a full web app in high school, and never looked back.</p>
<p>Well, kind of. Because there was definitely a time over a period of the last few months and years where my computer science knowledge stagnated, where my interest in the field was at a low point, and where I just felt burnt out. But lately I&#8217;ve felt that drive again, that addiction to building awesome things that only software engineering can deliver.<br />
<span id="more-1486"></span><br />
The biggest thing I did is that I started learning again. One of the hazards of being in computer science is that since the field is advancing so quickly, you have to work your tail off to keep up-to-date. And sometimes, it&#8217;s nearly impossible, and that makes it discouraging. But you have to learn to live with the fact that you&#8217;ll never know everything, and the best thing you can do is always be learning. There&#8217;s a lot of ways to go about this, but here&#8217;s what I did:
<ul>
<li><b>Reading</b>. I&#8217;ve started to make more of an effort to read technical blogs, blogs from my favorite open-source projects, etc. Blogs like <a href="http://www.joelonsoftware.com/">Joel on Software</a> and <a href="http://www.codinghorror.com/blog/">Coding Horror</a> are cool too, because they make programming seem a lot more glamorous and impressive than it actually is. Even non-technical writing, like books on business or <a href="http://www.amazon.com/Final-Jeopardy-Machine-Quest-Everything/dp/0547483163">books about your favorite Jeopardy-playing computer</a> count. Heck, I was even inspired by watching <i>The Social Network</i>.</li>
<li><b>Personal projects</b>. I had some brainstorms for web apps, saw some neat things with new APIs online, and simply sat down and started working on them. There&#8217;s no better way to learn than by doing, and by the end of it (hopefully) you have something neat to show off to friends.</li>
<li><b><a href="http://www.stackoverflow.com">Stack Overflow</a></b>. This is a relatively new thing for me, but I realized that sometimes, while I don&#8217;t have the time or energy to dive neck deep into a bunch of coding, answering questions on Stack Overflow makes you feel good for helping someone out, challenges you for a few minutes while you think through a solution, and maybe makes you rethink why a certain feature works the way it does. There are a lot of questions that are really easy to answer, but there are even more &#8220;advanced&#8221; questions. And while you might not know the answer, chances are, it will get answered at some point by someone who does.</li>
</ul>
<p>Everyone learns differently, but I think I can speak for all computer scientists when I say learning new stuff is fun and empowering, and a vital part of keeping your job interesting.</p>
<p>I also started, for lack of a better phrase, developing socially. Since early 2008 I&#8217;ve kept all of my work (homework, fun projects, whatever) in private Subversion repositories on my server. Since I was often the only one developing in those repositories, I didn&#8217;t really need the merging, branching or other features that advanced version control provides, just updates and commits. When I started at <a href="http://www.louddoor.com/">LoudDoor</a>, we used Subversion too.</p>
<p>But earlier this year, we switched to <a href="http://www.fogcreek.com/kiln/">Kiln</a>, a hosted version control system based on Mercurial by <a href="http://www.fogcreek.com">Fog Creek Software</a>. Mercurial makes stuff like branching and merging easy and cheap, and commits no longer had to be written to the central repository each time you committed, but instead were written to your own personal repository and pushed up at your leisure. </p>
<p><div id="attachment_1496" class="wp-caption alignright" style="width: 210px"><a href="http://www.jimmysawczuk.com/wp-content/uploads/2011/04/Screen-shot-2011-04-17-at-9.17.28-PM1.png"><img src="http://www.jimmysawczuk.com/wp-content/uploads/2011/04/Screen-shot-2011-04-17-at-9.17.28-PM1-350x142.png" alt="" title="A DAG of the project our team is working on" width="200" class="size-medium wp-image-1496" /></a><p class="wp-caption-text">A DAG of the project our team is working on</p></div>And maybe it was the novelty of it all, or maybe it was the satisfaction of marking issues as resolved in Kiln&#8217;s companion product, FogBugz, or maybe it was just marveling at how cool the DAG looks when a lot of people are working on a project. But all of the sudden, commits felt like an accomplishment, like you were getting stuff done. And that&#8217;s a good feeling.</p>
<p>For my personal projects, I switched to BitBucket, which is a Mercurial version of GitHub, which made the phrase &#8220;social coding&#8221; famous. And the same effect occurred: I was enjoying working on stuff again. And more than that, I now have a <a href="http://code.jimmysawczuk.com">little portfolio</a> of personal projects that I can be proud of. I had a code site before, but it wasn&#8217;t very pretty so I didn&#8217;t really promote it; it was more there for my own use if I needed access to code snippets for whatever reason. But the one on Bitbucket looks nice, encourages contribution, and is much more engaging.</p>
<p>But let&#8217;s be honest: most of your development work comes at the office. And a big part of the reason for my rut was that I was doing the same types of projects, often juggling two or three in a day, that really weren&#8217;t much different from one another and yet were different enough that I couldn&#8217;t automate the whole process. This kind of work would just beat me down over the course of a week so that by the time the weekend rolled around, I was so sick of programming I didn&#8217;t want to be near a computer. I think my immediate boss (our CTO) knew this, but I brought it up to his boss, and once we hired another developer, I was able to move on to longer-term, more fulfilling projects. Sometimes problems are solved that easily; other times, if it doesn&#8217;t look like things are changing the way you want them to, it might be time for a change. (And I get the feeling that the new developer, or &#8220;<a href="http://www.louddoor.com/team.html">Binary Star</a>&#8220;, will eventually feel the same way I do and will want to move up; good developers like being challenged.)</p>
<p>And finally, I got away from the computer and out of the office and house. It may seem counter-intuitive that the way you get back into programming is by getting away from the computer every once in a while, but getting out of the house, getting some exercise, and doing things that aren&#8217;t computer programming help you approach programming with fresh eyes when you come back.</p>
<p>If you&#8217;re a burned-out programmer and you&#8217;re reading this, hopefully some of these options will help. And if not, one of two things are true: either you&#8217;ll come out of it in time, or you&#8217;re not in the right profession. I hope it&#8217;s not the latter, because as I&#8217;ve recently rediscovered, this profession is pretty awesome.</p>
<hr />
<i>Post title is Rule #27 at <a href="http://www.louddoor.com">LoudDoor LLC</a> and should not be used without permission. Actually I&#8217;m just kidding, go for it if you want.</i></p>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmysawczuk.com/2011/04/learn-the-code-love-the-code-be-the-code.html/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>A bug by any other name</title>
		<link>http://www.jimmysawczuk.com/2009/11/a-bug-by-any-other-name.html</link>
		<comments>http://www.jimmysawczuk.com/2009/11/a-bug-by-any-other-name.html#comments</comments>
		<pubDate>Wed, 04 Nov 2009 03:57:56 +0000</pubDate>
		<dc:creator>Jimmy Sawczuk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[apple]]></category>
		<category><![CDATA[macs]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[stevejobs]]></category>

		<guid isPermaLink="false">http://www.jimmysawczuk.com/?p=450</guid>
		<description><![CDATA[I ran across this post today on TechCrunch (er, sorry, I guess it was on MobileCrunch). For those uninterested in reading the full article, I&#8217;ll speak a little bit about the bug, which has the potential to be very costly. Basically, the article states that when you&#8217;re viewing a motion-JPEG (a video format based on [...]]]></description>
				<content:encoded><![CDATA[<p>I ran across <a title="Newly discovered Safari bug could mean big fees for some iPhone users" rel="bookmark" href="http://www.mobilecrunch.com/2009/11/03/newly-discovered-safari-bug-could-mean-big-fees-for-some-iphone-users/">this post</a> today on TechCrunch (er, sorry, I guess it was on MobileCrunch). For those uninterested in reading the full article, I&#8217;ll speak a little bit about the bug, which has the potential to be very costly. Basically, the article states that when you&#8217;re viewing a motion-JPEG (a video format based on JPEG photos &#8211; often found in digital cameras or security cameras) file in Safari on the iPhone and then closing Safari, the browser actually stays open. Mobile Safari will continue to use up bandwidth as it loads the motion-JPEG at the specified interval, and if you&#8217;re on a pay-per-megabyte-downloaded plan, you could foot the bill for thousands of dollars.</p>
<p>The article kind of justifies this bug. After all, it states, it doesn&#8217;t affect you if you&#8217;re on an unlimited plan (because hey, if you have all that extra bandwidth, why not waste it?) and it only seems to occur if you&#8217;re viewing a motion-JPEG (which isn&#8217;t the most common file format, but it&#8217;s not unused either). So, fine. It&#8217;s a bug, it doesn&#8217;t really affect a ton of people that greatly, oh well, right?</p>
<p>Wrong.</p>
<p>The first comment on the article:</p>
<blockquote>
<p>How is this a bug?</p>
<p>The website refreshes…it’s not apples fault the person would have a crazy bill, it’s the user for not closing out the page.</p>
</blockquote>
<p>And here&#8217;s the real beauty of making an Apple product. No matter how bad it sucks, no matter what kind of problems it has, Apple users defend Apple products like they&#8217;re defending their children. This attitude either stems from or causes Apple&#8217;s ridiculous arrogance about its own products. Case in point, here&#8217;s one of the latest Apple commercials:</p>
<p><object width="480" height="295"><param name="movie" value="http://www.youtube.com/v/qpMN-4byxyc&#038;hl=en&#038;fs=1&#038;rel=0&#038;color1=0x3a3a3a&#038;color2=0x999999"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/qpMN-4byxyc&#038;hl=en&#038;fs=1&#038;rel=0&#038;color1=0x3a3a3a&#038;color2=0x999999" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="480" height="295"></embed></object></p>
<p>I&#8217;ll address the commercial first. Here&#8217;s the thing. Apple&#8217;s made a good operating system. <em>It didn&#8217;t happen overnight</em>. If you think this operating system has been rock solid from day one, <a href="http://en.wikipedia.org/wiki/Mac_OS_X#Versions">look again</a>. If you remember, OS X only really started even getting stable at around 10.3, and it got good at around 10.4. The OS has been really a work in progress since 2001, and it&#8217;s had its share of problems. That&#8217;s not to mention Mac OS 9 and below, whose codebase was, for all intensive purposes, abandoned when the company was on the brink of bankruptcy in the late nineties. But that&#8217;s an argument for another day.</p>
<p><span style="background-color: #ffffff;">Let&#8217;s get one thing straight: when you close a program, it should close completely or give you some indication that it&#8217;s still open: in OS X, an open program is a shiny light under the icon in your Dock, in Windows it appears in your taskbar or system tray, etc.  Not only does Safari not give you any feedback that it&#8217;s remaining open, <em>it&#8217;s the only application on the iPhone to do so</em>. It&#8217;s far from expected behavior, and when using an electronic device, users prefer devices that they can guess what&#8217;s going to happen based on their actions.</span></p>
<p>If any users get a bill in the triple digits (in some cases, as noted in the article, over $3000 for an hour of unknown downloading), Apple should pay it themselves. This isn&#8217;t user error. It&#8217;s either by design (for <em>whatever </em>reason), or it&#8217;s a bug. Apple should fix it.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmysawczuk.com/2009/11/a-bug-by-any-other-name.html/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>WWW is the new blog</title>
		<link>http://www.jimmysawczuk.com/2009/10/www-is-the-new-blog.html</link>
		<comments>http://www.jimmysawczuk.com/2009/10/www-is-the-new-blog.html#comments</comments>
		<pubDate>Sat, 24 Oct 2009 13:55:14 +0000</pubDate>
		<dc:creator>Jimmy Sawczuk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[blog]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[wordpress]]></category>
		<category><![CDATA[xna]]></category>

		<guid isPermaLink="false">http://www.jimmysawczuk.com/?p=443</guid>
		<description><![CDATA[A couple of quick programming notes (related to the content of this site, not my actual programming. Actually I guess it is related to my actual programming. So forget I said this.): You may have noticed that blog.jimmysawczuk.com now redirects you here, to www.jimmysawczuk.com. I did this to create a more unified feel for my [...]]]></description>
				<content:encoded><![CDATA[<p>A couple of quick programming notes (related to the content of this site, not my actual programming. Actually I guess it is related to my actual programming. So forget I said this.):</p>
<ul>
<li>You may have noticed that <a href="http://blog.jimmysawczuk.com">blog.jimmysawczuk.com</a> now redirects you here, to <a href="http://www.jimmysawczuk.com">www.jimmysawczuk.com</a>. I did this to create a more unified feel for my web presence, hopefully it&#8217;s more helpful for what you&#8217;re looking for. I&#8217;m still working on it, so let me know if you have suggestions or concerns.</li>
<li>Because I moved some files around I needed to rebuild certain projects so that they could be downloaded from the server off the installer, so I rebuilt <a href="http://www.jimmysawczuk.com/projects#invaders">Invaders</a> and <a href="http://www.jimmysawczuk.com/projects#georgeinspace">George In Space!</a>. If you haven&#8217;t checked them out yet, you should &#8211; they&#8217;re probably the two most useful programs I&#8217;ve ever made.
<p><div id="attachment_400" class="wp-caption aligncenter" style="width: 360px"><a href="http://www.jimmysawczuk.com/projects#invaders"><img class="size-medium wp-image-400 " title="Invaders" src="http://www.jimmysawczuk.com/wp-content/uploads/2009/10/invaders_ss1-350x273.jpg" alt="invaders_ss1" width="350" height="273" /></a><p class="wp-caption-text">Invaders</p></div></li>
</ul>
<p>As always, thanks for your feedback, and above all, thanks for reading!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmysawczuk.com/2009/10/www-is-the-new-blog.html/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Whiplash</title>
		<link>http://www.jimmysawczuk.com/2009/10/whiplash.html</link>
		<comments>http://www.jimmysawczuk.com/2009/10/whiplash.html#comments</comments>
		<pubDate>Fri, 16 Oct 2009 21:27:53 +0000</pubDate>
		<dc:creator>Jimmy Sawczuk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[mcjournal]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[scalability]]></category>
		<category><![CDATA[sql]]></category>

		<guid isPermaLink="false">http://blog.jimmysawczuk.com/?p=366</guid>
		<description><![CDATA[<a href="http://blog.jimmysawczuk.com/wp-content/uploads/2009/10/hosting-servers.jpg"><img class="aligncenter size-full wp-image-367" title="Servers" src="http://blog.jimmysawczuk.com/wp-content/uploads/2009/10/hosting-servers.jpg" alt="Servers" width="400" height="300" /></a>We ran into a problem at work last week that was, at the same time, a nightmare and exactly the kind of problem you want to have.

The culprit was our latest <a href="http://www.facebook.com/BigPrize">Big Prize Giveaways</a> promotion, and the problem was that our app had metaphorically gone from 0-60 in about two seconds, and it experienced the same thing your neck feels when it accelerates that fast: whiplash.]]></description>
				<content:encoded><![CDATA[<p><em>This post was originally written as a guest post for <a href="http://rybomedia.com/2009/10/whiplash/">RyboMedia</a> on October 15, 2009. Thanks to <a href="http://www.rybomedia.com">Rybo</a> for letting me post this! Hope you all found it enjoyable and informative.</em></p>
<p><a href="http://blog.jimmysawczuk.com/wp-content/uploads/2009/10/hosting-servers.jpg"><img class="aligncenter size-full wp-image-367" title="Servers" src="http://blog.jimmysawczuk.com/wp-content/uploads/2009/10/hosting-servers.jpg" alt="Servers" width="400" height="300" /></a>We ran into a problem at work last week that was, at the same time, a nightmare and exactly the kind of problem you want to have.</p>
<p>The culprit was our latest <a href="http://www.facebook.com/BigPrize">Big Prize Giveaways</a> promotion, and the problem was that our app had metaphorically gone from 0-60 in about two seconds, and it experienced the same thing your neck feels when it accelerates that fast: whiplash.<br />
<span id="more-366"></span><br />
This was my first experience with an app that was this big; even in my <a href="http://blog.jimmysawczuk.com/2007/09/transition.html">McJournal</a> days, I rarely averaged more than <span style="text-decoration: line-through;">60,000</span> (well, take that number and divide by 10,000 and you have the real number) hits per day. So in the last week, I&#8217;ve learned a ton during our march to a million fans that I think can be useful to everyone, no matter how close your app is to that kind of scale.</p>
<ul>
<li>This is the first rule in <em>Hitchhiker&#8217;s Guide to the Galaxy</em>, so it&#8217;s the first rule here: <strong>don&#8217;t panic</strong>. My first (extremely narcissistic) thought was &#8220;what? Something broke? Our server sucks!&#8221;, and my second (seriously overdramatic) thought was &#8220;I tried my best when I was writing it, how am I supposed to improve it now?&#8221; Most scaling problems are definitely manageable, and even though (for me) they&#8217;re not much fun and can be stressful, there are worse problems to have.</li>
<li><strong>Have a plan</strong>. These types of problems aren&#8217;t quick fixes, you&#8217;ll need to know what you want to do, how you intend to do it, and when. Keep in mind that unless you shut down your app completely, the slowdowns will continue to affect you as you work through the problem, so having a plan is crucial so you avoid wasting time thrashing.</li>
<li><strong>Use <code>EXPLAIN</code> liberally.</strong> You should do this to every query you run and make sure nothing jumps out at you. Many of my queries were non-indexed, meaning that while the query would be quick to run with only 50,000 contest entries, as the entries piled up and became more frequent and less distinct, even fast queries slowed down. And when your app is doing 50 queries per second, an increase of even 10 ms to a query will start to snowball and drag your app to a crawl. Point is, you should run <code>EXPLAIN</code> on your queries to ensure they&#8217;re doing what you expect them to.</li>
<li><strong>Index intelligently.</strong> Our CTO, <a href="http://www.jimsc.com">Jim Rubenstein</a> (who was the one teaching me a lot of this stuff as we worked through these issues) mentioned that for each <code>SELECT</code> query you run, you should have an index defined. This is particularly true on high volume <code>SELECT</code> queries. Indexing costs a little when you insert and costs some extra hard drive space, but in a day and age with multi-terabyte sized hard drives, some extra <code>INSERT</code> work is easy to work around.</li>
<li>Better than even <code>EXPLAIN</code>ing and indexing, you should <strong>write your app so it uses the fewest database queries possible</strong>. This doesn&#8217;t just mean reducing database queries per page load (although that&#8217;s important too), it means using tools like <a href="http://danga.com/memcached/">memcached</a> whenever possible to reduce the number of unnecessary or redundant queries to the database. memcached simply stores stuff in RAM as needed, and while the concept is simple, intelligently caching your data greatly reduces the number of database queries you have to make. Many of our sites at work use memcached, and we are looking into using a tool developed by Facebook called <a href="http://developers.facebook.com/scribe/">Scribe</a> to do the same thing with <code>INSERT</code>ing data that memcached does with <code>SELECT</code>s. When I first started work a few months ago, I had never used any real caching algorithms or practices in any of my projects, but now it&#8217;s one of my favorite problems to solve and one of the most fascinating.</li>
<li><strong>Learn about configuring your web server to handle more traffic. </strong>Most web servers (including Apache) are configured by default to be able to run on a server that divides its resources among other software, like a database. If you have the flexibility to allow your server more space in RAM, more CPU cycles and more hard drive space, open &#8216;er up and let your server work harder. To do this in Apache, we had to alter the <code>ServerLimit</code> and <code>MaxClients</code> Apache directives, although it may vary for you depending on what version of Apache you have. Do some research on the web to find the ideal settings and set them appropriately.</li>
<li>When all else fails, <strong>throw hardware at the problem</strong>. Without going into the details of our configuration, we scaled our webserver (which is a beast of a server, by the way) to four webservers that are load-balanced. Since implementing this scheme, along with the earlier fixes, we have had few problems. Let me say though, that unless your app or site is huge, there&#8217;s probably more optimizations to be done before this option.</li>
</ul>
<p>I think the most important piece of advice I can give you is to not panic. As Jim and I worked through this last week he noted that it&#8217;s a good problem to have, and that&#8217;s true. After all, if you&#8217;re getting slammed, it means people are finding compelling reasons to use your app, correct? Our president (who&#8217;s had a lot more experience than us) said also that with these kind of problems, you face growing pains but you fix them on the fly and you learn. I think it&#8217;s also true that until your app is on the web, there&#8217;s no telling how it&#8217;ll perform, and no matter how much you test, no matter how much you benchmark, stuff is bound to go wrong &#8211; it&#8217;s just a matter of coming back and making it better.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmysawczuk.com/2009/10/whiplash.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>UPDATE: Developing Socially</title>
		<link>http://www.jimmysawczuk.com/2009/09/developing-socially.html</link>
		<comments>http://www.jimmysawczuk.com/2009/09/developing-socially.html#comments</comments>
		<pubDate>Tue, 29 Sep 2009 19:16:50 +0000</pubDate>
		<dc:creator>Jimmy Sawczuk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[facebook]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[refreshcolumbia]]></category>

		<guid isPermaLink="false">http://blog.jimmysawczuk.com/?p=351</guid>
		<description><![CDATA[Just a quick post to let everyone who&#8217;s interested know that I&#8217;ll be giving a talk tomorrow at Refresh Columbia. More details can be found in this post, but I&#8217;ll be talking about Facebook development and how it can impact your Facebook Page. I&#8217;ll post some source code and my slides on this post once [...]]]></description>
				<content:encoded><![CDATA[<p>Just a quick post to let everyone who&#8217;s interested know that I&#8217;ll be giving a talk tomorrow at <a href="http://www.refreshcolumbia.org">Refresh Columbia</a>. More details can be found in <a href="http://www.refreshcolumbia.org/meetings/september-2009-meetup/">this post</a>, but I&#8217;ll be talking about Facebook development and how it can impact your Facebook Page. I&#8217;ll post some source code and my slides on this post once it&#8217;s over. Hope to see you there!</p>
<p><strong>UPDATE: </strong>Code and slides after the jump.</p>
<h3><span id="more-351"></span>Code</h3>
<p>Here&#8217;s the code: <a href="http://blog.jimmysawczuk.com/wp-content/uploads/2009/09/refreshcolumbia-demo.zip">refreshcolumbia-demo</a>. I commented it reasonably well, but if you have questions feel free to tweet, e-mail or leave a comment on this blog. Use it however you want, I&#8217;m not liable, yada-yada-yada.</p>
<h3>Slides</h3>
<p>Here they are, in PDF format: <a href="http://blog.jimmysawczuk.com/wp-content/uploads/2009/09/Developing-Socially.pdf">Developing Socially</a>.</p>
<p>Hope everyone who was there enjoyed the talk, I enjoyed giving it. Please give me any feedback you have, I think it&#8217;d be kind of cool to improve it and give it again at another venue. Thanks again!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmysawczuk.com/2009/09/developing-socially.html/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Two choices</title>
		<link>http://www.jimmysawczuk.com/2009/08/two-choices.html</link>
		<comments>http://www.jimmysawczuk.com/2009/08/two-choices.html#comments</comments>
		<pubDate>Fri, 21 Aug 2009 11:30:51 +0000</pubDate>
		<dc:creator>Jimmy Sawczuk</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[design]]></category>
		<category><![CDATA[facebook]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[internetexplorer]]></category>
		<category><![CDATA[productivity]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[software]]></category>
		<category><![CDATA[twitter]]></category>

		<guid isPermaLink="false">http://blog.jimmysawczuk.com/?p=307</guid>
		<description><![CDATA[I don&#8217;t normally write about higher level software design for a couple of reasons. For one, I don&#8217;t consider myself to be an expert in the field. I&#8217;m not sure there is any one expert in the field, actually; it&#8217;s a little bit like saying there&#8217;s an expert in string theory, a field that&#8217;s less [...]]]></description>
				<content:encoded><![CDATA[<p>I don&#8217;t normally write about higher level software design for a couple of reasons. For one, I don&#8217;t consider myself to be an expert in the field. I&#8217;m not sure there is any one expert in the field, actually; it&#8217;s a little bit like saying there&#8217;s an expert in <a href="http://en.wikipedia.org/wiki/String_theory">string theory</a>, a field that&#8217;s less that fifty years old and every bit as complex as software design. However, I don&#8217;t really consider myself above average at it either, and if I&#8217;m not above average at it, there&#8217;s not usually anything I could say that you couldn&#8217;t read somewhere else, better explained and more original.</p>
<p>The second reason I don&#8217;t normally write about software design is that since most of my projects are small (projects at work are either designed in collaboration or already designed), I don&#8217;t waste much time on design. Today I modified a GreaseMonkey script <a href="http://sysop073.blogspot.com">Mike</a> wrote to remove ads from GrabUp posts; he wrote it because he was sick of looking at ads, I modified it because I was tired of the refresh caused by redirecting to the direct image. I didn&#8217;t write out a vision and scope document, I didn&#8217;t create a design document, I didn&#8217;t diagram it &#8211; I just wrote it. Another example is my recent weekend project <a href="http://www.toolongfortwitter.com">TooLongForTwitter.com</a>. It&#8217;s a little larger in scope, but rather than figuring out how everything was going to work beforehand by diagramming it out, designing a database, etc., I just started writing it and it all just kind of came together. Even back when I was writing McJournal, I had an idea in my head of how the final product would look but I never wrote it down anywhere, I just started writing.</p>
<p>Point is, it&#8217;s pretty easy to skip that design process which can greatly influence the success of your product. As I thought about it this evening, I realized that all software products fall into two categories.</p>
<p>The first category are <strong>the applications that are designed not to suck</strong>. We all use software for many different purposes, but a lot of times, we&#8217;re using it for work or productivity. Hence, products like Microsoft Office, Quicken, GMail, TextMate, etc. are designed as software that stays out of your way. Either it lets you perform tasks the way you want, or it gently nudges you once and then leaves you alone. Nothing is more annoying in this case than the application that&#8217;s trying to do too much (Clippy: &#8220;It looks like you are writing a letter&#8230;&#8221; anyone?). Applications that are designed for productivity usually fall into this category, because normally you want to get your work done, then get off the computer and head out to the golf course. The key word with these types of applications is <strong>intuition</strong>: it should be intuitive for the user to use.</p>
<p>The other category is <strong>the applications that are designed to rock</strong>. As you might imagine, these are normally entertainment applications like video games or multimedia applications. These are applications that the user wants to use, applications that the user wants to learn, and applications where the user may want helpful tips. For example, take Halo 3. The game would have been a bestseller without adding a bunch of new weapons, a bunch of new gadgets and a bunch of new customization options in multiplayer mode, but because the game added those little features, it was smash hit and is still played today. Entertainment applications can&#8217;t be simply functional to be successful; they&#8217;ve got to be <strong>immersive</strong>.</p>
<p>Ever wonder why Twitter is emerging as a more popular social networking tool for professionals and celebrities compared to Facebook? <strong>It&#8217;s simple</strong>. Using it is as simple as sending an SMS message from your phone or typing 140 characters in one form field on the web. Want to share a link? No problem! Just copy and paste it in there and <strong>done</strong>. No captchas, no conversion to &#8220;shared items&#8221; like Facebook likes to do, just shows the URL and makes it a link.</p>
<p>On the other hand, Facebook is complex enough already, and it&#8217;s gotten more confusing for the average user over the years. Over the last couple of months I&#8217;ve had the pleasure of introducing my dad and my aunt to Facebook (seriously, <a href="http://www.facebook.com/markzuckerberg">Mark</a>, I&#8217;m fighting for you here, how about throwing some of that money my way?) and I&#8217;ve seen the site through new eyes: even with the wizards, hints, etc., a cautious user may feel overwhelmed when visiting the site for the first time. Facebook realizes this, that&#8217;s why they&#8217;re <a href="http://www.guardian.co.uk/technology/2009/aug/19/facebook-lite-friendfeed">rushing out Facebook Lite to their 250 million users</a>. Interacting with friends, profiles, streams and comments is hard enough; adding Pages and Ads to the equation makes it even more confusing. Thus, professional users or less computer-savvy users are using Twitter for their business communication.</p>
<p>Another example is in web browsers. As many of you may know, <a href="http://arstechnica.com/microsoft/news/2009/08/microsoft-dropping-support-for-ie6-is-not-an-option.ars">Internet Explorer 6 is still alive and kicking on the web</a>. As someone who has faced a ton of IE 6 errors and quirks, I am definitely in favor of getting this browser out of circulation. But generally, people are using IE 6 for one of two reasons: a) <a href="http://mashable.com/2009/08/18/ie6-offenders/">it&#8217;s an office requirement</a>, or b) it works for checking e-mail, news, etc. and that&#8217;s all it&#8217;s needed for. For these users, a browser is a productivity application, not an entertainment application, and IE 6 (unbelievably) &#8220;doesn&#8217;t suck&#8221; too much for them and it requires zero installing, configuring or tweaking to get up and running.</p>
<p>On the other side of the spectrum, Firefox is more of an entertainment browser. Clearly, users use it for productive purposes too, but it&#8217;s clear that Firefox is used as an application that rocks rather than an application that doesn&#8217;t suck: tabbed browsing, add-ons, and a prettier interface are just a few of the reasons younger users tend to use Firefox.</p>
<p>I guess the point of all this is, next time you&#8217;re writing an application, no matter how big or small, ask yourself the following question: <strong>do I want my application to rock or not suck</strong>, or better yet, <strong>do my users want my application to rock or not suck?</strong> Hopefully it helps you iron out your feature list and make it one that your users will expect.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jimmysawczuk.com/2009/08/two-choices.html/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
