28 Sep
2007
Since I’m building a very focused piece of HR software that hiring managers and recruiters can use to manage sourcing of resumes and other recruiting activities, I’ve been watching the various vendors like LongJump and Coghead, who promise a software silver bullet: delivering software without the expense of developing it. I’m not convinced they are going to deliver on that promise.
In some respects, I’m sure the applications they will help their clients build will be fine—they’ll do one thing (perhaps even doing it well), and cost very little to build, and everybody will be happy. In other ways, though, I think those applications will fall short, simply because the thought, the planning, and the refinement that go into a software application built by designers, developers, and domain experts working together with their respective skill sets just won’t be there.
As I’ve been working on Catch the Best, I’ve been reminded how an idea for an application can start out very small, but the deeper you dig into it, the more complicated it gets. Of course, this is one reason why trying to preserve simplicity in software is so hard. But on the flip side, your application can’t be so simple it isn’t useful. This can be a fine line to walk in order to deliver excellent software, and just handing someone some building blocks and saying “go build it yourself” will have mixed results.
In other words, sometimes the just-add-water brownie mix gets the job done. If you want the best brownies, though, it needs a little more effort than that. :)
Comments : 2 Comments »
Categories : Hiring, Recruiting, Ruby on Rails, Web Development
9 Aug
2007
Would you like to know how you can drop the request processing time for an action from 2 seconds to 0.2 seconds? With some excellent tools, some patience, and these tips, you too can speed up critical parts of your web application.
I recently had the opportunity to help a client (and all-around good guy) improve the efficiency of the API portion of his web application. His developer had done a great job with the logic and functionality, but they thought it would be a good idea to have me take a long look at the code to see what improvements I could make. Here are five tips you can use to speed up the slow requests in your Rails app.
Read the rest of this entry »
Comments : 13 Comments »
Categories : Ruby on Rails, Web Development
27 Jun
2007
This morning I decided to add roles to CatchTheBest to start adding a few simple permissions to the application. Sometimes people’s eyes glaze over when they hear role-based access control, but it really doesn’t have to be complicated. There are some plugins out there that are more or less plug and play for implementing RBAC, but here’s a quick and simple example you can use in your project to easily add user roles.
First, the migration:
class CreateRoles < ActiveRecord::Migration
def self.up
create_table :roles do |t|
t.column :name, :string
end
create_table :user_roles do |t|
t.column :user_id, :integer
t.column :role_id, :integer
t.column :created_at, :datetime
end
add_index :roles, :name
Role.create(:name => ‘Admin’)
end
def self.down
drop_table :roles
drop_table :user_roles
end
end
This adds the roles and user_roles tables and creates the first role (Admin). I have added an index to the name field of the roles table because we’ll be querying on that field quite a bit.
Here are the new models:
class Role < ActiveRecord::Base
end
class UserRole < ActiveRecord::Base
belongs_to :user
belongs_to :role
end
There’s nothing terribly exciting there. :) Notice that I don’t have any relationship declarations in Role, as I currently don’t care about finding users by role — I only care about finding roles by user.
Here are the changes to the User model:
class User < ActiveRecord::Base
has_many :user_roles
has_many :roles, :through => :user_roles
def has_role?(role)
self.roles.count(:conditions => [‘name = ?’, role]) > 0
end
def add_role(role)
return if self.has_role?(role)
self.roles < < Role.find_by_name(role)
end
end
And that’s it. Easy, eh?
Comments : 7 Comments »
Categories : Ruby on Rails, Web Development
7 Jun
2007
A while ago I launched Tesly Jr. as a free hosted service for producing HTML reports for your automated Rails tests. A week or so before RailsConf I decided to open up the source to this simple little app, so now you can host your own version of Tesly Jr. Head on over to the Tesly Jr. site and download it from the link on the right-hand side of the page. Enjoy!
Comments : Comments Off
Categories : Ruby on Rails, TDD, Testing, Web Development
24 May
2007
Since I transferred ownership of the conferencemeetup.com domain this morning, it’s now official: I’ve flipped my first business. Confabb is the proud new owner of the domain and the Rails application. Doing this kind of a transaction has actually been something I’ve wanted to do for a while, but without a definite plan or timeline. Having done it, though, I can look back and pull out a few lessons learned for those wanting to do the same.
Read the rest of this entry »
Comments : 5 Comments »
Categories : Business, Ruby on Rails, Web Development, confabb
Recent Comments