Monday, December 31, 2007

Eclipse Startup Options: showlocation

If you are like me, then you probably have multiple installations of Eclipse installed on your computer. For example, I have one install for all of my JEE development, and another for my RCP development. One of the hardest things that I have found is distinguishing between which instance I am currently running.

Recently, I learned about the Running Eclipse startup option called "showlocation". By leveraging this startup option, you will always know which version of eclipse you are running because it will show you your workspace in the Eclipse title bar. Even better, if you are using at least Eclipse 3.2 - which was last year's Callisto's release, you can pass a String to describe the instance that you are currently running, and that will be shown in the Eclipse Title bar instead of the workspace.

Here is how I have my shortcuts currently configured:

JEE version
C:\myPrograms\Eclipse\eclipse-jee-europa-win32\eclipse\eclipse.exe -showlocation JEE -refresh -vmargs -Xms256M -Xmx256M

RCP version
C:\myPrograms\Eclipse\eclipse-rcp-europa-fall2-win32\eclipse\eclipse.exe -showlocation RCP -refresh -vmargs -Xms256M -Xmx256M

Share and enjoy...

Wednesday, December 19, 2007

Is Mac redefining PC?

Apple may be well on the path to redefine the term PC. For years now, PC has been synonymous with Windows machines - instead of it's true definition of Personal Computer. With the current advertisements from Apple, we may have to adjust our definition of PC.

Don't you just love the new Apple commercials, comparing Windows and the Mac? Whoever is heading up this marketing campaign is earning every dollar of their salary and then some. I am curious to how many people will be receiving their first Mac this year for Christmas. I am pretty sure that I will be part of the crowd.

For years now, I have wondered why so many of my software developer friends prefer Macs to Window machines. I have had the stereotype that Macs were used by people who enjoy web development and graphic design. I always assumed that these types of people was the crowd that Macs were appealing to. My perception changed when I found some hard core Java developers who prefer the Mac environment to Windows. Then, I watched the demo of the latest release of OSX, Leopard, and I was hooked. The features and functionality that comes standard with this OS is simply amazing, and it appeals to everyone, not just software developers.

What does this mean to me? If I am right, and more people start switching from Windows to Mac, then that means that the overall Windows community is going to decline over time - windows specific languages, may not be the best investment of time and effort in learning. The current perception is the .NET should be used to develop desktop applications on the desktop while Java is more suited on the server. In the long run, maybe Java will not only reign supreme on the server side, but also on the desktop.

What are your thoughts?

Thursday, December 13, 2007

OSGi on Software Engineering Radio Podcast

The Software Engineering Radio Podcast if featuring an interview with Peter Kreins and B.J. Hardgrave on the subject of OSGi. For many people who ask me what OSGi is and why would someone want to use it, this is a great place to start. Enjoy.

Monday, November 19, 2007

GLSEC was awesome...

The Great Lakes Software Excellence Conference was great!!! I had a chance to meet some of the technical talent here in West Michigan (and beyond), and learn a lot of new and interesting things regarding technology and Project Management.

One of the greatest parts of the conference was listening to Bob Martin speak. I have never heard him speak before, and he is great. He is very passionate about software development. I took away many of nuggets of wisdom from his talk titled Clean Code, and I will plan to share some of them in future posts.

Overall, I think that my talk, Classical vs. Mockist Test Driven Development was well received. I was definitely nervous, especially since I had to follow Bob Martin's Clean Code talk. In the end, however, it is very natural to talk about a topic that you enjoy - in this case Test Driven Development.

I also attended the first day of tutorials offered at the event. I spent the day with Chad Fowler, learning Ruby and Ruby on Rails. I was really impressed with what is capable with Ruby on Rails. To be able to whip out web applications so fast with such little effort, is definitely enticing. If you are a Java Developer, I highly recommend you taking the time to look at this language. I believe that in the future, dynamic languages on the JVM is going to become more and more popular, and it will be important to know these concepts in the future.

Standing ovation to all of the people who dedicated so much time to the GLSEC making this event the success that it was. I am definitely looking forward to it next year.

