RSS

@Inject(Tech) Thoughts on Daily Life.

Written by a professional geek for hire and amateur pundit. Mostly about technology but on occasion, other stuff gets included too.
Aug 24
Permalink

An argument against the "Add-On" lifestyle.

I hear this argument a lot:

  • “Oh no. I don’t want to use this really helpful software utility because I’ll end up depending on it and wouldn’t be able to use somebody else’s computer ever thereafter”.

Isn’t that like saying:

  • “Oh no. I don’t want to use this really helpful hammer thingy because I’d end up depending on it and wouldn’t be able to use somebody else’s rocks ever thereafter”

And my opinion is that this doesn’t make sense to me, so whenever I encounter this argument, I assume it really means ”I don’t want to learn yet another tool even though it promises to make the first tool easier”.

Feb 24
Permalink
Programmers… often take refuge in an understandable, but disastrous, inclination towards complexity and ingenuity in their work. Forbidden to design anything larger than a program, they respond by making that program intricate enough to challenge their professional skill.
— Principles of Program Design (1975), Michael A. Jackson
Jan 30
Permalink

Code Monkey but mostly Architecture.

Been thinking about my way into the art of programming.

Way back when I’d just come of GW-Basic and before that, the Commodore 64 Basic, I was very line number oriented. I used goto’s and knew nothing about Edsger Dijkstra’s influential 1968 paper “Go To Statement Considered Harmful”.

I dabbled in Turbo Pascal and I used QBasic but was too locked into the idea of line numbers. A friend sorta had to push me to start thinking in subroutines. Later, in the interim between high school and further study, I looked at C. C++ opened my eyes to object orientation. VBScript was awful and Javascript highly frustrating because of browser oddities. I could never remember how to do stuff in Perl. Assembly sank my boat and made me cry.

It wasn’t until I started writing Java that I began to think about abstraction and discovering GoF Design Patterns challenged me to go further. Tapestry 3 began my way into component orientation and ASP.NET made me dump the Struts controller completely-never-to-go-back.

ASP.NET made events easy and likeable for me because of their first-class citizenship in C#. Though it took a few false starts before I found out how to use them without excessive FindControl this and thats.

Then it got popular to learn LISP which I sorta kinda did. I looked at the language but I first learned about the “Code as Data” concept from blog posts by Howard (of Tapestry fame).

ESBs introduced me to message based systems. Something that’s probably been popular for ages but which to me, still seems like only being worth it in large systems with tough demands on scalability.

I began using dependency injection with Tapestry 4 and became a fan of the decoupled design and external interface-class configuration though I hated the XML. Guice hit the nail on the head for me while Spring still seems like XML hell.

Dynamic languages are sorta kewl but scary.  I haven’t made the transition. Python doesn’t feel right for me but I haven’t use it much. The new ‘var’ keyword in .NET 3.5 C# seems more conservative and I could get use to that. In spite of all the buzz and excitement, I can’t see a place for this dynamic stuff in real-world projects with budgets and deadlines. I have yet to try one.

All this makes me wonder how the future will change my current favorites of using dependency injection, code-as-data, events and component orientation.

Jan 07
Permalink
You gotta get into subs [subroutines], man!
— Grant Sinclair, Keebra Park co-student, circa 1993 outside math block.
Jan 04
Permalink

A new year.

Quotes and ideas to live by until better ones are found.

“Any fool can write code that a computer can understand. Good programmers write code that humans can understand.”
- Martin Fowler

KISS principle: Keep it Simple, Stupid.

“Good judgement comes from experience, and experience comes from bad judgement.”
- Fred Brooks

“Do not take life too seriously. You will never get out of it alive.”
- Elbert Hubbard

Fail-fast principle

“Learning is not compulsory. Neither is survival.”
- W. Edwards Deming

DRY principle: Don’t repeat yourself.

“The important thing is not to stop questioning.”
- Albert Einstein

The Project Management Triangle: Fast, Good or Cheap. You may only pick two.

Dec 07
Permalink

Sick

