Archive for December, 2005

Free Icons

Tuesday, December 20th, 2005

famfamfam has kindly provided a set of Free Icons of all different shapes and sizes. They look great.

> Need icons for your new website or web application, at the best price there is (free!)?

CSS-Only, Table-less Forms

Monday, December 19th, 2005

Jeff Howden has created a CSS-Only, Table-less Forms CSS solution.

> Most of the CSS-only, table-less forms available suck. So, not wanting to stoop to mediocrity, I decided to take on the task of coming up with something better. This is the result of my efforts. It works in Win/IE6, Firefox v1.0 , Win/Opera v8.0, has minor layout differences in Mac/Safari v1.0.3 and Mac/Safari v1.2, and is usable but fairly buggered in Mac/IE5.2.

File Uploads with Rails

Monday, December 19th, 2005

Sebastian Kanthak has created a very handy file upload utility for Rails called FileColumn.

> This library makes handling of uploaded files in Ruby on Rails as easy as it should be. It helps you to not repeat yourself and write the same file handling code all over the place while providing you with nice features like keeping uploads during form redisplays, nice looking URLs for your uploaded files and easy integration with RMagick to resize uploaded images and create thumb-nails. Files are stored in the filesystem and the filename in the database.

Rails Petstore

Monday, December 19th, 2005

The Rails Petstore is

> an implementation of Clinton Begin’s JPetstore that has been developed with the Rails web framework. The aim of this project is to develop a reference application that demonstrates the capabilities of the framework and the best practices that should be followed when developing an application.

This is for all you Java people out there who have seen the Petstore application in one form or another over the years. The Petstore is a common Java application implementation used to show how a framework is used “in the real world”. It’s been implemented many times, and comparing a Java Petstore to a Rails Petstore is very useful.

Ruby off the Rails

Sunday, December 18th, 2005

Ruby off the Rails is a look at Ruby from a Java developer’s point of view.

> Ruby on Rails is just one facet of what makes Ruby great, just like EJB is only part of the Java™ enterprise platform. Andrew Glover digs beneath the hype for a look at what Java developers can do with Ruby, all by itself.

Steal These Buttons

Saturday, December 17th, 2005

Steal These Buttons is a collection of those little button images you find on the sidebars of blogs, such as Valid XHTML 1.0. There are over 3000 buttons available. Of course, if you can’t find what you need, you can always make your own or use the handy web version.

All these links stolen from MeFi.

SwitchTower: Automating Application Deployment

Saturday, December 17th, 2005

SwitchTower is a set of scripts to automate application deployments for Ruby on Rails applications. For anyone who knows the pain of deploying and upgrading many applications, this is heaven sent. At a previous job we spent close to 25% of our time deploying and redeploying applications.

> SwitchTower is a standalone utility that can also integrate nicely with Rails. You simply provide SwitchTower with a deployment “recipe” that describes your various servers and their roles, and voila! You magically have single-command deployment. It even allows you to roll a bad version out of production and revert back to the previous release.

Question now is, can this even be done in the Java world? Even if it could, would it ever take hold? I almost think that a common deploy script and procedure would not be widely accepted in the Java world, because of the mentality of the common Java developer. A Java developer wants to built it himself (see the insane number of web frameworks out there for evidence of that). Of course, one size doesn’t fit all, but in the limited scope of web applications, one size fits most.

IM, meet AJAX

Friday, December 16th, 2005

AJAX, meet Instant Messaging. IM, meet meebo.com

Call me when I’m running an AJAX browser inside my browser.

On the Rails Again

Friday, December 16th, 2005

Danny’s Blog has some good perspectives from a Java guy who just went to JavaPolis, but who is also On the Rails Again. He did pick up on a general meme of EoD:

> A lot of presentations I saw, about Java EE 5 (GlassFish) but also for instance about Spring, stressed that everyone now focusses on EoD(Ease of Development) and ‘code by exception’, meaning: only having to code the exceptions to the default behaviour.

Having just come back from The Spring Experience myself, and having written Ruby on Rails applications for the two weeks prior, I can attest to what Danny experienced. Programming in Rails certainly opens up your eyes to what else is possible in the web programming world. Not all of it is good, mind you. You immediately miss the power of your Java IDE, for one thing.

I recommend that every Java web developer go code a quick application in Rails, even if they will never use Rails again. It’s so easy to get caught up in a language’s constraints, both physical and mental. By programming an application in something not Rails, you take a breath of fresh air. Rails is cutting edge because of what it doesn’t try to do. I’m certain that a Java developer can learn a thing or two from what Rails attempts.

Writing Mixins using AspectJ

Friday, December 16th, 2005

java.net has a nice long article on Writing Mixins using AspectJ. They use the example of JavaBean property change event listeners, which up to this point has been a total pain to write. Using AspectJ, you can whisk that code away into its own aspect. Your tradition bean looks clean and beautiful again, while retaining the nice functionality of event listener notification.

>Aspect-oriented programming complements object-oriented programming in many ways. One interesting complementary feature is behavior composability. This means that it should be possible to compose a class by adding behavior from different classes. OO uses inheritance and many patterns to add behavior to existing classes. AOP allows us to use mixins without changing the class inheritance hierarchy or otherwise changing the code.

>Mixins enable us to uniformly extend a set of classes with a set of fields and methods. Java does not support mixin-based programming. This article shows what mixins are and explains how AOP constructs in AspectJ allow us to use this technique to isolate crosscutting concerns, with an example. It starts with a plain Java implementation and ends with an AspectJ 5 implementation.