Wednesday, October 24, 2007

Presenting at GLSEC

Great news!!! Yours truly was selected to present at this year's Great Lakes Excellence Software Conference to be held November 7th and 8th in Grand Rapids, Michigan. I will be presenting on the topic of Classicist or Mockist Test Driven Developer - a continuation / explanation of my original blog post of the same name.

Although I have spoken many times at different local user groups, this will be the first time that I have submitted and been selected to speak at a conference. I have found the whole experience to be quite rewarding thus far - submitting the talk to the council, receiving the acceptance letter /email, and preparing for the presentation.

In addition to being excited about speaking at the conference, I am also excited about meeting and networking with so many wonderful technology professionals. Some of the people you may recognize that are going to be at this event include Bob Martin, of Object Mentor and Chad Fowler the Ruby Maestro. Chad Fowler wrote a very interesting book titled My Job Went to India: 52 Ways to Save Your Job. I have not had a chance to pick up my copy yet, but I did get a chance to listen to a podcast where he was interviewed about his book, and was very impressed with his thoughts and ideas.

I hope that you are all able to go to the conference. I am sure that it will be a great time.

Friday, September 7, 2007

Object Oriented or Still Procedural Driven?

Well, according to Chris Richardson, I am not the Object Oriented Developer that I thought I was. In his talk at SpringOne 2007, he challenged his audience to question whether they are actually doing OOD (Design / Development) or if they have carried over the habits of Procedural Programming into the Java language.

I must admit, he has made me think. Many of the points in his article reflect the types of projects that I have been on - heavy service objects full of business logic while the domain objects are basically reduced to Value Objects / Entities to persist without any business logic being in them. His argument is that this is fundamentally procedural programming brought into an Object Oriented programming language. Instead, we should have the business logic contained within the domain model (which includes both business logic and state) and the service objects that use them are a thin layer around the domain model that clients delegate to.

Overall, I think that this may be a "purist" position on OOD, and I am suspect of the claims of ease of maintainability and supportability are really true. Of course, I am speaking from the position of not having any experience with this style of programming - but I am very curious about it. Ultimately, I do believe that he is promoting the Domain Driven Design approach to software. Does anyone have any experience with Domain Driven Design? Can anyone vouch for this style of programming?

Tuesday, August 21, 2007

iTunes, you are working my nerve...

I don't know if you have experienced this or not, but lately, I have been hammered with so many updates to Apple's iTunes product. Funny how all of these updates coincided with the release of the iPhone. My thought is that they are using these releases of iTunes in order to patch the iPhone. I don't have an iPhone, nor do I plan on getting one. I use iTunes and Quicktime for it's original intent, playing music and watching video.

Is Apple trying to accomplish too much with iTunes? Is it time for them to develop a more modular product that will offer consumers exactly what they need and ignore the rest? If I was at Apple, I would definitely suggest a move like this in their product development. The alternative is to have disgruntle consumers who through the countless number of patches will either lose faith in the product's stability, or simply become annoyed to the point of considering alternatives. Speaking of alternatives, does anyone have any?

Thursday, August 9, 2007

SpringFramework Nugget...

Recently we were dealing with an issue in a Spring based application that was causing us some real problems. We had an integration test that we were using to perform some black box testing. Unfortunately, we were getting test failures because the unexpected state of the springletons (not true singletons, but through the use of spring, they act as singletons). When running a subset of our tests individually, they had no problem. However, when ran in a suite, those same tests that succeeded on their own, now failed.

After some digging, we found that a test that was running earlier was putting the springletons, in an unexpected state, affecting the remaining tests. In order to resolve this issue, we used the setDirty() (See section 8.3.1) on our integration tests to make sure that Spring would reload the objects anew.

I hope this little nugget of information helps someone else out there...

Saturday, July 21, 2007

Barcamp Grand Rapids Returns!!!


We are in the final sessions of the 2nd Annual BarCamp Grand Rapids 2007. Last year was fun, but this year was a blast. Kyle Adams and Dave Brondsema really put a lot of effort into making this year's unconference a success.

