In concert with my NFJS Tour talks on MuleSoft iBeans, I’ve just released a corresponding 15 minute video on writing an iBean with a quick explanation of the motivations and syntax contributing to this unique lighter-than-ESB platform.
Posts Tagged ‘Programming’
iBeans Screencast Launched
Friday, May 14th, 2010iPad, iPhone Certified Developer Program – A Wild Idea
Friday, May 14th, 2010As much as we (the Software Engineering industry) detest testing and certification, Ben Ellingson and I were wondering if it would be useful to have an Apple iPhone skills-certified developer program. The idea would be that a developer would pass a certain skills test and then be permitted to directly publish bug-fix updates to the store without the usual review waiting period. I realize this is controversial and further cements Apple’s importance in a software release process where many think they should not be involved.
Updated Apache Tomcat Web Application Maven Archetypes via MuleSoft
Thursday, April 29th, 2010MuleSoft Tomcat Web App Maven Archetypes
I’m pleased to announce that MuleSoft and I have collaborated to freshen the world’s two most commonly used Maven Web Application Archetypes, the maven-archetype-webapp and the wicket-archetype-quickstart.
The Motivations
These two archetypes had fallen out of date, both in terms of using the new Archetype 2.0 style metadata, as well as in the dependencies on the third-party libraries such as JUnit. Due to limited volunteer developer time, when the Maven Archetype developers moved from the 1.0 to the 2.0 branch many of the existing archetypes did not successfully make the transition. Thus, the public was having to make do by using old versions of these archetypes.
The Update
Given MuleSoft’s and my keen interest in the Apache Tomcat ecosystem, including the enterprise-strength Tcat product, we set out to bring these two aging archetypes up to date. We found that easiest to do under the very open MuleForge repository & GitHub source code hosting for the near term, but we will be submitting a patch to get these improvements back into the core archetypes at Apache too.
Contributing back to community
A week into the effort, the “update” turned into a complete “rewrite” of the archetypes to reap all the benefits of the Maven Archetype Plugin’s version 2.0 features.
The metadata has dramatically changed between the Maven Archetype 1.0 and 2.0 versions of the plugin. Previously, the file named archetype.xml lived in the src/main/resources/META-INF/ directory, then it was relocated to src/main/resources/META-INF/maven, and finally, in full modern 2.0 form, has been additionally renamed to src/main/resources/META-INF/maven/archetype-metadata.xml.
Similarly, variables inside source files were updated to use the ${} notation, with legacy elements like $package updated to ${package}.
The poms for the archetypes were updated from the old archetype plugin type to use the new 2.0 lifecycle extensions
The resultant archetype code is hosted at GitHub for easy viewing, consumption, technical review and forking. We’d love to get your input and improvements!
These two archetypes now represent the most pristine use of the Maven Archetype Plugin v2.0 format.
Integration Tests
We didn’t want to stop at just updating the archetypes though. We wanted to make them better. So one of the most obvious ways to do that was through adding integration tests. I can’t tell you how often I get asked for a good example of leveraging the Maven pre-integration-test and post-integration-test lifecycle events. Up until now, I’ve been relatively empty handed to respond to this request, but finally we have some reference examples.
These lifecycles are now bound to the redeployment and undeployment of the web application artifact (WAR) and the execution of a JWebUnit integration test that exercises and validates the home page on each of the JSP and Wicket flavors of web application.
Instructions for Use
We’ve built a wiki page showcasing the usage of this archetype which we also invite you to review and improve. In short, you can inform Maven of the new archetype catalog via a quick execution of:
mvn archetype:generate -DarchetypeCatalog=http://dist.muleforge.org/maven2/
Lastly, for those of you that prefer a video walkthrough of the usage of these two archetypes, check out our screencast demo that takes you from start to finish of working with these valuable new tools in the Maven, Tomcat, Tcat, and web application development ecosystems.
Future Goals
Like all good developers, we are always looking towards the next iteration, just as the current ones are drawing to successful close. In the next release of these archetypes, or perhaps in supplemental sibling instances, we’re exploring:
- A zero-footprint, embedded Tcat installation that can be retrieved from a Maven repository.
- Profiles to allow for the integration tests to be selectively executed in a local or embedded Tomcat or Tcat installation, possibly auto-detected to activate the proper profile.
- Support for Maven provisioning of completed artifacts into Tcat server groups.
OSS Thanks
In closing, we want to thank the Tomcat community for founding such a great product and the Maven community for planting the seeds of these new archetypes. Java web application development is at its current fevered pitch, thanks, in large part, to these excellent tools and their communities.
A Set of Exciting Conferences
Sunday, April 4th, 2010I’m enjoying the privilege of being invited to several large conferences across the globe in 2010. Let me give you a brief overview of these exciting just-attended and upcoming venues…

