Archive for the ‘technology’ Category

Using Guice and Mule Together

Friday, August 15th, 2008

I’ve been playing around with Mule lately, mostly just trying to learn and see if it’d be a fit for a little side project I’m working on (it looks like it won’t, but that’s OK). But one thing that was a bit confusing about Mule integration is that the 2.0 version is very heavily dependent on Spring. That would be nice if I used Spring, but this project uses Guice.

First I tried Google, but only came up with this. Then I tried to see how other containers (Pico, Hivemind, etc) integrated in to Mule, but it turns out those integrations were for 1.x and nothing has been built for 2.x. I’m sure there is a better solution that what I came up with, but for a quick and dirty integration this worked really well:

    <spring:bean name="foo" class="com.bar.GuiceUtil" 
                       factory-method="getGuiceInstance">
        <spring:constructor-arg>
            <spring:value>com.bar.Foo</spring:value>
        </spring:constructor-arg>
    </spring:bean>

    <model name="...">
          <service name="...">
               <inbound>
                    <inbound-endpoint address="..." />
               </inbound>
               <component>
                   <spring-object bean="foo"/>
               </component>
          </service>
     </model>

Basically, you just make a simple utility class (GuiceUtil) that holds your Guice Injector and offers a static method named getGuiceInstace:

    public static <T> T getGuiceInstance(Class<T> t) {
        return injector.getInstance(t);
    }

Now Spring is configured to created a Spring bean named “foo” that actually came from Guice. Then you simply tell Mule to use that Spring bean. I’m sure there are a lot better ways to do this (I am a complete Mule newbie and know very little of the configuration options), but this got the job done for me.

Simplify Media launches for the iPhone - get it now!

Thursday, August 14th, 2008

An coworker from my old company, Spoke, just launched an iPhone version of their app and you’d be silly not to get it right now.

I predict this will become one of the killer apps for the iPhone. The app is really quite simple: it lets you play your home iTunes library (all of it) and your friends libraries on your phone. It works by utilizing a desktop app that integrates with iTunes. It’s simple, effective, and super cool.

And why should you get it right now? Because it’s free for the first 100K downloads, after which it’ll cost $3.99. Get on it!

13949712720901ForOSX

Sunday, November 4th, 2007

Sure, count me in for voting for Java 6 on OSX. Not sure what 13949712720901ForOSX is? I’m not quite sure either. Google it.

Leopard Spaces + IntelliJ IDEA = Sadness

Saturday, November 3rd, 2007

Looks like the new Spaces feature in Leopard doesn’t work with some Java apps, including IntelliJ. Specifically, you can drag the window to various spaces, but when you click on the icon in the dock, the screen doesn’t automatically navigate to the correct space.

My guess is that this has to do with the way IntelliJ creates the Swing-based windows it displays. Spaces probably is keying in on some hidden window and so it doesn’t know where it should take you.

On the other hand, most apps properly support spaces just fine, even when multiple windows are open in different spaces. For example, Safari windows in two different spaces will simply cause spaces to alternate between the two windows every time you click on the Safari icon in the doc.

Here’s to hoping Jetbrains fixes this soon…

Java Blog Posting Library

Saturday, November 3rd, 2007

Does anyone know of any Java-based (or any other language, for all I care) utility or library that makes it easy to post blog entries to various blog systems (Blogger, MovableType, WordPress, LiveJournal, etc)?

Embarassing

Saturday, November 3rd, 2007

Wow - this is embarrassing. Another one of those “I can’t believe I haven’t posted in so long” posts. But really, it’s been 5 months since my last post, and 7 months since my second to last one. Ouch!

That is going to change, especially because I little side project I have going on involves a lot of blogging…

As for what I’ve been up to…

  • Got married a few weeks ago
  • Sold my company earlier this year (I don’t think I ever actually blogged that - whoops!)
  • Been traveling a lot to Boston (50% of the time)
  • Speaking at various conferences (The Ajax Experience, STPCon, StarWest, etc) - mostly QA-related stuff
  • Not too involved in Struts and OpenSymphony, but I hope to be again soon
  • Still fairly involved in OpenQA