I’m ill with the flu. This always messes up my sleep pattern, as well as giving me odd food cravings like what I’m eating now, at 5am, which is .. a can of chopped pineapple that’s been sitting in a kitchen cabinet for the last year. I’m always surprised by the expiration date on those things.

Anyway, on to the point of this text. Audiobooks are great. I usually listen during my 45 minute commute to save the stress on my sleep deprived / overworked eyes.

While I’ve been ill with the killer flu of Satan, I’ve listened to “Douglas Adams at the BBC” and I am absolutely awestruck. I was already a huge fan of the Hitchhikers Guide to the Galaxy and to a lesser degree, Dirk Gently and I thought that was all that he had ever done. But no, he was also a computer and Internet visionary and into protecting endangered species. The book doesn’t read like the usual narrator kind. Rather, the host sets up a series of comedy sketch plays and interviews with the people that worked with Douglas Adams over the years. It’s a definite must-consume for biography fans.

Another book “How to Survive a Robot Uprising” was less good. I’d heard an interview with the author and thought it’d be better but it ended up putting me to sleep earlier. The humour was pushed too hard for some of the advice on how to escape killer robots eg. why would your Roomba vacuum robot and digital home ever need robot arms?! While it is a geek book, I think it’s less of a must-consume. Personally, I have a tendency to weigh the plausibility of things. This has ruined many movies and I’m clearly at fault. Can’t help it though.

Done with the pineapple. Now, what else can I eat?

Sep 26
Permalink

Unleash my iPod

Apple didn’t want to host the Podcaster application in their App Store. Their reason was that it duplicates functionality already present in iTunes.

No, it doesn’t and I’ll tell you why. I’ve had the same old podcasts on my iPod Touch for a week now. This was not the case when my iPod was JailBroken and I used the MobileCast application to wirelessly download podcasts over any open WIFI.

I need my iPod to stand alone because I’m just not plugging it into iTunes everyday. Needing a computer to update an iPod doesn’t make sense to me, so I don’t do it.

Since I upgraded to 2.1, I haven’t been able to JailBreak my iPod due to some 600x error and I really miss that MobileCast application.

Sep 17
Permalink

Too much automation hurts.

I just recieved an automated email answering a question that I had about a failed payment. The answer does not address anything relating to my question at all. Now THAT’s a good way to anger your customers.

I experienced what I consider the most annoying error on the internet: a failed payment transaction. I’ve been waiting for Spore for years and while I’m against all that includes DRM, I had to make an exception in this case.

So I loaded up the EA shop and found that the Mac version is only available for immediate download through some Canadian shop. I proceeded to pay and found that it was handled by WorldPay.com. It was all as I expected until WorldPay decided to send a browser redirect while checking my card details.

Firefox 3 introduced an odd feature that halts a redirect from happening. I’m not sure if it’s part of an effort to thwart phishing sites but in my case, it thwarted my attempt to pay for Spore. It simply broke the WorldPay payment flow.

Having a payment transaction fail is always accompanied by fear. And while I’m feeling the fear of having lost my money into the great void of /dev/null, I fully expect the responsible company to respond to this “lost my monies, yes/no” question. It’s okay if it takes 2-4 days. It is NOT okay to get an automated answer that isn’t even about my question.

Bad bad bad WorldPay.com.

Aug 21
Permalink

Annoyances

An incomplete list of technology “issues” that annoys me.

Microsoft Silverlight == Sun Applets.
Won’t fly. Applets proved this. Sure WPF is pretty but apps still don’t integrate browser functions such as print. Microsoft marketing makes me nauseous.

Synchronization.
I want my mobile devices to pull data directly from online servers. This includes email, calendar etc. It also includes podcast downloads. I do _not_ want to use my computer as a transit device.

Media sharing.
Sharing media is still a pain. Codecs, transport formats and DRM screws everything up. Even the lowest denominator of file formats has internal variances that some devices can’t stomach.

Bad software translations.
I loathe bad software translations. What makes my toes cringe and blood pressure rise is usually word(s) used in the wrong context. Furthermore, having companies assume that I speak swedish, norwegian or german just because of geographical proximity to those countries is offensive. If I can’t have a _good_ danish translation then I’d much rather settle for the english version.