Scandinavian Developer Conference
I just wrapped up giving my well heeled Open Source Debugging for Java talk to the wonderful folks at the 2010 Scandinavian Developer Conference in Göteborg, Sweden. Tomas and Lennart were the most wonderful conference hosts and the speaker dinner was world class. The conference was around 700 strong this year, which broke through expectations of growth from 2009. That showcases what a polished event Iptor hosts.
Many stateside colleagues joined me on this trip, including Tim Berglund, Paul Rayner, and Nate Scutta.

Great Indian Developer Summit
Next, I’m looking forward to the Great Indian Developer’s Summit in just a few short days from now. I’ll be speaking on a range of topics from iPhone Development for Java Programmers all the way to Dividing and Conquering large datasets with Hadoop. I’ve already been impressed by the helpfulness of the Saltmarch hosts, Usha Karen and Dilip Thomas.

Epicenter
In June, I’ve been invited to the green landscape of Dublin, Ireland to present at Epicenter. I’ll be speaking on iPhone development for Java Programmers once again (a topic I’m passionate and knowledgeable about) in addition to Encryption on the JVM.

UberConf
Just one day after returning from Epicenter, I’ll be speaking for four days in my hometown of Denver, Colorado at the newly minted UberConf. It will be a weekday show with a very unique pre-conference workshop (boot camp) on iPad Development for Java Developers. Ben Ellingson will be co-teaching this class with me.
There will be over 100 sessions at this unique conference, which is scale-tipping for an NFJS branded event. There are even registration levels that are all-inclusive, which works great for some corporately sponsored attendees. These unique (and quite successful) packages bundle travel, hotel, meals, registration, and an iPad. You’ll know your exact costs before you even take one step towards an airport.

