<?xml version="1.0" encoding="UTF-8"?><rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title>BryanRay.NET</title><description>Pragmatic, Agile, Development with a range of technologies from Ruby, Rails, Merb, .NET and others.</description><link>http://bryanray.net</link><pubDate>Fri, Jul 2008 17:00:00 CST</pubDate><generator>http://smerb.com?v=0.1.2</generator><language>en</language><item><title>Some changes to Merb edge you should probably know about.</title><link>http://bryanray.net/2008/8/18/some-changes-to-merb-edge-you-should-probably-know-about</link><pubDate>Mon, 08 Aug 2008 00:00:00 CST</pubDate><author>bryan@bryanray.net (Bryan Ray)</author><guid isPermaLink="false">http://www.bryanray.net/2008/8/18/some-changes-to-merb-edge-you-should-probably-know-about</guid><description><![CDATA[<p>While doing a fresh pull of <a href="http://merbivore.com">Merb</a> edge this weekend I realized that all of my forms had suddenly just disappeared and I was also receiving some NoMethod errors; which is never a fun scenario. Just in case you like to develop on edge (and who doesn&#8217;t when it comes to Merb?) you should probably be aware of a few changes that went through this week.</p>


	<p>There was a pretty big refactoring with the form_helpers. In fact, it&#8217;s still a little flaky at the time of this writing.</p>


	<p><strong><span class="caps">UPDATE</span></strong>: It has stabilized over the next couple of days and, according to wycats and GMFlash, should become more solid by the next release (0.9.5 at the time of this writing).</p>


	<p>Previously in merb there were:</p>


	<ul>
	<li>&#8220;_control&#8221; controls* &#8211; These controls signified that it was going to be &#8220;bound&#8221; to a specific attribute on a model.</li>
	</ul>


	<ul>
	<li>&#8220;_field&#8221; controls* &#8211; These were controls which were not bound to a model.</li>
	</ul>


	<p>This refactor completely eliminates all of that complexity. Now there is only one way helper for each control. <em>One helper to bring them all and in the darkness bind them</em>. Sorry I had to do it.</p>


	<p>Here are a list of the new helper methods:</p>


	<ul>
	<li>form (previously this was form_tag)</li>
		<li>form_for (This helper will generate a form that is bound to a specific resource (model)</li>
		<li>button</li>
		<li>submit (previously submit_button)</li>
		<li>text_field, password_field, hidden_field file_field, text_area, select, check_box, radio_button, and radio_group</li>
	</ul>


	<ol>
	<li>The &#8216;form&#8217; and &#8216;form_for&#8217; methods now render output so you&#8217;ll need to prefix it with a %= rather than % and = rather than &#8211; if you&#8217;re using <span class="caps">HAML</span>.</li>
	</ol>


	<p>The way you bind specific attributes to a model is by simply passing a symbol in to the method. You can see this in the private bound? method in the <a href="http://github.com/wycats/merb-plugins/tree/master/merb_helpers/lib/merb_helpers/form/helpers.rb#L196">helpers.rb</a> file.</p>


<pre lang="ruby">
  private

  def bound?(*args)
    args.first.is_a?(Symbol)
  end
</pre>

	<p>Thank you, sweet baby jesus and GMFlash, for this refactor. It really does simplify views that require forms and makes things much cleaner. Suddenly the form helpers just make much more sense to me.</p>


	<p>At the time of this writing there are a couple patches in the pipe:</p>


	<ol>
	<li>There a patch in the intertubes that changes the way &#8216;select&#8217; works. Here is the <a href="http://merb.lighthouseapp.com/projects/7588/tickets/143-select_control-and-select_field-error-when-using-collection-w-one-two-three#ticket-143-8">ticket and the patch</a>. <strong><span class="caps">UPDATE</span></strong>: This has been merged in to the refactoring.</li>
		<li><del>Apparently there is a bug in the way the checkbox control sends it&#8217;s output that does not allow a checked checkbox to ever render a &#8216;true&#8217; (1) value.</del> <strong><span class="caps">UPDATE</span></strong>: My patched was <a href="http://github.com/wycats/merb-plugins/commit/cc6461712b42bf724c53380c35435f9ff9df9287">merged in</a>. You can see the <a href="http://merb.lighthouseapp.com/projects/7588/tickets/145-when-submitting-a-form-that-has-checkbox_control-result-is-always-a-0-value#ticket-145-1">ticket (and patch) here</a> at Lighthouse.</li>
	</ol>


	<h3>Examples</h3>


	<h4>Form Helper (not bound to a model)</h4>


<pre lang="ruby">
&lt;%= form :action =&gt; url(:login) do %&gt;
  &lt;%= text_field :name =&gt; "login", :label =&gt; "Username" %&gt;
  &lt;%= text_field :name =&gt; "password", :label =&gt; "Password" %&gt;
  &lt;%= submit "Log in" %&gt;
&lt;% end =%&gt;
</pre>

	<h4>Form Helper (bound to a model)</h4>


<pre lang="ruby">
&lt;%= form_for @post, :action =&gt; url(:posts) do %&gt;
  &lt;%= text_field :title, :label =&gt; "Title" %&gt;
  &lt;%= text_area :body, :label =&gt; "Body" %&gt;
  &lt;%= check_box :published %&gt;
  &lt;%= submit "Create or Update" %&gt;
&lt;% end =%&gt;
</pre>

	<ul>
	<li>Notice the %= at the beginning and end of the form and form_for methods.</li>
		<li>Notice the :symbol being passed in to the control helper methods to signify a &#8220;bound&#8221; control.</li>
	</ul>


	<h4>select helper (bound)</h4>


	<pre><code>select :foo, :collection =&gt; [['0', 'Text Method 1'], ['1', 'Text Method 2' ]]</code></pre>


	<p>which should generate something like this:</p>


<pre>
  &lt;select name="foo"&gt;
    &lt;option value="0"&gt;Text Method 1&lt;/option&gt;
    &lt;option value="1"&gt;Text Method 2&lt;/option&gt;
  &lt;/select&gt;
</pre>

	<p>The above code didn&#8217;t go through the Ruby interpreter at all. It was all hand typed so please forgive me if there are typos.</p>


	<h3>Important Notes</h3>


	<p>When using the new helper methods to bind to your models. Please note that your models are required to have an errors methods; This error method should be provided by your <span class="caps">ORM</span> of choice (DM or AR).</p>


	<p>So, if your models have:</p>


	<pre><code>include DataMapper::Resource</code></pre>


	<p>then all you need to do in your init.rb file is:</p>


	<pre><code>dependency "dm-validations"</code></pre>


	<p>As always there is much more that these helper methods are capable of, but it will take some digging around to find. You can always check out the <a href="http://www.merbivore.com/documentation.html">merb documentation</a>, stop by the #merb channel, or dig in to the <a href="http://github.com/wycats">merb code</a> yourself!</p>]]></description></item><item><title>Fighting spam with mollom</title><link>http://bryanray.net/2008/8/8/fighting-spam-with-mollom</link><pubDate>Fri, 08 Aug 2008 02:55:50 CST</pubDate><author>bryan@bryanray.net (Bryan Ray)</author><guid isPermaLink="false">http://www.bryanray.net/2008/8/8/fighting-spam-with-mollom</guid><description><![CDATA[<p>As many of you may have noticed I decided to roll my own blog engine in <a href="http://merbivore.com">merb</a> and I have to say the most annoying thing so far &#8230; is <span class="caps">SPAM</span>. My comments have just been inundated with the most absurd comments ever.</p>


	<p>So, I apologize that the site has just been a spam hole for a week or so, but I finally implemented some spam protection via <a href="http://mollom.com">Mollom</a> (which is a similar service to Akismet).</p>


	<p>I&#8217;m not entirely sure how well Mollom is going to work yet, but a couple of the test comments that I&#8217;ve made have been blocked so that&#8217;s a good start. I&#8217;ll be adding in some more data so that Mollom can make some better decisions over the next couple days in hopes to eliminate as much spam as possible.</p>


	<p>Anyways &#8230; just wanted to drop a quick apology for all the viagra and penis enlargement ads that have been flooding the site.</p>]]></description></item><item><title>My new blog engine ... smerb!</title><link>http://bryanray.net/2008/7/28/my-new-blog-engine-smerb</link><pubDate>Mon, 07 Jul 2008 20:02:03 CST</pubDate><author>bryan@bryanray.net (Bryan Ray)</author><guid isPermaLink="false">http://www.bryanray.net/2008/7/28/my-new-blog-engine-smerb</guid><description><![CDATA[<p>Well, I just got my new blog engine published … which I’ve tentatively code named “smerb”. It’s really nothing great right now, but it lets me post articles, provides a simple feed reader, allows for comments and has a simple administrative interface. It’s a nice jump away from WordPress and doesn’t provide all of the bells and whistles, but it’ll work for now.</p>


	<p>The fun part? The technology behind it all! It’s all written in Ruby on the Merb Framework. Using DataMapper as the <span class="caps">ORM</span>, haml as the template language, jQuery for the javascript library and being hosted over on Slicehost. I think the best thing about it is how much I’ve learned about implementing everything.</p>


	<p>There are still a lot of kinks I need to get worked out and transfer over some of the existing data from the WordPress site, but for the most part it’s working pretty well. I changed over my <span class="caps">DNS</span> entries yesterday so I’m sure it will take the weekend for it to propagate through the interwebs.</p>]]></description></item><item><title>Adding some flexibility to sqlite3 and dbconsole</title><link>http://bryanray.net/2008/7/12/adding-some-flexibility-to-sqlite3-and-dbconsole</link><pubDate>Sat, 07 Jul 2008 20:05:50 CST</pubDate><author>bryan@bryanray.net (Bryan Ray)</author><guid isPermaLink="false">http://www.bryanray.net/2008/7/12/adding-some-flexibility-to-sqlite3-and-dbconsole</guid><description><![CDATA[<p>With sqlite3 you can pass in a few arguments to the sqlite3 command to initialize your session with some, in my opinion, better defaults. The sqlite3 command I typically use looks like this:</p>


