About

Personal Photo Location :
Cleveland,OH,USA

Origins :
Manchester, UK

Contact Me

I've been developing software for over 15 years working in Delphi and now Java. This site is a home for my open source projects, writings, articles and tutorials mainly focusing on Java and Java EE.

Archives

I think choosing a framework is hard because no framework is perfect. Every framework under consideration is like a Porsche with a gaping hole in the side that just ruins it. The very act of choosing a framework means that you are knowingly accepting every little ugly wart and blemish of that framework, and explicitly saying “Yes, I want to deal with that problem everyday for the next few months!”. We aren’t built to choose things that are going to cause problems for ourselves.

It’s one of the reasons I always revisit the state of web frameworks now and again to see what pain points have been cleared up and what new ones have been created.

By Andy Gibson • September 1st, 2010 • in Articles 2 Comments

When I talked about how Context Matters When Discussing Frameworks I intentionally left out naming any picks because the point of that article wasn’t to start a framework debate (neither is this one, but at least it will get isolated in here). In this post, I’ll cover my choice of frameworks.
(more…)

As if web framework religious discussions weren’t annoying enough, one thing that I always think is missing from such debates is context regarding the type of application being developed. It’s like discussing the best mode of personal travel without taking the type and size of journey into account. There’s a reason why you walk to the mailbox and drive to the store. You can drive to the mailbox but it will incur costs greater than the benefits. Similarly, you can walk to the store as long as it isn’t too far, you have the time to do so and you aren’t buying much.
(more…)

This tutorial will demonstrate a pattern for creating CRUD applications in JSF and Java EE 6. While this is not the only way of implementing this mechanism, it does promote re-use and can give you essentially zero code CRUD pages requiring just the view code. The goal is to provide a single structure that provides the particular feature of being both stateless or conversational where we might want a conversational edit page and a stateless view page. This pattern is based on the EntityHome pattern that was used in JBoss Seam and carries over well to Java EE 6 with CDI. This is something I use all the time to make view/edit pages really quickly and unlike most of the automatic scaffolding in other frameworks, doesn’t need re-writing to go into production.
(more…)

The previous version of the Knappsack Maven Archetypes included archetypes for creating projects using JSF, JPA, CDI and Bean Validation that can run in a servlet container such as Jetty or Tomcat. In order to put it through its paces I decided to create a little test social bookmarking application that lets users create accounts, and when logged in, add bookmarks and tag them. Users that are not logged in can view the bookmarks and filter them by user or tag, and the results are paginated.
(more…)

One of the first Seam 3 Modules to appear is the Seam Faces module which provides additional functionality to JSF. While there aren’t many pain points left in JSF, one of the biggest is the issue of data converters for entity objects. This article will take a look at how Seam Faces takes the pain out of writing JSF converters.
(more…)

By Andy Gibson • August 16th, 2010 • in Articles 4 Comments

This is the first in a series of articles looking at the conversation scope introduced in CDI as part of Java EE 6. We’ll start by looking at existing scopes and how they introduce limitations for developers and how CDI conversations get around these limitations.
(more…)

There are many times you might find yourself with a need to insert constant data into a SQL table using a hand written SQL statement. Here’s a shortcut to save you some time and typing to generate the necessary SQL.
(more…)

The latest version of the Knappsack Maven Archetypes now supports creating Java EE 6 applications for servlet containers. These projects includes configuration for core Java EE 6 technologies such as JSF, CDI, JPA and Bean Validation and can be run from the command line using the embedded Jetty and Tomcat servlet containers.

Also with this latest release, all the archetypes are available in the Central Maven Repository which means you can dive straight in and create a new Maven project using these archetypes :
(more…)

By Andy Gibson • August 12th, 2010 • in Articles 2 Comments

In part 1, we looked at the basic structure and configuration of the project that is common in all the archetypes. This time we’ll look at the minimal archetype that contains some more functionality and a number of different classes used to implement that functionality. (more…)