A while back, I had a technical interview where I was required to write some sample code. This idea seemed pretty normal until my interviewer described what would be expected. “So far we have a good impression of you. But now we would like to see how you code. So why don’t you come into our office, and create a simple java web application. Bring your own laptop if you like. You can use the Eclipse IDE, a build tool such as ant/maven, an application server like glassfish/tomcat/jetty, a persistence framework such as hibernate/ibatis/jpa, a database, and a web framework. Unit tests would be nice as well.” Sure. No problem.

For a moment, I panicked. First, I didn’t really have a nice Windows laptop to bring to the interview since I did all my programming on the desktop PC at work. I had just gotten a new Mac OSX laptop for personal use and even though I had heard people say how great macs are for programming, I didn’t exactly know where to begin. I rummaged around the internet and began to set things up. Java on Mac OSX was a whole new world. And then, there was the question of the best way to develop, build, and deploy the application. This was supposed to be a simple example. It was all about knowing how to code more than anything else, so downloading and setting up a bunch of heavy enterprise tools and plugins seemed out of the question. When it came to programming, I had used many different frameworks in all the projects I had worked on as a consultant over the years, but which did I consider to be the best ones? What were the best architectural practices? How would I write unit tests for all the different application components?

After reading through several manuals and scouring the internet for articles, debates, and tutorials, I created a prototype to prepare for the interview. Everything went fine to my relief, but the challenge didn’t end there. Since creating the initial prototype, I kept thinking what a cool exercise that was, and I continued to build the prototype concept and revise it. Its essence became the ultimate challenge for me. I began to outline what I thought were the most essential components of modern java enterprise web applications, and the simplest way possible to illustrate them. In my experience I have found that programmers are somewhat impatient and lazy, and want to get something up and running fast and then understand it. So that is the basic objective here. The example I use may seem overly simplified but that is the whole point. Less code, more concepts.

I later decided to transform the prototype I created into an incremental tutorial series so I could share it with others. The great thing about it is that it assumes only basic knowledge of java, html, persistence, and web frameworks. It is meant to take you from the very beginning of setting up your development environment to making your first build to adding the web layers, persistent layers, security, logging, and unit testing. Then you will be able to continue building your own prototype. I have made very careful selections of what I think are the best frameworks and tools to use that are available at this time. And, I have chosen the most logical and efficient ways to use these frameworks (that I could think of, at least). I also found a way to build and deploy the sample application that is just simple and good for learning, and similar enough to an enterprise experience. And best of all, everything is free and easy to download and set up!

Acquiring new knowledge and skills can seem overwhelming. But don’t despair! Just keep this in mind:

Like anything, the greatest challenge is getting started.
To really understand how to do something, you have to actually do it.
To remember it well, you have to do it again and again.
You don’t need a complex example to explain a simple concept.
Always master “Hello World” first, then build on it bit by bit.
Be aware of all the different ways to do things. Choose the best methods for your needs.
Have fun.


Post a Comment