<pre lang="shell">sqlite3 -column -header [database]</pre>

	<p>This simply puts sqlite3 in to column mode and displays the names of the column (headers) above the table. It reads a lot easier to me. A majority of the time I go in to the sqlite3 database I end up issuing the command:</p>


<pre lang="shell">
mode column
header on
</pre>

	<p>So what I wanted to do was something like this:</p>


<pre lang="shell">./script/dbconsole --mode column --header</pre>

	<p>Seemed easy enough &#8230; but keep in mind, this is just a personal preference, but the current implementation of the ./script/dbconsole command did not allow me to do this:</p>


<pre lang="shell">./script/dbconsole --mode [column, line, list, html] --header</pre>

	<p>I modified the dbconsole script a little bit to allow for this functionality. With this patch you can now issue these optional commands. Obviously if you don&#8217;t provide any of the options the script will just load you in to your default sqlite3 instance and you can go from there.</p>


	<p>It took me about 30 minutes to put this together and I&#8217;m sure there are some things that I&#8217;m missing, but this should at least get you started.</p>


	<p>Please let me know if you make any changes as I would be interested in seeing them.</p>]]></description></item><item><title>The importance of a companies web presence!</title><link>http://bryanray.net/2008/7/4/the-importance-of-a-companies-web-presence</link><pubDate>Fri, 07 Jul 2008 16:35:05 CST</pubDate><author>bryan@bryanray.net (Bryan Ray)</author><guid isPermaLink="false">http://www.bryanray.net/2008/7/4/the-importance-of-a-companies-web-presence</guid><description><![CDATA[<p>I know this might sound strange coming from a developer and someone who feels that they don&#8217;t have an artistic bone in their body, but I still understand the importance of a taking care of your personal appearance as well as your virtual presence. I can&#8217;t stress enough how important it is for companies to take pride in the look and feel of their web  site. This is especially true for companies that are looking for new clients or even looking to hire new employees.</p>


	<p>Recently, I&#8217;ve been browsing through Rails job boards on the <a href="http://weblog.rubyonrails.org/jobs">Ruby on Rails</a> and <a href="http://www.workingwithrails.com/browse/jobs">Working with Rails</a> sites. Typically, the first thing I do is read through the job description to make sure that they really know what they&#8217;re looking for and working on. After reading through a job description my next step is to go to their web site. Oddly enough, this has the <strong>most</strong> weight in the process for me. I consider your web site to be your first impression. To me this is no different than meeting someone in person.</p>


	<p>If I meet someone in person and they&#8217;re rockin&#8217; a mullet (as awesome as that would be), some old school Girbaud jeans, a tank top, Gucci sunglasses, and some Prada boots  ... I&#8217;d be a little reluctant to sit down in a public area and discuss anything with you &#8230; let alone be able to take you seriously about your business.</p>


	<p>Now, don&#8217;t get me wrong &#8230; this isn&#8217;t to say that you need to put on a Versace suit and stroll around town like you&#8217;re made of money either! Not at all. I don&#8217;t really care if you&#8217;re wearing Under Armour and just left the gym, have a faux hawk and just left a concert wearing your favorite bands t-shirt, or you really did step out of a board meeting wearing your work suit. The important thing is that you&#8217;ve put yourself together in a manor that depicts your personal style at that given moment. The web is <strong>no</strong> different and probably even more important than your personal style.</p>


	<h3>You&#8217;re doing it right</h3>


	<p>If I&#8217;m browsing your site and I somehow feel the need to crank up Firebug or the source code to look at the <span class="caps">HTML</span> behind the scenes to see how you&#8217;ve put things together &#8230; you can almost guarantee that I&#8217;m going to submit my resume to your company. Even if you&#8217;re not actively looking for a developer. In fact, I&#8217;ve been known to browse sites and send emails to their contact us address just to tell them how much I appreciate their site design. It really is that crucial for me.</p>


	<p>Or if your site has a good flow to it, well laid out color scheme, good font spacing and size, and just looks like some thought was put in to the design then you&#8217;re on the right track.</p>


	<p>There are so many things that can make a site unique and/or attractive and to me it&#8217;s worth the time, money, and effort to put it together correctly if you&#8217;re relying on your web presence to do any marketing for you.</p>


	<h3>You&#8217;re doing it wrong</h3>


	<p>On the other hand &#8230; if your site has that cookie cutter corporate feel with the standard navigational drop down menus, blueish or orangish color scheme, pictures of people standing around the printer smiling like they&#8217;re at their wedding, because they&#8217;re looking at a document that someone just handed them (seriously?), but you&#8217;re looking for a &#8216;laid back Ruby Rockstar to develop your hot new product management system&#8217; ... you might be doing it wrong.</p>


	<p>To me that&#8217;s like looking for a lead guitarist for your Metallica cover band at an Opera. Sure you have a chance of finding someone who is musically inclined, but are they really interested in slammin&#8217; down Jager Bombs on stage with you screaming out, &#8220;Give me fuel, Give me Fire, Give me that which I desire!&#8221;? Chances are probably slim.</p>]]></description></item><item><title>Site Redesign!</title><link>http://bryanray.net/2008/7/2/site-redesign</link><pubDate>Wed, 07 Jul 2008 06:35:36 CST</pubDate><author>bryan@bryanray.net (Bryan Ray)</author><guid isPermaLink="false">http://www.bryanray.net/2008/7/2/site-redesign</guid><description><![CDATA[<p>My blog is currently running on <a href="http://wordpress.org/">WordPress</a> and I&#8217;ve really been satisfied with it for the most part, but when it comes to putting together your own theme &#8230; all I can say is, &#8216;ouch.&#8217; What a hassle! I could be going about it all wrong, but I&#8217;m not really motivated enough to download the code and get it running on my local box to figure out the ins and outs of WordPress. So, needless to say &#8230; it was a bit painful.</p>


	<p>But in an effort to bring my site in to the 21st century &#8230; I spent some time today working on a redesign. I&#8217;ve often doodled on paper and come up with little sketches for a design. But nothing beats grabbing a few <a href="http://www.mountaindew.com/">Mountain Dews</a>, cracking open Photoshop and TextMate, and beating the <span class="caps">CSS</span>/HTML creativity out of me.</p>


	<p>Honestly, it wasn&#8217;t all that bad. The hardest part about it was trying to trick WordPress in to thinking I was its daddy. The templates are not the cleanest in the world and digging through old <span class="caps">PHP</span> code made me a bit nauseous, but reminded me how much I need to appreciate <a href="http://www.ruby-doc.org/stdlib/libdoc/erb/rdoc/">erb</a>, <a href="http://haml.hamptoncatlin.com/">haml</a>, <a href="http://www.liquidmarkup.org/">liquid</a> and the other template engines.</p>


	<p>I&#8217;d still like to consolidate the front page a little bit and reduce the amount of &#8216;junk&#8217; that&#8217;s getting tossed out on the page. So don&#8217;t be surprised if you&#8217;re browsing around the site and run in to an issue or two. It should be resolved soon.</p>]]></description></item><item><title>You're killin' me, Twitter ...</title><link>http://bryanray.net/2008/6/30/youre-killin-me-twitter-</link><pubDate>Mon, 06 Jun 2008 17:15:01 CST</pubDate><author>bryan@bryanray.net (Bryan Ray)</author><guid isPermaLink="false">http://www.bryanray.net/2008/6/30/youre-killin-me-twitter-</guid><description><![CDATA[<p><img src="http://bryanray.net/wp-content/uploads/2008/06/twitter-whale.png" style="width: 275px; float: right; border: 1px solid black;;" title="Twitter Whale" alt="Twitter Whale" /> I&#8217;ve heard a lot about Twitter&#8217;s <a href="http://www.google.com/search?q=twitter+scaling+problems&amp;sourceid=navclient-ff&amp;ie=UTF-8&amp;rlz=1B3GGGL_enUS264US264">scaling problems</a> (read: bad architecture) lately. Day after day after day people keep talking about why Twitter is constantly having issues, constantly &#8216;whaling out&#8217;, isn&#8217;t scaling, and I love reading all the technical aspects of what people think is happening. But, Twitter, it&#8217;s getting really <strong>old</strong>!</p>


	<p>Need I remind everyone that we live in the 21st century? When did &#8216;scaling&#8217; become such a <span class="caps">HUGE</span> issue? We&#8217;ve got servers that can compute complex algorithms that allow us to travel to distant planets. We&#8217;ve got search engines that handle massive amounts of requests every second. We&#8217;ve got servers that are handling money traveling through our economy, computers that are constantly supporting our basic way of life,  computers and applications that appear to handle much more complex things than sending out millions or even billions (I don&#8217;t know Twitter&#8217;s statistics) of text messages a day.</p>


	<p>Understand that I know I&#8217;m simplifying things, but when it comes down to it &#8230; Twitter is a simple messaging application. So &#8230; let&#8217;s see here. We have:</p>


	<ul>
	<li><span class="caps">MMORPG</span>&#8217;s (Massive Multiplayer Online): Massive Multiplayer games out there that are pushing millions of users playing a single game online. They&#8217;re constantly pushing and pulling massive amounts of data from a server and to your computer, rendering graphics, processing commands, storing items, hit points, kills, and so on and so forth.</li>
		<li>YouTube: We&#8217;ve got sites that that are streaming video to millions of viewers a day.</li>
		<li>Facebook / Myspace: Social Networking applications are handling a <span class="caps">LOT</span> more users, functionality, and traffic than Twitter. Last year Facebook received 26 <strong>million</strong> visitors in August with a little more than 22 <strong>million</strong> end up signing in.</li>
		<li>Flickr: Handling god knows how much data being uploaded, downloaded, commented on, tagged, shared, linked to, viewed &#8230; the list goes on and on.</li>
		<li>Stock Market: Tons and tons of servers and computers out there requesting and sending massive amounts of data through our stock market every hour of every day.</li>
		<li>Online Banking: Millions of people do online banking. Posting checks instantly to their account, transferring money hourly from one part of the world to the other.</li>
		<li>And lets not forget the massive amounts of Porn being served up around the net! I can&#8217;t even imagine how many web sites out there are streaming God knows how much data of Jenna Jameson&#8217;s boobies to God knows how many people!</li>
	</ul>


	<p>Seriously, Twitter. Seriously &#8230;</p>


	<p>The list of incredibly useful and &#8216;scaled&#8217; application is extensive! And you&#8217;re going to tell me that we&#8217;ve now run in to a problem with sending messages from one user to another? Come on now. Put your heads together and come up with a solution before someone else does! I can tell you this &#8230; as soon as another contender supports <span class="caps">SMS</span>. I&#8217;ll be showing Twitter the deuce.</p>


	<p>I&#8217;ve really been trying to give Twitter the benefit of the doubt. I&#8217;m really not a hard customer to satisfy. I know sites have problems from time to time, but Twitter is slowly making it&#8217;s way on to my list of sites that I really just frustrate me. Right up there next to Myspace and eVite (I don&#8217;t even want to link to them I hate them so much).</p>


	<p>Basically all this boils down to is that Twitter is not providing a very good service with either a) a very bad architecture or b) a very bad code base. Period.</p>


	<p>I understand the fact that it&#8217;s a big service and you blew up way it was ready. I understand that it has a <span class="caps">LOT</span> of users and a <span class="caps">LOT</span> of throughput. I understand that the problems multiple exponentially and I really don&#8217;t know anything about the internal architecture or code base &#8230; but let&#8217;s get things together! Twitter isn&#8217;t exactly rocket science here and you&#8217;ve received $15 million in VC funding (probably more) ... and you can&#8217;t solve this scalability problem? What going on?</p>]]></description></item><item><title>Rails Appli-plugins ... the Drag and Drop developer.</title><link>http://bryanray.net/2008/6/25/rails-appli-plugins-the-drag-and-drop-developer</link><pubDate>Wed, 06 Jun 2008 19:45:36 CST</pubDate><author>bryan@bryanray.net (Bryan Ray)</author><guid isPermaLink="false">http://www.bryanray.net/2008/6/25/rails-appli-plugins-the-drag-and-drop-developer</guid><description><![CDATA[<p>Before I start &#8230; I&#8217;d like to state that I&#8217;m not against plugins at all. So please don&#8217;t think that I&#8217;m knocking them in any way. There&#8217;s no doubt about it &#8230; plugins are one of the things that makes Rails great. But as the saying goes, &#8220;With great power &#8230; comes great responsibility.&#8221; So please keep that in mind while reading the article. I&#8217;m not telling you to completely ignore plugins all together or just write your own code all the time, but just understand that plugins don&#8217;t have to be added in to your application on a whim just because the plugin claims it does X functionality.</p>


	<p>It&#8217;s my personal preference to write my own models and controllers for an application before adding a plugin. There are obviously some exceptions to the rule: <a href="http://github.com/technoweenie/restful-authentication/tree">restful-authentication</a>, <a href="http://agilewebdevelopment.com/plugins/acts_as_state_machine">acts_as_state_machine</a>, <a href="http://github.com/mislav/will_paginate/tree">will_paginate</a>, <a href="http://agilewebdevelopment.com/plugins/exception_notifier">exception_notification</a>, <a href="http://rspec.info">rspec</a> (obviously) and a few others are in my list of mandatory plugins for pretty much any application I write. To me, these plugins provide site-wide functionality that allows me to focus on my application rather than the unnecessary bits.</p>


	<p>I&#8217;m sure the question many of you are asking now is, &#8220;Bryan &#8230; why would you write the code yourself if someone else has already done it for you?&#8221; And it&#8217;s a perfectly valid question! I&#8217;m sure there are tons of arguments for and against it. I&#8217;m a firm believer of the <a href="http://37signals.com">37signals</a> book <a href="http://gettingreal.37signals.com/">Getting Real</a>. It&#8217;s an excellent read and it talks a lot about keeping things simple and not just adding in functionality just because. The reason I believe in writing the code myself is that it let&#8217;s me keep things real (to a certain extent). It forces me to look at how simple I can make my models and controllers to start out with and then if I need something more elaborate take that route.</p>


	<p>But a majority of the plugins that I add in provide me a whole bunch of cool functionality and features that I just <strong>don&#8217;t need.</strong> Granted, they add in great features that any customer would love to have, but I find that when I keep things real &#8230; I don&#8217;t need a lot of the stuff that the plugins provide. Remember though, this is not a concrete statement about all plugins. There are plugins out there that are extremely helpful and let you focus more on your application rather than writing code to get you started writing your application.</p>


	<p>Some examples of plugins that I would start coding myself before I dropped in a plugin:</p>


	<ol>
	<li>Social Networking. If I&#8217;m writing an application that requires some social networking capabilities &#8230; why use <a href="http://lovdbyless.com/">lovd-by-less</a>, <a href="http://portal.insoshi.com/">insoshi</a>, or <a href="http://missingmethod.brunobornsztein.com/projects/community_engine">community engine</a>? Talk to your customers, figure out exactly how they want their users to interact with each other and then write the code yourself! Often times, the code is much simpler to write, because the customer does not <strong>really</strong> require a full socially networked site like <a href="http://facebook.com">Facebook</a>. They probably just want their users to be able to send messages to each other or view another users profile. That is if you don&#8217;t tell them you can just &#8216;drop in&#8217; Facebook like functionality &#8230; or at least tell them the repercussions of doing so.</li>
		<li>Tagging. There are a lot of tagging plugins out there that are excellent. They let you generate tag clouds, find different objects tagged with similar content, etc &#8230; but does my application <strong>really</strong> need that stuff right now? Maybe. Maybe not. I typically find that my tagging requirements are always simple at first and adding in a plugin is just not worth it at the time.</li>
		<li>Blogging. Adding my own simple Blog or Post model with simple tests around it should be plenty to get me started. As my application evolves and I realize that I need a more functionality &#8230; then explore other options. Writing more of my own code or looking around at plugins. This allows me to start at square one and &#8220;Get Real&#8221; with the functionality of my application.</li>
	</ol>


	<p>Let me take this one step further &#8230; when thinking about adding some functionality to a Rails application; Typically, the first thing Rails developers do now-a-days is ask Google with the assumption that someone else has already done it. <a href="http://www.google.com/search?q=rails+networking+plugin&#38;sourceid=navclient-ff&#38;ie=UTF-8&#38;rlz=1B3GGGL_enUS264US264&#38;aq=t">rails networking plugin</a> they&#8217;ll enter in and not surprisingly Google responds with a whole slew of social networking plugins. Repeat this process 5 to 10 times and suddenly we&#8217;ve pieced together an application with no effort, no thought, no planning, and probably worst of all &#8230; no specs!</p>


	<p>I also think it gives customers a false sense of how easy it is to develop in Rails. If your customer is constantly asking you to add functionality and your response is, &#8220;Sure, we can do that really quickly&#8221; purely because you can drop in a plugin &#8230; to me, this is bad, because I don&#8217;t think we&#8217;re truly &#8216;developing&#8217; anything as much as we are gluing pieces of different puzzles together.</p>


	<p>In the .NET world I have a word for developers who live inside of Visual Studio; using the <shiver>Designer</shiver> to piece together their applications. I refer to them as &#8220;Drag and Drop Developers.&#8221; These are the developers who think that development is all about dragging objects on to a form, double clicking on them, and hooking up events with some of their own code and some snippets from Google. And things can work out when writing small applications using this approach, but if you&#8217;re writing any sort of production level code then things can (and often do) go horribly wrong. This &#8220;drag and drop&#8221; mentality is the same feeling I get from Rails plugins.</p>


	<p>Sure, things might work pretty well for a while, but the minute I have to start thinking about how to do something to my application that is truly original &#8230; I&#8217;m going to have to jump in to plugins and attempt to couple some new model (or a model in another plugin) to another model; which in turn is going to cause me to add some new relationships in to the models inside the plugins, and before I know it I&#8217;ve got a rubber band ball of code with no specs all. Which is not good. Not good at all.</p>


	<p>Of course, you can develop applications this way. I&#8217;ve done it before and I&#8217;m sure I&#8217;ll do it again, but I think if you&#8217;re serious about developing an application you need to take the time to think about whether or not you just want to drag and drop plugins in to your application or if you should spend some time thinking about your domain model, thinking about what your application needs, determine which models need to interact with other models and write that code yourself!</p>


	<p>I think if you continually drag and drop plugins in to your application without thinking about exactly how things are fitting together then you, your application, and worst of all your customer(s) are going to suffer the consequences. I don&#8217;t think that plugins are a substitute for taking the time to think about the design of your application, about the models you&#8217;ll need, about interactions that will need to occur in those models and while doing that &#8230; writing <strong>specs</strong>!</p>


	<p>An example of plugins that I feel are just a little <strong>too</strong> much are the new &#8216;social networking&#8217; plugins (Insoshi, lovd-by-less, acts_as_community, etc) that have started cropping up around the Rails community. Again, I think these plugins are great. I love the fact that they&#8217;re sharing their code and that they allow developers to quickly get something up and running, but to me this is Rails scaffolding code taken to another level. Scaffolding is great for demonstrations and showing people how quickly you can get things working, but when it comes to actually using scaffolded code &#8230; 98% of the time I end up killing it off, because it is <strong>not</strong> useful in a real situation.</p>


	<p>Now, don&#8217;t get me wrong &#8230; I understand that plugins are open source. If you don&#8217;t like something about it or it doesn&#8217;t fit my applications needs &#8230; than I&#8217;m more than welcome to hop in to the code and tweak it to meet my applications needs and I&#8217;m all for that! But more often than not things don&#8217;t work out for the better when doing this. Developers end up with an untested hack here and an untested hack there to get things pieced together and slowly but surely (&#8220;Don&#8217;t call me shirley&#8221; &#8211; Michael Scott. ha, sorry) your application ends up as a Jenga puzzle. Just waiting for that one piece of the puzzle to knock everything out of place.</p>


	<p>Agree? Disagree? Leave a comment and let me know.</p>]]></description></item><item><title>RailsConf 2008 - Wrapping up</title><link>http://bryanray.net/2008/6/3/railsconf-2008-wrapping-up</link><pubDate>Tue, 06 Jun 2008 18:09:25 CST</pubDate><author>bryan@bryanray.net (Bryan Ray)</author><guid isPermaLink="false">http://www.bryanray.net/2008/6/3/railsconf-2008-wrapping-up</guid><description><![CDATA[<p>{{{