No Fluff Just Stuff Series
And lastly, I’ll continue to present at my favorite recurring conference series, the No Fluff Just Stuff tour. There are at least 15 more stops on the tour this year and I hope to hit most of them. I’m looking forward to meeting up with a lot of the audience members that I had delicious breakfasts, lunches and dinners with in 2009 in the cities where the tour visits.
JavaZone 2009 Open Source Debugging Talk
Wednesday, January 27th, 2010Open Source Debugging in Norway
My Open Source Debugging talk that I gave at JavaZone, Oslo, Norway last September is online and can be watched in Flash format or downloaded as an M4V file. If you were not able to catch this talk at either this venue, or any of the many NoFluffJustStuff.com stops that I gave this talk at last year, give it a try and let me know what you think of it.
AppleScript to Re-Apply Finder Comments
Monday, January 25th, 2010Finder Comments Lost
When restoring from a backup, depending on the Mac-specific intelligence of your backup solution, or when copying files written by a 10.4 Mac, your Spotlight (Finder) Comments stored in the .DS_Store files might not survive the round trip. You’ll first notice this by the fact that your comments field or column is completely empty for files you know you previously tagged or made comments on.
Leopard, Snow Leopard Comment Storage
Tiger and previous editions of Mac OSX store Spotlight comments in the .DS_Store file exclusively. Leopard and Snow Leopard on the other hand, claim to maintain backwards compatibility by storing the Spotlight Comments in both the .DS_Store and the new Extended File Attributes. I question this thinking though, because Mac OSX developer Steve Gehrman of the awesome PathFinder team says that Finder, while it writes both formats, still only reads back the .DS_Store ones. It seems to me that Apple would have changed Finder to read from the newer Extended Attributes as soon as they started writing to those in duplicate.
“On Mac OS X 10.4 Tiger, for example, .DS_Store files also contain the Spotlight comments of all the folder’s files, whereas Mac OS X 10.5 “Leopard” stores this information in Extended file attributes.”
Script Research
Giving a tip of the hat to the similar-but-not-quite-what-I-wanted script that helped me get enough of the syntax working (using type alias instead of type file was tricky) get my own authored, I give you:
A MacOSXHints article, and the corresponding code
The Solution
To solve this extended attributes vs. .DS_Store discrepancy, we only need to read (from the extended attributes) and reapply (thereby recreating the .DS_Store) the same comment. The solution is this AppleScript. Just highlight the files needing the treatment in Finder, then execute this script from the AppleScript Editor.
The result is that Finder (which reads only the .DS_Store files) and PathFinder (which only reads the extended attributes) can both now see the Spotlight Comments.
Extras
If you would like your Mac to automatically clean up the .DS_Store files it writes out to flash sticks and network drives, check out BlueHarvest, an interesting little utility app that fills this need.
What’s the big deal about font choices in presentations?
Tuesday, January 19th, 2010Fonts and Presentations
Fonts, fonts, fonts. What’s this obsession? For those of us that share a passion for making presentation materials as comprehensible as possible for our students, sandwiched right between a great story and great delivery is a great font.
Reviewing the list
Once you’ve installed Microsoft Office, iWork, or Open Office, you’ll find that you’ve been granted a few (or possibly many) extra fonts installed into your operating system. This is a temptation you should approach carefully, just as you would the edge of a cliff. It is truly a time and design precipice you can fall off of into the abyss.
As you gradually approach this list of fonts, if you obsess over design like I do, you’ll let out an “Ooooooo” as if mesmerized by the quantity of selections you could make. A tool would be perfect here. Let me grant your wish with FontDoc for the Mac and WinFontsView for Windows.
Title versus Body
Now, you have a tool to whittle that list of massive fonts down to size. Let me give you two facets that will chisel it down even further.
First, use a maximum of two Font Faces per presentation. I’ll allow for three if you make judicious use of a handwriting font.
One font should be interesting and story-relevant. It should mesh well with your photography and choice of color in the slides. I’d suggest you primarily use it for titles, strong statements and short phrases. It adds spice to your presentation. Feel the freedom to have fun with your title fonts. I’ve recently styled a presentation on Hadoop with an African theme. I used the Tribeca font in the title and custom rhinoceroses for the bullet points (yes, I used some bullets).
The second (primary) font should be highly legible. I can’t stress that enough. For the portions of your slide deck that people will need to read (and quickly, so they can return mental focus to you), readability is the critical point. I always suggest sticking with a very legible Sans Serif font, as does Garr Reynolds of Presentation Zen Design.
I don’t always obey this rule of Sans Serif in the body, sometimes to my own peril. Fortunately, local audiences in Denver are kind, and remind me that I need to change it back.
Hello Verdana. Really, I didn’t mean to cheat on you! It was just that Aquiline showed up looking so stylish and I just couldn’t help it.
The finalists
The short list of Sans Serif fonts that I printed and put across the room is:
- Agenda
- Arial
- Bitstream
- Calibri
- Century Gothic
- Franklin Gothic
- Futura
- Geneva
- Gill Sans
- Helvetica
- Optima
- Heiti
- Trebuchet
- Verdana
I’d suggest you do the same. Also put them up on a projector if you have access to one. Do white font on black. Do black font on white. Notice the affect each font’s nuances have on legibility. Throw up some ranking numbers next to each. That’s precisely what I did. And I asked a few folks to give me their rankings too.
The winner
The variant that I (and my scientifically font-polled friends) love the most, is Helvetica Neue. The beautiful part is that it comes preinstalled on many systems these days, but can also be purchased online if you are on a OS or office suite that doesn’t include it.
In the life of a font, you know you’ve arrived when a movie is made about you. Yes, a biographical movie about Helvetica, the font named after Switzerland’s classical name.
Lest you think this is a factor of Steve Jobs and his Apple design shop, I’ll let you in on the secret that this predates the personal computer by several decades. Max Miedinger was the designer behind this font all the way back in 1958!
Conclusion
Give any of these Sans Serif fonts a try (but lean towards Helvetica!) in your next presentation and be sure to gather design feedback from your audience. I think you’ll be pleasantly surprised!
Shameless plug: Keep an eye out in 2010 for the Presentation Patterns book from Neal Ford, Matthew McCullough and Nate Schutta for a complete recipe book with easily digestible presentation improvement hors d’oeuvres like this one.
Presenting at the Great Indian Developers Summit
Wednesday, December 9th, 2009I’m very excited to announce I’ve been selected to present at the Great Indian Developers Summit in Bangalore, India in April. I just found out that my NFJS colleagues, Scott Davis and Venkat Subramaniam will be joining me there as well. It will be great to have familiar faces at this venue and to present to such a distinguished audience.
My latest DZone RefCard on the Google App Engine has been released
Tuesday, December 8th, 2009I’m excited to announce that my latest RefCard for DZone has been released. In a Q&A session with Lyndsey Clevesy, I discuss the card’s focus on helping developers get started with the Google App Engine for Java.
The RefCard is intended to be a jumping off point and provides information about and links to the frameworks that now support GAE as well as external resources to help you dive deep if this new arena of cloud computing. Grab a copy and send me feedback.
Encrypted SCM Passwords in Maven
Friday, August 28th, 2009A little late night hacking and I was able to get encrypted passwords to work in the Maven SCM plugin with Maven 2.2 based on the prodding of Kurt Tometich, an NFJS attendee, and his JIRA bug# SCM-495. Previously, this encryption feature only worked for Wagon providers (the connectors for uploading artifacts), not for SCM providers, contrary to some blog comments.
It was quite the effort. After a few minutes, I found the code in DefaultMaven.java that performed the decryption. Now, I thought, “just implement a similar call in AbstractScmMojo.java right?” I harbor a bit of angst for the fact that the JIRA isn’t Fisheye-connected to the source code repository, so finding the files changed for a given defect is much harder than it should be.
The Maven Mojo Developer Cookbook did offer a bit of insight (though syntactically off a bit on the container.getLookupRealm()) on how to get a handle to the container and look up the security provider, DefaultSecDispatcher.java.
SecDispatcher sd = null;
try {
sd = (SecDispatcher)container.lookup( SecDispatcher.ROLE, "maven" );
}
There was even the fabled “java.lang.ClassCastException: org.sonatype.plexus.components.sec.dispatcher.DefaultSecDispatcher cannot be cast to org.sonatype.plexus.components.sec.dispatcher.DefaultSecDispatcher” at one point. Oh nuts. Not the classloader scoping issue, please…
The trick on the classloader is that the DefaultSecDispatcher class is available via a dependency to plexus-sec-dispatcher, but also included (repackaged) in the Maven core distribution maven-2.2.0-uber.jar. So the SCM provider project’s dependency on plexus-sec-dispatcher has to be scoped as <provided> for compilation of the maven-scm-plugin.
Lots of learning about the Maven code base occurred. The only interesting finding was how, instead of putting the decryption on the accessor (getter) of password from the settings data structure, it is put in each place it is attempted to be used (e.g. the Wagon “dispatcher”, and now the SCM “dispatcher”). I’ll bring up a refactoring of that with the Maven IRC folks…
