"With all the Rights and Responsibilities ..." (a quotation)
April 16, 2009
"I've given you admin privileges ... this way you can see everything. Please do not make any changes to the data."
- Shawn
Refresh a page using Javascript
March 24, 2009
Courtesy of the great Panda, here's how to refresh a page using javascript. It's one of those things that makes sense once you see it, but that I doubt I would have guessed had I needed it.
---js
window.location = window.location
Creating a Shared Context for Monitoring the Health of an Application
March 17, 2009
As part of my vital signs project, I'm building a framework for monitoring the health of an application based on various ways of 'taking its temperature'. Each vital sign will measure something specific (drive space left on the server, database requests per second, etc.).
The point of this project is to quickly give _any_ viewer an idea of...
Ruby Hash constructor -- useful, unintuitive
March 12, 2009
I've been confused in the past about the behavior of "Ruby's Hash constructor":http://ruby-doc.org/core/classes/Hash.html#M002868 . Now that I've looked at the documentation, I have to say I think it violates the principle of least surprise.
A default hash returns nil any time you access a key with no set value. The default value can be...
How does Parsing fit in to the OO landscape?
February 05, 2009
I've been working on a Ruby library for accessing the "NefFlix API":http://developer.netflix.com/docs/REST_API_Reference . It's good fun, but it's brought me to some pain points that don't fit in to my "OO is king" worldview.
My current struggle revolves around parsing.
Should an object know how to parse its data from some external data...
it's Valuable -- like attr_accessor on steriods
January 30, 2009
Take a look at the "ruby gem named valuable":http://valuable.mustmodify.com
I recently worked on a Rails project where most of the domain-related data came from a HyperCube database, rather than a relational one. I have to admint, albeit begrudgingly, that it provided a lot of value. Conversely, the interface was crazily complicated, and...
Rails says, "SQL Server does not exist or access denied."
January 23, 2009
Using SQL Server 2005 with Rails 1.2.6, I got the following (less than helpful) error message.
---
OLE error code:80004005 in Microsoft OLE DB Provider for SQL Server
SQL Server does not exist or access denied.
HRESULT error code:0x80020009
Exception occurred.
---
database.yml:
---yml
development:
adapter:...
Introduction to Unit Testing in .NET using TDD
December 19, 2008
Test Driven Development - noun, also TDD - The step-by-step process of creating an application that is well tested by codifying expectations as tests, then implementing the solution to that test. As implied by the name, the tests drive the implementation, instead of meandering randomly through the code, changing things willy-nilly.
TDD changes...