Things are wrapping up here at <a href="http://en.oreilly.com/rails2008/public/content/home">RailsConf 2008</a> and I&#8217;ve only had about 11 hours of sleep over the past 3 days so you&#8217;ll have to forgive any incoherent or fragmented sentences. Thank God for caffeine and advil though.</p>


	<p>Anyways &#8230; I just wanted to put together a quick synopsis of the lessons that I personally attended as well as put a little information about some of the people that I met and experiences I had while hanging out at RailsConf 2008.</p>


	<h2>The Sessions</h2>


	<p>A lot of the talks have been very good. I was a little disappointed on Friday when I was kicked out of a couple sessions due to some crap about a fire safety code? I mean seriously &#8230; who cares about fires, anyways? Yeah &#8230; but they got it sorted out on Saturday and even got some of the speakers to agree to redoing their sessions on Sunday as well. Very nice.</p>


	<h3>Friday</h3>


	<h4>Entrepreneurs on Rails</h4>


	<p>Some very interesting discussion points about getting a company together and moving forward with going out on your own. The most important thing I took out of this was that you really need to have the energy, dedication, and passion to work on whatever it is you&#8217;re doing. This rang true for me, because after a full day of doing &#8216;real&#8217; work during the day I also need to have the drive to spend another hour or two on a project that I&#8217;m interested in.</p>


	<h4>10 Things I Hate about Web Apps</h4>


	<p>I&#8217;ve already <a href="http://bryanray.net/2008/05/30/session-2-10-things-i-hate-about-web-applications">written a bit about this</a> one and really wasn&#8217;t too happy with sitting in on it. I&#8217;m sure there were a lot of helpful things for certain people, but it just wasn&#8217;t doin&#8217; it for me.</p>


	<h4>Lightning Talks</h4>


	<p>After leaving the &#8220;10 Things I Hate about Web Apps&#8221; I walked over to the lightning talks. Unfortunately, I only caught the last 4 or 5, but there were some neat ideas that people were working with and it was a nice change of pace from the typical sessions.</p>


	<h4>Faster, Better, <span class="caps">ORM</span> with DataMapper</h4>


	<p>This was actually one of the more interesting ones for me. I&#8217;m extremely motivated to give DataMapper a try now that I&#8217;ve seen it in action. I&#8217;m not entirely sure I&#8217;m going to go against the grain with using it in a Rails application. So I think I&#8217;m going to do something with Merb using DataMapper as my <span class="caps">ORM</span> of choice. I&#8217;m still trying to think of a decent application to kind of use for testing the <span class="caps">ORM</span> waters though &#8230; feel free to leave a suggestion.</p>


	<h4>The Profitable Programmer: Creating Successful Side Projects</h4>


	<p>I was kind of torn in this session. This talk included Geoffrey Groesenbach interviewing 4 very notable people: The creators/developers of GitHub, FamSpam, Gravatar, and PeepCode. All of which I&#8217;m extremely happy for &#8230; but a piece of me got a little frustrated. I want to be them. I want to build something good. I want to be known in the community, but it&#8217;s not an easy thing. There are hurdles and it&#8217;s hard coming up with those ideas and even harder to act on them. But again &#8230; I&#8217;m truly happy for them and their success &#8230; I just want some of it. Which is actually motivation to do work harder on getting something I believe in put together.</p>


	<h4>Remote Pair Programming</h4>


	<p>I actually ducked out of the Profitable Programmer a little early and caught the tail end of this session. I really didn&#8217;t get a whole lot of information from it, but heard talks about setting up web cams and using some of the more obvious tools: <span class="caps">SSH</span>, Emacs over TextMate, using WebCams, <span class="caps">VNC</span>.</p>


	<p>They admitted that there was no perfect way to go about Remote Pairing, but that technologies were there to make it easier. I tend to agree, but it&#8217;s still very difficult.</p>


	<h4>UI Design on Rails</h4>


	<p>This was geared a lot towards Designers, but it was given by Ryan Singer, of 37 Signals, and it was nice hearing things from a Designer stand point. Ryan gave a very good presentation and it was nice seeing a designer who is really knowledgeable of certain development processes. It&#8217;s nice to see someone going above and beyond their role and step in to the development world just enough to understand how to better work with them. Excellent talk and the questions session was even better.</p>


	<h4>Side Notes on Friday</h4>


	<p>I wasn&#8217;t able to attend the session, but I heard extremely good things about &#8220;MagLev: Ruby That Scales.&#8221; I plan on doing some reading up on it over the next week or two.</p>


	<h3>Saturday</h3>


	<h4>Working the Way You Want To: Mingle 2.0</h4>


	<p>I&#8217;m a huge fan of Mingle and even more so of Mingle 2.0. Their software just seems to fit so well in to the agile development process. I really didn&#8217;t take a lot out of the session as far as technical things go or Agile methodologies, but it was very cool seeing some of the new features.</p>


	<p>I&#8217;m eagerly awaiting their integration with Git <span class="caps">SCM</span> and trying out the concept of creating tasks for stories. A great feature that was not available in 1.x and is extremely welcome in the 2.0 version.</p>


	<h4>Advanced RESTful Rails</h4>


	<p>I think my hangover and lack of sleep were in full effect on this one, because I can&#8217;t say as I remember a whole lot about it other than, &#8220;Use <span class="caps">REST</span>. It&#8217;s good.&#8221;</p>


	<h4>Fast, Sexy, and Svelte: Our Kind of Rails Testing</h4>


	<p>Loved it. I&#8217;m a huge fan of <span class="caps">BDD</span>/TDD and having quick feed back on your tests using mocks/stubs over database interactions. This was a great presentation on how to structure your tests and I&#8217;m glad I got to see it.</p>


	<h4>Integration Testing with RSpec&#8217;s Story Runner</h4>


	<p>I&#8217;m a huge fan of rSpec and Behavior Driven Development so this talk was great to be in. <a href="http://davidchelimsky.net">David Chelimsky</a> started out with a nice quick introduction to what RSpec is, where it started, and about <span class="caps">BDD</span> in general. If you&#8217;re not real familiar with <span class="caps">BDD</span> and/or rSpec &#8230; I highly recommend giving it a shot.</p>


	<p>The story runner demonstration was good &#8230; things kind of hopped around a lot and I think if you weren&#8217;t a little familiar with rSpec and the basics of the story runner already you might have gotten a little overwhelmed with using it, but I was able to come out with a couple new ideas for writing integration level tests and will be giving them a try this week.</p>


	<h4>Metaprogramming and Ruby Internals for Rails Programmers</h4>


	<p>This presentation is incredibly intense. There is a lot of C level code and low level information about Ruby. Patrick does a very good job at keeping the C code interesting and presenting it in a way that is understandable. Unfortunately, Patrick&#8217;s computer gave out about 1/4 of the way through the presentation and it was taking a while to get it up and running again so I moved on to hang out and write some code in the hall with everyone else.</p>


	<h3>Sunday</h3>


	<h4>The Worst Rails Code You&#8217;ve Ever Seen (and How Not to Write It Yourself)</h4>


	<p>Overall I think it was a good presentation. It had a lot of <em>bad</em> code examples; some that were just absolutely hideous pieces of code and then others that just seemed like one of those pieces of code that you get to work and just move on. I think a lot of the time it really just depends on the situation you&#8217;re in when writing the code.</p>


	<p>My personal opinion is that when you&#8217;re writing code for a client who is not very technical and is relying on you, the developer, to make sure the plumbing is done correctly &#8230; there is some of the &#8220;Worst&#8221; code ever &#8230; that, unfortunately, just is the way that it is. Most clients are more worried about progress on the front end. They want to see ajax calls, images, functionality, etc &#8230; but, as a pragmatic or passionate developer I think it&#8217;s our job to make the decision on when and where refactoring needs to occur. And when the refactoring does need to happen I think your battles need to be chosen wisely. Different developers prefer different things and certain refactorings can take a lot of time and money that isn&#8217;t going to provide any visible feedback to the client.</p>


	<h4>De-Railing: Smashing the Rails Stack</h4>


	<p>Personally this presentation didn&#8217;t do it for me. There were a lot of good points about how to make sure that your application is as secure as it can be, but security is just one of those things that has never really piqued my interest. I understand that it is vital to write a secure application and I know enough about security to make sure that my servers and code are secure, but there are <span class="caps">DEEP DEEP</span> levels that can be applied to securing an application. And I admit freely that it&#8217;s just a personal lack of knowledge and interest on my part.</p>


	<h4>Oh, the Fail I&#8217;ve Known</h4>


	<p>To be honest &#8230; I haven&#8217;t really paid a lot of attention. I&#8217;ve been typing up this blog post and I feel bad for doing it, but &#8230; Adam just hasn&#8217;t caught my attention yet. Oops. I&#8217;m going to chalk it up to my lack of sleep though.</p>


	<h3>Meeting People</h3>


	<p>I&#8217;ve been fortunate enough to meet a lot of really good people while I&#8217;ve been here. Also got to catch up with some people that I&#8217;ve met at previous conferences. I have to say that meeting developers at the conference is, personally, the most satisfying thing for me at these conferences. There are so many smart people who are just eager and willing to talk about their development experiences and help you grow as a developer as well.</p>


	<p>I didn&#8217;t get a chance to hang out with <a href="http://sneaq.net">Patrick Reagan</a> &#8211; which is disappointing, because he&#8217;s a good guy and one of the few people I&#8217;ve stayed in touch with from the <a href="http://lonestarrubyconf.com">LoneStar RubyConf</a>. But I at least got in a few words with him and met some of his team over at <a href="http://viget.com">Viget Labs</a>. Good guys.</p>


	<p>I also got to spend some time chatting with <a href="http://blog.davidchelimsky.net">David Chelimsky</a> from the <a href="http://rspec.info">rSpec Project</a>. He&#8217;s an awesome guy to talk to and just has a fountain of useful information.</p>


	<p>I was pretty excited that I got to meet <a href="http://loudthinking.com">David Heinemeier Hansson</a>, <a href="http://obiefernandez.com">Obie Fernandez</a>, <a href="http://blog.jayfields.com">Jay Fields</a>. It was very cool getting a chance to talk and/or hang out with each of them and just realizing that they&#8217;re really down to earth people is a nice thing to.</p>


	<p>I was also able to meet a lot of the <a href="http://hashrocket.com">HashRocket Team</a>. People like: <a href="http://www.mattremsik.com">Veez</a>, Zach Inglis, <a href="http://reinh.com">Rein</a>, <a href="http://workingwithrails.com/person/10428-ben-mcdonald">Ben McDonald</a>, <a href="http://workingwithrails.com/person/9803-jim-remsik">Jim Remsik</a> (Tiger), <a href="http://turriate.com">Sandro Turriate</a> ... all very cool guys. A few of us traveled around downtown Portland and I&#8217;m pretty sure we drank a majority of the beer. Then stumbled back to the hotel for a few good games of Werewolf. Good times.</p>


	<p>All in all, it was an awesome trip. There was tons of good information from the sessions and a lot of good people to meet. Hope to see everyone again at RubyConf and next years RailsConf.
}}}</p>]]></description></item><item><title>Session 2: 10 Things I hate about Web Applications ...</title><link>http://bryanray.net/2008/5/30/session-2-10-things-i-hate-about-web-applications</link><pubDate>Fri, 05 May 2008 19:42:46 CST</pubDate><author>bryan@bryanray.net (Bryan Ray)</author><guid isPermaLink="false">http://www.bryanray.net/2008/5/30/session-2-10-things-i-hate-about-web-applications</guid><description><![CDATA[<p>{{{I sat in on the <em>10 Things I hate about Web applications</em> session and I had to step out in the first 15 minutes. I&#8217;m sure it could have been useful to some people, but it seemed to be one of those obvious things that you&#8217;ve just got to deal with as a developer. A web application developer complaining about all the different technologies, to me, is kind of like an auto mechanic complaining about all the different types of wrenches, screw drivers, ratchets, and the different sizes that are needed to fix a car. Come on.It discussed the standard things that every web developer has problems with when it comes to web development: * <span class="caps">HTML</span>* Browser Compatibility* <span class="caps">CSS</span>* JavascriptThese have been &#8220;problems&#8221; with web development since the dawn of time and a lot of steps have been taken to actually reduce the frustrations: Haml, Javascript Librares, <span class="caps">CSS 3</span> (soon to come), but I just don&#8217;t really see the use in discussing why you hate the tools and languages you have to learn to be a master of your craft.Anyways &#8230; I sat outside with Wynn for a bit and I think he was going to spend some time working on the TickStart application we&#8217;ve started developing internally and I walked over to the lightning talks; which was a little more interesting that then 10 Things I hate about Web Applications session.I&#8217;m also keeping my twitter up to date so if you want more information: http://twitter.com/bryanray&#8212;follow along.ps. I&#8217;m not spell checking or editing these posts, because I don&#8217;t have time &#8230; so please forgive the poor sentence structure, grammar, and spelling.}}}</p>]]></description></item></channel></rss>