11/15/2006

Upgrade Blogger Version

Hope this upgrade doesn't cause anyone any problems :) They have a nicer templating editing feature and some better default templates than I can create.

4/04/2006

The Emotional Side of Design

Design sessions can often become emotional but this is not what I am talking about. People have strong feelings about the right and wrong way to do things but this is not what I want to address.

I want to try to describe the emotional feelings that one gets when a design idea is proposed. These aren't the strong passions of right or wrong but more of a gentle tickle deep inside that something is wrong.

We have all read articles on the "art" of programming and design. We have seen and experienced the best designers become the worst teachers. There is much written on the levels of knowledge from:


  1. I don't know how much I don't know.
  2. I have studied the process and am comfortable with it.
  3. This process is crap and these are the improvements we need to make.
  4. I understand thing well enough that I can explain it in simple terms.


we all exist at all levels. On many computing subjects I have no clue how ignorant I am and on others I teach.

I experienced a level 3 yesterday that went something like this:


Ed: Yes, you should replace VSS with CVS.

Customer: But CVS can't do file linking across branches. We only want to have to make a change once for all the product branches.

Ed: While that sounds like an advantage, it is actually the most horrific situation you could possible create for yourself.


I don't think I conveyed this statement quite as strongly as I might have but I couldn't articulate why file level release versioning was such a bad idea. I explained how I would manage it with branch and merge techniques in CVS and I think they saw this as a possible alternative but I didn't have the knowledge necessary to explain that the process they were using was exactly the thing that was killing their development throughput.

They gave me some hints to their atrocities, "We make developers send emails to the configuration team to check in and out files" and "The last release is managed on the O: drive because it was too difficult to manage in VSS".

Perhaps I could have got into the mathematics of why X files with Y differences takes Z brain hours to manage and the slope of the graph looks more like Everest than a manageable process.

So what is this emotional link we get with a set of ideas. Perhaps emotional is the wrong word, is it a 6th sense, intuition or perhaps just random gas.

Anyway, I have no answers, just experiences.

3/22/2006

Site Integration - Maps, Music, Chat and Sound

Site Integration - Maps, Music, Chat and Sound

I have been playing with techniques for site integration for a little while and have some interesting samples that are worth cataloging.

We all know that Web Services and B2B are the primary architectural vehicles for integrating computer systems but its not what is visible in the real world. Certainly we are building web services and certainly they serve to integrate systems but to the internet culture as a whole they are an irrelevance.

Let me say it this way. Corporations use B2B techniques to seamlessly integrate symbiotic features. Web Site builders use other techniques to integrate user experiences.

Perhaps we could look at the two as layers of the same cake. An internet user experiences features presented to them. Some of those features might require Web Services to achieve their goal but the user integration of experiences is a "higher" level integration.

Ok, so I can't explain it. Lets go with some examples. These are all on my home page.

Frapper



Frappr allows us to share graphical locations and present them as a map. A piece of this map can be integrated onto your web site. The XP Cincinnati site integrated this information into a blog entry.

They use simple javascript to link the two sites together.

Odeo Blogging



Odeo has developed a technology that allows us to record sound and publish that sound. Most use it for blogging but I have heard that some are using it to record and publish their music as well.

I have an Odeo blog and this allows me to record snippets of sound and then integrate that sound into my web site.

In this case the integration is achieved with an object tag that runs a some flash. The parameters point to the recorded mp3 that is stored on the Odeo site.

last.fm Music Listening



last.fm is a music tracking site. It supplies you with plugins for winamp, Media Player and others that will send the name of the music you are playing to their site. This can then be retrieved in a variety of formats to your website so that your customers can see what music you are playing at that moment.

This uses a little pseudo javascript insert that retrieves the HTML necessary to list your music.

Instant Messaging or Instant Talk



There are lots of features that allow you to publish your Instant Message online status to your web site but I was focusing on Skype since it includes the voice and video features that will ultimately become part of the communication applications of the future.

This site uses a little javascript with a new embedded protocol "skype:" so if you have an anchor with "skype:Edward Sumerfield?call" in it and you have the skype client installed then clicking on it will call me.

Conclusion


I think this point has been made in other blogs already but it doesn't hurt repeating. The primary site integration tool is javascript since it is the glue code that allows countless disparate technologies to interact.

If you are developing any kind of user interface tool today. Make very sure that you are including your javscript hooks. It will allow your tool to become integrated in ways that you can not imagine.

3/02/2006

Agile Set Me Free

My current client is thinking about adopting a more Agile approach to software development. We have had initial discussions and passed out books to read. We have been running an XP project for them for 6 months so they have all witnessed its success.

Someone found an article written in July 2002 that goes to town discrediting XP. So, I need to spend time trying to understand this 4 your old paper and trying to explain where it is misunderstanding the Agile proposals.

This is when it hit me. All the comments the author makes fall into one category. Fear. Fear of change. Fear that iterations make projects unmanageable. Fear that less documentation will cripple the maintenance effort. Fear that Test Driven Development will not produce a perfect object model. All of the answers stem from the base feelings that we have developed over years of working with requirements that changed and software that we kept on finding bugs in. We have beaten ourselves up so much about how little discipline we have and how bad we are at talking to the customer that we can't imagine that the opposite approach might be better. We are just not good enough to execute the perfect process we have been working at all these years.

All the complaints I read about Agile take everything it says at face value and fail to see the depth that it is suggesting. Release early is miss-read as ignore requirements. Allow the customer to change requirements is miss-read as never knowing what you are about to release. Don't write irrelevant documentation is immediately the terrifying idea that there will be no documentation.

So much confusion from simple, practical improvements in a process.

