I’ve been following the discussions between Joel Spolsky and Jeff Atwood about a new Q&A site they’re putting together, Stack Overflow. I signed up for the beta and poked around.
I posted my first question yesterday, a real question that I didn’t know the answer to, that was relevant to my work. I’m trying to shoehorn Java into a new shoe, for a project where dynamic languages would be a more natural fit.
http://stackoverflow.com/questions/86607/how-do-i-correctly-access-static-member-classes
Grails has shown Java could be competitive though, at least as an easy to use “convention-over-configuration” web framework. In fact, I first wanted to use Groovy, but team resistance made me abandon that track.
Anyway, I thought I’d give it a try. I started with a big properties file, moved into a hashmap (a friendly co-worker who didn’t know what I was doing suggested hashmaps were almost never the answer) and then though about static fields. And then static inner classes. This would give the huge benefit of IDE discoverable configuration, but it would be a maintenance nightmare. A hierarchy of potentially hundreds of properties over dozens of classes, all in one file — being edited by 20 people.
I found a way to do it, but the compiler was throwing up warnings left and right.
“The static field Foo.bar shoudl be accessed in a static way”
But it compiled and it worked. I knew my team mates would never stand for it. And half of them wouldn’t even understand why it was being done that way. The other half would say that it was the wrong way to do it, but not know a right way that I could be happy with. So that wasn’t maintainable either.
I knew it was possible, but I knew the compiler didn’t like it. I thought it was a limitation of Java (probably deliberate–in the same way every bug ends up being ‘the way I meant to code it’), but I was determined to beat the system. I wanted to know what the rationale for the error was, though I didn’t hope to get a decent answer. But I did.
Thanks to stack overflow and jon.
StackOverflow does indeed rock. For one thing, it’s totally spam-free. It’s also been around long enough by now that many of the esoteric questions I would have asked have already been asked and answered–and the search function is quite good, so those answers are easy to find.
Mark-
Thanks for the comment. Stack Overflow has exceeded all expectations. I think it being community driven is a large part of that. Not it’s social networking aspect, but the buy in it has received from developers thanks to Jeff and Joel. Even then, if it hadn’t been so well executed, it wouldn’t work.
I like your site CriticalResults.com too. I’m just starting out consulting, mainly QA, but also some business solutions. Of course, I want to get rid of terms like ‘consulting’ and ‘business solutions’ and your site is a good example of a well written, informal approach.
Thanks, Aaron! I got a lot of my marketing ideas from Robt. Middleton at http://actionplan.com and Mark Silver at http://www.heartofbusiness.com.
I don’t think of Stack Overflow as much of a social networking site, but I do enjoy the “badges” and appreciate those reputation scores. On the downside, the site is SOOOO full of experts that I don’t often get a chance to answer a question. You have to be fast!