Two Google employees, a Senior Technical Recruiter and a Linux System Administrator, made the event this year, with plenty of swag. They gave away T-shirts, notebooks, pens and one lucky guy walked away with an iPod. Envoi Solutions, funded the party. There was great food and great drinks. Some of the interesting talks and Lightning Talks (LT) included:

Package Management for Ubuntu - Matt Alexander of Google
Design Eye for the IT Guy - Kyle Adams
Interaction Based Testing - Matt Heusser and Sean McMillan
(LT) :- SOA and Transactions
(LT) :- Re-inventing the Wheel

The presentations and the content were great, but the best part of the unconference was the people. At this type of event, it is the people that make the conference what it is. Since there was such a great group of people, I think that is what made this years event absolutely great. Looking forward to it next year.

Thursday, July 5, 2007

Model View Presenter

For those of you that did not come to the last Perl User Group meeting, you missed a great presentation which prompted a wonderful discussion on the Model-View-Presenter Pattern (MVP). Primarily being a J2EE developer and with many years of experience with the Struts Framework, I am very familiar with the Model-View-Controller (MVC). I was very interested, however, in this MVP pattern. This is mostly due to the thick client application development that I have been doing lately.

During the meeting, a lot of questions were raised regarding this pattern, and Jason Porrit was very patient with all of us (touche'). After the meeting, I decided to do a little more investigation, and found the following:

Martin Fowler Retires Model View Presenter Pattern

Yes. Believe it or not, this pattern has been retired by Martin Fowler. Well, I don't know if retired is the correct 'r'-word. Maybe it should say 'R'efactored instead. He has split up the pattern into the Supervising Controller and the Passive View. After reading both of the patterns, they sound very similar in detail and in practice. In the Passive View you put all of the widget population logic into the Presenter. All logic is pushed on the Presenter including the population of text fields or any other widgets available on the View. In the Supervising Controller, you push most of the logic onto the Presenter, but leave some of the logic of populating widgets in the View. Martin states:

"...the essence of a good Supervising Controller is to do as little as possible. Let the view handle as much as possible and only step in when there's more complex logic involved."

Atomic Object Presenter First
On a related note, Atomic Object also has their own variation of the MVP Design pattern called Presenter First (PF). After reading an article from Better Software magazine (referenced from their PF resources), I find this design pattern very attractive as well. What most attracts me is the concept of linking different PF triads in order to orchestrate behavior and a process. Please refer tot he Better Software article for more information on this.

Overall, I owe a big thanks to Jason for inspiring me to learn more about this design pattern. I look forward to hearing him present in the future.

Wednesday, July 4, 2007

CXF 2.0 Released...

At long last, I am very pleased to share in the celebration on the release of Apache CXF. Apache CXF is the culmination of two seperate projects: Iona Celtix and the open source tool XFire hosted at Codehaus, both serving the SOA community.

I have been using XFire on a number of contract projects lately, and I have found the product to be very easy to use and extremely reliable. Fellow blogger, netzooid, goes into more detail of what XFire fans can benefit from with this rebranding and stable release.

Congratulations once again to the entire team.

Tuesday, July 3, 2007

Eclipse Europa - the Good and the Bad

After using Eclipse Europa for the past couple of days, I thought that it would be a good idea to share my thoughts on this latest release.

the Good...
This new version of Eclipse has many wonderful and new features and shortcuts. My two top features are the CTRL+3 and the View folding.

CTRL+3 allows you to search across the entire Eclipse platform, matching on Views, Menu Items, and other parts of the Eclipse system. I am a huge fan of keyboard shortcuts. I believe that through their use, you can save lots of time and increase productivity. If you do not believe me, think about the time that it takes to move your hand from the keyboard to the mouse and click on a menu item. It may not seem like a lot of time, but how many times do you do this during the day? week? month? This shortcut just adds to my arsenal of productivity boosts.



The other enhancement that I am enjoying is the folding of the Views. In the older versions of Eclipse, when you collapsed a view stack that resided on the left portion of the screen, they would leave a thin collapsed view on the screen. Now, when collapsing views, they completely collapse and minimize to the left most portion of the screen. This leaves much more room for the work that you are actually focusing on.

the Bad...
Yes, believe it or not, there is something that I do not like about the new version. It goes back to my earlier statement of short-cut keys and committing them to memory to boost productivity. In Eclipse 3.2, I often found myself needing to surround code with a try catch block. I did it so often that I found a shortcut key that would do it for me. That shortcut key was Alt+Shift+Z, 4, as shown by the screen capture.





For some reason, in the Europa version, they decided to change this. Instead of it being Alt+Shift+Z, 4 it is now Alt+Shift+Z, 6. I know that this may seem minor, however when you get used to using something, like a short-cut, I don't think that you should ever change it. It makes me wonder what else they may change in the future.



Overall...
Overall, my impression of the new version of Eclipse is absolutely great. I have enjoyed this release thus far, and I am looking forward to learning more about it in the future.




Friday, June 29, 2007

Eclipse Europa Releases Today...

We are one hour away from the annual simultaneous release of many Eclipse Projects. This year's release is titled Eclipse Europa, which will include 21 different Eclipse Projects. Hats off to the Eclipse Team and Community for coordinating such an effort.

Unlike the iPhone, which also releases today, this is the product that I am sure to acquire. Speaking of the iPhone, here is a list of highly anticipated features as reported by the Onion.

Enjoy.

Saturday, June 9, 2007

Eclipse Europa Releases Soon...

Has it been a year already? Is it really that time again?

The annual release of the Eclipse projects, is just 20 days away. This years release, titled Europa, is sure to clog the "series of tubes" (Senator Ted Stevens) that the internet is, due to the massive downloading that will be taking place.

To learn more about this release:

http://www.eclipse.org/europa/

Congratulations and thank you to all of those whose efforts have made this possible.

Wednesday, May 9, 2007

Chasing your Dream...

I had a chance to attend a free conference last night. Unfortunately, it was not what I expected it to be, but I did pick up a lesson or two, which has made all the difference.

Overall, the conference was a sales pitch for additional training (which of course was not free), but they promised that the training was going to open the doors that would allow you to achieve your dreams. There was a part of the conference where we were asked to visualize our dreams and what we wanted to achieve in life. For me, this part of the conference was the most valuable.

How many of us actually take the time to think about our dreams / goals? Are we able to visualize them? Are we able to verbalize what it is that we want to accomplish? How many of us have settled for the status quo? How many of us have gotten so wrapped up in the hustle and bustle of our lives that we have lost sight of our dreams? How many of us have actually forgotten what it is that we want to accomplish?

Here is my challenge to you. Take time for yourself today and think about your dreams and your goals. Take a walk over lunch, or turn the radio / mp3 player off during your commute to work, and remember what it is that you would like to achieve. Develop a statement, a few sentences that becomes your mantra. Do whatever it takes to get excited and start chasing your dream.

Thursday, May 3, 2007

Eclipse RCP Presentation

I am just completing a tour where I presented Eclipse SWT / JFace and RCP to both the Grand Rapids Java User Group (GRJUG), and the Ann Arbor Java User Group (AAJUG).There are a few items that I am going to change in the content, but overall, the impression the audience gave me was that they were pleased.

I have been fascinated with Eclipse and Eclipse RCP for many years now, but never really had an opportunity to learn more about it. At one point, I tried to teach myself the framework for a contract, but was intimidated and decided to put it on the shelf for later. (For that contract, I just used SWT directly instead of using the Rich Client Platform.) After recently attending a training session on Eclipse RCP, I have found new confidence in the technology, and I am looking for opportunities to gain more experience.

Are you currently doing thick client application development? If so, what kind of technologies are you using? Are you using a Rich Client Platform? Eclipse or Netbeans or other???

Thursday, April 19, 2007

Instantly Become a Better Developer

If you are not interested in becoming a better software developer / engineer, you do not need to read this post. However, if you have an inner desire to improve your skills (with minimal investment), please read on...

Static analysis tools are a great way to becoming a better software developer. These tools have the ability to scan your source code, and give you feedback that can make your applications run faster and less prone to errors.

FindBugs, by Bill Pugh and his team, is a great example of a static analysis tool. After listening to his interview on the Java Posse, I was very interested and excited to give FindBugs a try. After installing it as a plugin for Eclipse, I ran it on a random project that I had in my workspace. It notified me of some areas where the code could be improved, but it also gave a very clear explanation of why it was making the suggestions it made:

FindBugs Explanation

So if you are interested in becoming a better software developer, I don't think you can get a better return on your investment than employing FindBugs, or any other static analysis tools.

Classicist or Mockist Test Driven Developer

I just read an interesting article titled "Mocks Aren't Stubs", by Martin Fowler. In this article, he explains the difference between a Classicist and Mockist TDDer (Test Driven Developer). After reading the article, I started to reflect on the TDDer style I have been practicing and if I needed to reevaluate my strategy.

When I first started practicing TDD, I didn't use Mock objects. Instead, I relied heavily on Dummies and Stubs. If I was unit testing object A that collaborated with object B, then I would have a stub implementation of B that had states that could be set. For instance, if I was testing method A.calculatePay(), that called B.getHourlyRate() that returned a Float, then the stub implementation of B would have a method called setHourlyRate() giving me the ability to control what was returned from the B.getHourlyRate() method. This approach did meet my needs, although it really cluttered up my testing package and the stubs soon became very messy. Imagine if B.getHourlyRate() returned a Float but also had the possibility to throw 3 different types of exceptions that should be handled differently in object A. If this was the case, I had a very complicated stub implementation of B in order to control whether to return the Float or throw 1 of the three exceptions. By doing this, I found myself writing more code to control the behavior of the stub implementation rather than testing A.calculatePay().

After I became familiar with mock frameworks, it really simplified my unit tests. Instead of creating a stub implementation of B, and programmatically controlling it's behavior, I leveraged a mock object framework that did most of the work for me. The Tests with Mock Objects portion of Martin Fowler's article shows examples of how this can be accomplished. What I found was an increase in productivity because I was no longer focused on building stub code to handle all of the different cases, but actually working on testing A.calculatePay().

Ultimately, whether you call yourself a Classicist or Mockist TDDer, in my opinion, as long as you are practicing TDD, you are on the right path.

Knowledge Portfolio Investing Suggestions

After 7 years of experience in Software Development, I have learned that it is absolutely critical to your career to continually invest in your knowledge portfolio. When I refer to the Knowledge Portfolio, I am talking about your personal bank account of skills and experience that someone is willing to pay for. It is the selling point to our customers. It is the reason why they will choose us over someone else vying for the contract - and let's be honest, we are all selling our skills to a customer whether we carry the title of consultant or permanent employee. When investing in my portfolio, I have learned that diversity and focus are two important things to consider.

Diversity

When trying to decide what to learn next, take a minute for self assessment. Should you focus your time on a hard skill or is it time to invest in a soft skill. Many of us are eager to learn the latest framework or programming language (both of which probably solves the same problem that the old framework and programming language did), but do we take the time to invest in our softer skills, like how we relate to others? I have just started to read, for the third time, 7 Habits of Highly Successful People. Every time I read this book, I learn more about myself and acquire practices that I can put into place that will increase the quality of my relationships with others. For those of us that do not work in silos, and we either report to someone or have others report to us, maybe we should consider enhancing our interpersonal, communication or some other soft skill.

Focus

Since time is precious, and in short supply, be focused during the time that you have set aside for your portfolio investment. I think that it is completely appropriate to spend the first 5 - 10 minutes of your investment time, planning what it is that you are going to accomplish. Define your goals and how you are going to meet those goals. At the end of your time, critique how you did. Did you meet your goals? How could you have been more productive and what are you going to do next time in order to ensure that you are more productive? This may seem like a tedious exercise, but speaking from experience, I know how much time can be wasted without clearly defined goals of what you are trying to accomplish.

As you know, technology moves pretty fast. If you want to move with it, make sure that you are spending the time necessary investing in your knowledge portfolio.

Wednesday, April 18, 2007

Apache Geronimo First Look...Impressive

I have a tendency to be curious about everything. Software development and design, is no exception. Lately my curiosity has led me to taking a look at Application Integration Solutions.

Examining the experience that I have with various integration techniques, (Socket Layer Communications, Remote Method Invocation, Web Services) I realized that the one that I was missing was Message Driven Beans (MDB). So I decided the other night to give both MDBs and Geronimo a try.

After installing Geronimo I immediately went to their Wiki to learn more about the deployment architecture. I was very surprised to find source code for an MDB, along with step-by-step instructions on how to build and deploy it. I was excited, but I tempered my excitement by recalling all of the other tutorials that I have gone through in the past, that reportedly worked at one point and time, but not when you were running it locally on your machine. Has anyone had this type of experience?

So I took a deep breath, and decided to walk through the tutorial anyways. Imagine my excitement when everything worked perfectly the first time without any problems. In under 20 minutes, I had a fully functional MDB deployed on Geronimo. Instead of wasting precious time, trying to investigate problems with Geronimo or the given source code, I could now start investing time into learning more about MDBs.

Special kudos to Lasantha Ranaweera, who I am assuming is the developer who wrote this great introductory example of working with MDBs, as well as the Wiki editor that put together such a nice tutorial on how to build and deploy this application on Geronimo. With this level of quality in both source code and documentation, I am planning on using Geronimo for all of my JEE adventures of curiousity.

TDD Koolaid :- Sip don't Chug

I have been getting into a lot of discussion lately regarding Test Driven Development. For those of you that do not know me, I am a TDD practioner (some may call me a fanatic). However, I was not always that way...

My TDD journey began a couple of years ago when someone handed me the book Extreme Programming Installed. I was part of team given the task to evaluate different Methodologies for Software Development. Fate led me to study Extreme Programming, but I will leave that for a different post. In my view, the best way to learn something is to put it into practice. Test Driven Development seemed like as good a candidate as any to start learning Extreme Programming, so I did.

Starting to practice Test Driven Development was not easy. For so long, I had operated in the mode of "Coding Blindly". The cycle of doing J2EE development was lengthy and insane: write code, compile, build distribution, deploy to application server, pray that it works!!! To change that mindset, as ridiculous as it was, was a challenge. Instead, I started to force myself to write tests against the business logic layer of my application. (Only recently have I started writing tests against the Data Access Layer, due to lack of methodologies of doing so). By writing my tests first, no longer was I operating blindly. Through the use of expectations, I had a goal in front of me that I was trying to reach and I was rewarded by the "almighty green bar" when I reached it.

I actually found myself working less. By writing the tests first, and building tests against objects and methods that were not even created yet, I allowed the IDE (Integrated Development Environment) to do all of the heavy lifting for me. With a click of a button, I was able to create classes and methods that allowed my tests to compile. With some creativity, I was able to control behavior of the dependencies, and test many scenarios that were impossible if not difficult to do while I was "Coding Blindly".

I have to admit, TDD was not easy to get used to. It required a lot of time, patience and research. I would like to challenge all of you who are reading this post to start applying some of the test driven practices. If you are having a hard time "chugging the TDD Koolaid" sip it instead. Take small steps and watch how more productive you become, how clean your code looks, how much more secure you will feel in the code that you write, and not to mention how much fun it will become.

Monday, April 16, 2007

Switching Blogs

Well, I have finally decided to create a new blog. I got tired of all of the spam that I was receiving from my previous blog. So much so, that I found myself less eager to create any more posts, in fear that it would lure more spammers. So, instead, I have decided to make blogger.com my new home.

Let me introduce myself. I am an owner of a consulting company / software developer / trainer / open source fan / family / Christian young man. I wear many titles, so you never know what you might find on this post. I may share some good tips and information, or I may reach out and pose some questions. It should be fun.

Looking forward to hearing and talking to you.