Agile is a liberation of our freedom to produce great software. Agile is a reconnecting with the essence that is writing software to solve business problems. Agile gives us the excuse to succeed when all we had before was more disappointed customers and another bug to fix.

Dam this job could be depressing. I have always loved programming but hated the job. It never made any sense until Agile opened my eyes. Actually, to be more specific, Mark Windholts opened my eyes when he pitched the test first practice to CinJug. Dude, you rock.

2/26/2006

Another Hour Another Rails Release

While I am a complete novice at this and my controller tests still don't work I have been able to add basic delete and create functionality to "WebZone On Rails" in about 5 hours.

The reason I couldn't do this in Java is because of ActiveRecord and the tight integration between the controller and the page.

With ActiveRecord I have been able to create and delete from an existing MySQL schema with just a couple of lines of code. With the integrated mock data infrastructure that comes with Rails I have full unit tests for all these steps.

With the tight integration of controller and page I am able to create controller instance variables and directly reference them from the rhtml pages. This makes it mind blowingly easy to load data and reference that data directly on the page while maintaining the MVC isolation. This is similar in concept to the .Net idea of the page and code behind being the same instance.

I still can't run my controller tests. Ran the gem update rails with no improvement.

Blog Entry From Camera Phone

Trying the mobile blogging feature at blogger.com. Just have to send an email to go@blogger.com and 'they do the rest'. Sound too easy.

Publishing Rails with SwitchTower

I need a simpler way to get my changes out to the web site. currently I am just copying file by file to FTP but this is tedious and error prone. I have heard that Switch Tower is the tool of choice for deploying Rails apps so here goes:


gem install switchtower


The install seemed to go well with the following dependencies also being installed.


Attempting local installation of 'switchtower'
Local gem file not found: switchtower*.gem
Attempting remote installation of 'switchtower'
Updating Gem source index for: http://gems.rubyforge.org
Install required dependency net-ssh? [Yn] y
Install required dependency needle? [Yn] y
Install required dependency net-sftp? [Yn] y
Successfully installed switchtower, version 1.0.1


Switch Tower needs to make some changes to the current rails app so that it can deploy it.


switchtower --apply-to [full path to rails app]


This seems easy enough but the first run gives me this. After a hour of google searching and drilling down into the gem install I find that the error, is infact, correct, the rails_generator/sripts/generate code does not exist as part if the switchtower install but I don't know where to get it so I am stuck.


d:/products/ruby-1.8.2-14/lib/ruby/site_ruby/1.8/rubygems/loadpath_manager.rb:5:
in `require__': No such file to load -- rails_generator/scripts/generate (Missin
gSourceFile)
from d:/products/ruby-1.8.2-14/lib/ruby/site_ruby/1.8/rubygems/loadpath_
manager.rb:5:in `require'
from d:/products/ruby-1.8.2-14/lib/ruby/gems/1.8/gems/activesupport-1.2.
5/lib/active_support/dependencies.rb:214:in `require'
from d:/products/ruby-1.8.2-14/lib/ruby/gems/1.8/gems/switchtower-1.0.1/
lib/switchtower/generators/rails/loader.rb:7:in `load!'
from d:/products/ruby-1.8.2-14/lib/ruby/gems/1.8/gems/switchtower-1.0.1/
lib/switchtower/cli.rb:248:in `execute_apply_to!'
from d:/products/ruby-1.8.2-14/lib/ruby/gems/1.8/gems/switchtower-1.0.1/
lib/switchtower/cli.rb:219:in `execute!'
from d:/products/ruby-1.8.2-14/lib/ruby/gems/1.8/gems/switchtower-1.0.1/
lib/switchtower/cli.rb:12:in `execute!'
from d:/products/ruby-1.8.2-14/lib/ruby/gems/1.8/gems/switchtower-1.0.1/
bin/switchtower:11
from d:/products/ruby-1.8.2-14/bin/switchtower:19:in `load'
from d:/products/ruby-1.8.2-14/bin/switchtower:19

WebZone port to Rails

I have been using a product called WebZone since 2001. I built it to do what I want and have extended for me. It supports other users and sharing data with them but primarily it has always been for me.

Its primary goal is to allow me to collect information in one place and organize it. It does this with good support for drag and drop into the browser, JavaScript scriptlets that can add the current page to your WebZone account and the ability drag your information around your WebZone to relate it in anyway that you want.

WebZone on Java



At 5 years old it needs some serious re-writing. When I started it I was just getting into test first so it doesn't have many tests. It has no mock data so continuous testing is out.

Since Rails is getting so much press I have decided to try it our there.

Phase One. Allow a rails app to read and navigate a WebZone database.

Phase Two. Add edit feature.

Phase Three. Add delete feature.

Phase Four. Add create feature.

We are in Phase three and it is now deployed to

WebZone on Rails



So far so good.

The basic app was easy to create but I needed some ActiveRecord help from the XP Cincinnati team to get the database interface working nicely. Thanks to Jim Weirich.

With that part working, putting the rhtml files together to display the data was a snap.

A continuing problem is getting the controller tests working. So I am doing as much unit testing as possible but not being able to test the controller level is a serious problem. I am getting the error:


Exception: No url can be generated for the hash
{:targetId=>"1", :controller=>"read", :action=>"item", :targetType=>"TableText"}
generated_code/routing/generation.rb:5:in `generate_default_path'
.../action_controller/routing.rb:419:in `send'
.../action_controller/routing.rb:419:in `generate_path'
.../action_controller/routing.rb:415:in `generate'
.../action_controller/routing.rb:602:in `extra_keys'
.../action_controller/test_process.rb:86:in `assign_parameters'
.../action_controller/test_process.rb:295:in `process'
.../action_controller/test_process.rb:307:in `get'
webzone3/test/functional/read_controller_test.rb:20:in `test_item'