Aug 14
Permalink

Bleeding abstractions in .Net.

Building a software architecture on the idea of dependency injection demands that each distinct feature is defined by an interface. One advantage of this is decoupled code where a part can be swapped out without a major refactor. I’m definitely a huge fan of this idea.

But in order for this code swapping to work, any implementation of an interface must only exhibit behavior defined by that interface. An example of a bleeding abstraction is if an implementation throws an exception that isn’t defined in the interface.

Recently, I found a major difference between .Net and Java that I hadn’t thought about before. It’s all to do with exceptions being unchecked in .Net.

.Net contains only unchecked exceptions which means that there is no way of defining these in an interface. This makes all exceptions specific to a given implementation.

So, if you insist on letting exceptions bubble out of your implementations then your interface abstractions are bleeding. This is bad because you need detailed knowledge of the implementation in order to use the interface. The worst case of ignoring this is 5 unhandled exceptions bubbling to the top within 5 mintutes and thereby shutting down your IIS web application.

But ignoring this detailed knowledge is exactly the point of dependency injection and if you’re going to do it right then you can’t use exceptions for error reporting.

Loosing the exception system when designing features is a big loss. The akwardness can be seen in MembershipProvider.CreateUser which uses an enum to report failures. While this is a tad better than returning raw integer values, it isn’t much better. There’s no stack trace to help debugging unexpected causes either.

Sure, I know exceptions are expensive to create and they should only be used for unexpected errors but using an enum out parameter for error reporting is a step way backwards to early C programming days.

So, my conclusion is that exceptions are out if you’re building dependency injection powered application in .Net. I feel pretty bummed out by this realization.

Jul 29
Permalink

Best hobby, ever.

I like creating my own software. It’s the kind of thing I find myself doing on a sunday morning and during vacations. I get so much pleasure from tinkering that I doubt I could have any other hobby. I play.

The mixture of puzzles, challenges and craftsmanship is what appeals to me.

I read alot of what other people do as well. The ideas of smarter people which I take to integrate into my own world. Sometimes, I discard an idea as being silly or because another idea proves better. This makes for a fun never-ending hunt for interesting ideas.

So, what is an idea? An idea is like a blueprint for building a part in an engine or house. An idea is also a set of blueprints that includes the interaction of the parts that they describe. It’s just a craftsman’s argument for doing something in a way that’s supposedly been well thought out.

If you have enough of these blueprints, you end up building a whole organism ie. software. I like to imagine software as being like a living organism. It has a brain, hormones that transport messages, a skeleton to provide structure and lots and lots of organs. Some organs act when activated while others are involuntarily locked to eg. an interval like the heart pump cycle. Putting this puzzle together makes me feel all God-like.

Sometimes, a thing of beauty is created. All the parts becomes art and I’m filled with joy. It may be the software itself or it may just be a tiny part that’s special. I have even, on occasion, jumped about clapping my tiny hands at something marvelous.

The ever changing world caused by the never-ending hunt for ideas is comforting. There’s always more insight to be gained and because it’s so exciting, it’s fun to keep asking myself why an idea is really the right one.

I have the best hobby. And I get to do this professionally too although in a much more conservative manner. Doing this as a job adds to the number of considerations that must to be observed when putting the puzzle together. Project economy, maintainability, simplicity and manageability all makes it more challenging. I doubt that I could have any other job.

Jul 18
Permalink

Dangrish and the HTC Touch Diamond.

I recently got myself a HTC Touch Diamond. It looked good in the video reviews and the physical size appealed to me.

Once I started using it, I found a few odd usability problems. Like for instance when a call connects, it instantly turns off the screen. This is bad for telephone menus that requires the dial pad. Also, lying the phone face down will mute a call and while initially a cool sounding feature, I found it annoying. The sluggishness of the phone is really bad too.

I solved all these annoyances by hacking the registry to turn up cache sizes and disabling a few bells. The phone is almost as zippy fast as an iPod Touch now with no stability problems.

