Annotations are a new language feature introduced in Java 5 that allows Java code elements such as classes or methods to be annotated with structured metadata. This metadata can then be used at compile-time or at run-time by other code. Annotations are commonly used to provide configuration information for infrastructure frameworks to provide cross-cutting functionality.
Using […]
Java Server Pages (JSP) is a Java technology for rendering dynamic web pages. Unlike servlets written directly in Java, JSP files contain special markup to identify java or JSP code. The normal (non-markup) text is interpreted as HTML. Early in JSP’s evolution, custom tags were introduced as a way of providing reusable functionality, particularly reusable […]
Audit columns are a common design pattern used to record data creation and modification information for database tables. A typical implementation of this pattern is to add four columns to every non-static database table: CREATE_USER, CREATE_TIMESTAMP, UPDATE_USER, and UPDATE_TIMESTAMP. The create columns are populated only when a record is initially populated, while the update columns […]
My previous article started discussing Hibernate relationships, focusing on lazy versus non-lazy relationships. This article continues the theme by discussing how to improve performance when dealing with relationships in Hibernate through a feature called eager fetching.
Hibernate’s abstraction of database access behind getter and setter methods on domain objects hides potentially inefficient database access. Mindlessly using […]
Support for entity relationships is a great time-saving feature in Hibernate, but it can also be a trap for the unsuspecting developer. Handling relationships between entities can be a complex business, and I for one am glad for all the support that Hibernate provides. Hibernate’s assistance, however, can do more harm than good when it […]
Hibernate tries to hide the details of dealing with relational databases, but it is at best a leaky abstraction. At its most basic level, Hibernate is a framework that issues SQL commands to the database. Sometimes it does not do what you would expect or want (more on that in future articles). Therefore it is […]
Hibernate is a de facto standard for object-relational mapping. One of my recent projects involved the use of the latest version of Hibernate (3.2). Since I had not used Hibernate since its version 2 days, I picked up the authoritative reference Java Persistence with Hibernate which is co-authored by Gavin King, the founder of […]
My appreciation of the power of search, particularly for developing software, has grown over the last few years. The wise use of search can significantly increase your effectiveness as a developer, acting like an amplifier or expansion unit for your brain. Search allows you to navigate faster, remember easier, and know more.
I spend most of […]
Code reviews are an important practice for improving the quality of your software and ensuring that it is ready for release. Software engineering research has found that reviews (or inspections) are a powerful QA practice and have many advantages over testing:
A higher percentage of defects are found when using reviews – as high as […]
What is excellence in software development and how can you achieve it? This is a question of interest not only to software developers, but also to managers of software teams.
I recent read the book First, Break All The Rules: What The Worlds Greatest Managers Do Differently which provides some great insights into this question. […]
To code or not to code, that is the question for senior software developers when they are presented with the opportunity to move into an architect, project manager or team lead position. Rob Walling recently wrote an excellent article titled Why Good Developers Are Promoted Into Unhappiness describing his unsatisfying experiences as a manager and […]
When are you done writing a piece of code? Is it when you have implemented the necessary functionality? When you have tested it? I believe there is more to professional-quality code than just getting it to function properly. What else is there? Making sure the code is maintainable - well designed and understandable. I use […]
If you are a software developer and have not maintained operational applications with real users hammering away at it, then you are missing some important lessons. You might not fully appreciate the operational challenges facing the maintenance and support team, particularly when the software in question is suffering in the areas of reliability, performance, or […]
I am a big fan of the agile philosophy of software development as summarized by the Agile Manifesto. The agile approach fits well with my pragmatic mindset, and I consider myself an agile practitioner, despite currently working in a bureaucratic environment providing application development and maintenance services to a large, process-heavy government client.
But then […]
As a software developer what practices do you consider essential? Which practices are must-haves that you would refuse to build software without?
I believe that producing good software is hard, and that we software developers need all the help we can get in developing software. I have put together a list of the top five practices […]
There is always something more to learn. That was the lesson for me last week when I learned something new about the Java programming language, despite having used professionally it for almost 10 years.
I was upgrading a Java web application to WebSphere server version 6.1 and as the first step I switched the development environment […]
My previous article discussed the question how much do you code?. After thinking more about this, I realized that a more important question is whether you are doing enough coding. How much is enough versus too little? This depends on the reasons why you code.
For myself, I can think of several reasons why I […]
As a software developer, how much time do you actually spend writing code? I recently have discussed this topic with both junior and senior coworkers, from which I have realized that this is a very important question for many developers. The amount of time the average developer actually spends coding can be surprisingly small, and […]
In my previous article Architecting for Deployability, I wrote about the importance of deployability - how reliably and easily software can be deployed from development into the production environment. To accomplish this, one approach I recommended was to encapsulate differences between environments to isolate them from the majority of the application, and thus simplify deployment. […]
Deployability is a non-functional requirement that addresses how reliably and easily software can be deployed from development into the production environment. For desktop (client-side) software, deployability addresses the installation and update mechanisms that may be built into the software itself. For server-side software, deployability is addressed through the system architecture and the deploy process. The […]