I think that’s it. More posts soon…

Most Exciting Leopard Feature…

Saturday, November 3rd, 2007

Forget all the whizbang stuff… Stacks, Dock, Time Machine, etc. And look past the fact that stupid Apple has decided to abort Java on OS X. As someone who travels a lot and loves his basic Dell keybaord, this is what I’ve been waiting for:

Leapard_keyboard.png

Yup - that’s right. OS X will finally automatically change the keymapping for me between my laptop keyboard and my desk keyboard. Considering all the travel (and lounging on the couch) I do right now, I have probably gone in to this preferences panel over a thousand times just this year. Never again!

Fred Thompson, MerchantCircle, and small businesses

Monday, June 4th, 2007

One of my very good friends, Kevin, as well as my old CEO back from my Spoke days, work at a company called MerchantCircle. Kevin recently opined about how the focus of MerchantCircle relates to the upcoming presidential election.

First, a quick note about what MerchantCircle does: think “social networks for businesses” and you kind of have the idea. Instead of focussing on the consumer, like review sites like Yelp and CitySearch do, they focus on the business. Businesses can “partner” with other businesses for coupon deals (think “friends”), create their own home page, (think “profile page”), and provide an official response for praise or criticism of their business.

I find his points interesting specifically because of the waves Fred Thompson is now making as he begins his candidacy. Fred Thompson is claiming that he, like Howard Dean, will use the power of the internet and social networks, to run a more effective campaign for less.

So far we’ve heard about Barrack’s MySpace page, but I don’t really think things like that are a good demonstration of how Web 2.0 can be utilized to improve our democracy. MySpace is, afterall, mostly about kids who can’t even vote, or stoners who likely won’t.

However, more focussed communities like MerchantCirlce (small businesses), Digg (high tech workers, perhaps?), or online schools (ie: University of Phoenix, etc) might provide an excellent conduit for engaging in deep, thought-provoking exchanges about specific issues.

Forget town halls, virtual town halls, or even debates - they are too general and end up suffering from the “law of diminishing returns” because their audiences cover such a broad base. I think engaging with a specific community about needs specific to them, on a mass scale, would really open our eyes up about the candidates. I would love to see an online chat with Digg users, or a forum for MerchantCircle users to ask tough questions.

Update: MerchantCircle just recently celebrated it’s one-year birthday. Congrats to them. I love the idea of bridging local small businesses and the vastness of the internet.

My only complaint would be that they focus on the business owner and not the consumer, but that’s not really a valid complaint because they readily point out to and integrate consumer-focussing sites, ending up being a companion to them more than a competitor.

Jive Forums 5.5: A quick review

Tuesday, April 10th, 2007

I recently upgraded the OpenQA forums over to Jive Forums 5.5 (beta) and I am very impressed. We were using a pretty old version (4.2.1) and the difference was like night and day.

The upgrade

The upgrade was as simple as it can get

  1. Copy the new war file over the old one.
  2. Open the forums in the browser.
  3. Enter the administrators password to initiate the upgrade process.
  4. See a nice little list of steps that need to be completed, along with estimated times for each task.
  5. Done.

It really was that easy. Everyone should build software this good. The only other company I know that has a nice upgrade framework is Atlassian, and theirs is nowhere as elegant, nor does it provide the visual feedback that inspires confidence in a process that inherently introduces risk.

Reply by watches

By far my favorite new feature. Previously, the OpenQA forums have been using Jive’s unique “email gateway” feature that allowed a mailing list and a forum to stay in sync. This let users choose the style of message delivery (web, RSS, forum watch email, mailing list membership, etc).