I’m not sure whether I needed to but I installed .Net 3.5 myself. The specification mentioned that it was pre-installed but I could find no trace of it. The installation was easy though.

The one beef that’s left now is the poor Danish translation of Window Mobile. Deciphering odd translations like “ray approval” can be tricky. I have seen this problem in lots of software and have been confused to the point of vowing to always get the english version whenever I can.
Howerver, the language seems to have been burnt into the ROM of the phone and there’s no way of changing it.

So, apart from the odd Dangrish translation, it turned out to be a usable phone after some tweaking.

Permalink

Apple is not my savior.

I don’t like Apple. I say that even though I own multiple Apple laptops, a mini, an old iPod and a Touch, Airport extreme/express APs, keyboards, mighty mouse and a shuffle but I’ll defend that by saying these were all purchased after careful consideration of the alternatives (ok, the mighty mouse was a mistake).

I do like OS X but that’s mostly because of its unix core, the composite window manager and the way Apple software seems to talk more easily to one another compared to previous Windows and Linux experience. Both have improved a lot since I switched in 2003 and I’m considering switching again.

So why don’t I like Apple when my inventory seems to reek of Apple fanboyism?

Besides the excessive oversimplifying and control, these are my top 5 reasons for not liking Apple.

1.
I don’t like the reality distortion field. Everytime I hear Steve speak, I just don’t believe what he says. He has no credibility. The people that accompany him on stage during keynote presentations are just puppets repeating the same exaggerations. Anyone who steps out of line gets executed by Mad Dog Steve.

2.
What is up with the lame change logs that accompany bug fixes?. Apple seems to think it’s okay to just repeat the same “fixes things and improves stability” mantra for every update. They used to be much better at this. I need to know whether it’s safe to apply an update during work hours or if I should wait until the weekend in case I have to re-install. I don’t want to work during weekends and a changelog would help me decide this.

3.
I was all excited by the iPhone SDK until I downloaded it and learnt about the strict developer control that was enforced. In the end, I went “screw you Apple” and I no longer care about creating applications for the iPhone/Touch. My motivation was to earn a buck or two through the App Store and I’m a Touch owner. The App Store is a really great idea.

4.
Java was to be a real first-class citizen on OSX. Apples inital enthusiasm for Java that promised Cocoa bindings have been dropped in favor of Objective-C, Ruby and Python and this is an issue for me. Sure, Java isn’t an exciting new language but dammit, it’s rock-solid. True, the GUI is ugly as hell but dammit, Cocoa could’ve helped.

5.
The subpar IDE. I’ve tried using XCode and it sucks compared to Visual Studio, Eclipse and NetBeans. When I work, I want to focus on making sound architectural choices, writing intuitive testable code and fulfilling requirements. I need a helpful IDE and XCode is not a helpful IDE. Considering that XCode is a semi-free application redeems it a little. Afterall, Microsoft charge an arm and a leg for their IDE and a comparison might not be fair. However, I wish the developers at Apple would demand a better tool.

Jun 23
Permalink

Javascript is hot

Yes, Javascript is hot. More now than ever. I see all these browser UI frameworks that’s maturing as a sure sign that the chasm between the UI and server side developers just keeps widening. Browser UI work is becoming more specialized and it has already surpassed the point where most server side developers no longer have the required knowledge to really make the code groove to its own coolness.

This is not a bad thing. Server side developers has other responsibilities. Also, to be frank, most server side developers that I’ve known and myself included, has no real interest in creating a progress bar using DHTML and would never really make it … groove to its own coolness.

However, I haven’t dissed Javascript completely. I find that it is emerging as the one truely portable computer language which enjoys support on mobile hardware, browsers and the desktop. The iPhone (e.g.) ships with neither a Java, Silverlight, Air or Python VM. No Flash though I’m seeing rumours that it will soon. But there’s Javascript. The desktop Gadgets/Widgets also relies on Javascript.

So from the perspective of this particular server side developer, the real interesting bits of Javascript these days is the maturing language structure - the ability to create the object models and abstractions that I rely on to tackle the complexity inherent in any difficult task.

May 24
Permalink