I chose RSS+web because I get enough email as is and hate being subscribed to random lists that I can’t remember how to jump off of. Plus, I like knowing that my membership is part of the forums, which gets you little things like “reward points” for answering questions (something which obviously email doesn’t have).

But whenever I traveled, I missed email. I wanted to be able to reply to the threads I saw in my RSS reader while offline in an airplane, but I couldn’t. In the latest version of forums, Jive introduced a killer new feature: reply to watches by email.

Now I can watch my feeds in RSS, but when I know I’ll be on the road coming up, I can turn on my email watches to the forum. Then, as each message comes in, I can reply to the watch notification itself and my response will automatically show up in the forums (and get sent out to the mailing lists, thanks to the gateway we’re using). To me, this is the best of both worlds, and Jive did an excellent job with it.

My only complaint is that the subject the watches come in with is unique every time. This is due to how they sync up replies with threads. The downside of this is that my watch notifications won’t get grouped together as a thread in my mail client, so it’s a bit harder to follow conversations. I also had to modify the watch templates to include the entire thread instead of just the new message. This gives the required context that one would expect if they wanted to reply by email.

Wiki formatting

The new forums also allow for common formatting, often found in wikis, to be used in forum posts. This is nice because now I can format new replies by email and I know it’ll look good for both audiences: text (email) and HTML (web and RSS).

But what I was really impressed with was the customizations. Jive supports a link syntax similar to Confluence (Atlassian’s wiki) that uses square brackets. Unfortunately, the OpenQA forums use square brackets a lot due to the fact that people post xpath expressions all the time, such as

//div[contains(@id, 'border-box')]

This, of course, produced some bogus links. What impressed me is that I could drill in to the wiki formatting settings and individually turn off link support. Even more: when I turned it off, it no longer appeared in the help guide! That’s the way software should work all the time.

Other stuff

THe OpenSymphony Forums have had integrated web chat support for a while, written by yours truly. However, the OpenQA ones never did because I didn’t want to maintain the code going forward. While it isn’t quite as nice as the OpenSymphony forums, Jive Forums now comes with an integrated web-based group chat. This is a great way to host meetings and to help people out in real time.

The features I’m missing from the OpenSymphony forums are:

  • Ability for chat transcripts to be easily searchable and accessible. I did this by posting the chat log to the forums every 24 hours, but other solutions are possible too
  • When in the forums, being notified that activity is happening in the forums (new message posted). I did this with a “chatbot” in the OS forums, but again, this could be done other ways, such as XMPP watches, etc.
  • Tying chat rooms and forums together such that the people in the associated chat room are listed along side the forum as “now chatting”. Even better, their expertise level (reward points) are shown, so people can immediately tell if experts are ready to help them in real time.

The good news is that a lot of this stuff will likely end up in some sort of integration between Openfire and Clearspace (think of it as Forums + blogs + wiki + content management + etc).

Overall, Forums 5.5 was a great improvement. I’m looking forward to Clearspace, when hopefully my little nit-picks will be addressed :)

Atlassian outlines how to build great software

Monday, April 9th, 2007

All software development organizations, take notice: Atlassian builds software right and the result is continually great software. I can’t speak for Crowd (haven’t used it), but I certainly know that the process defined in this article certainly will put your project on the path for success (in terms of technology… of course if the idea sucks, a nice dev process won’t save you!):

Basically we have taken the following steps:

  1. Move from CVS to SVN
  2. Move from Ant to Maven 2
  3. Add some level of test coverage, and build this into our development process
  4. Add integration tests for the Crowd Console
  5. Hook all this up with Cargo and Maven 2
  6. Drop it into a continuous integration server

(Via Atlassian Developer Blog.)

The only thing I think they could improve on is the use of JWebUnit/HtmlUnit. They should really step up to Selenium, especially considering how often bugs crop up due to inconsistencies across web browsers. But still, that is merely an incremental improvement to their very solid foundationl. On top of that, JWebUnit has an abstraction layer on top of Selenium, so it should be an easy switch.