Untangling a Gigaspace Pojo

December 21st, 2009 / Transient Technology

A hibernate entity class is annotated describing to hibernate how its to be persisted. Annotate this class with JAXB for a transformation, chuck in some gigaspace annotations so we can add it to a cache and things start to get messy. Worse still gigaspace has some tight restrictions surrounding what it requires from a pojo, hibernate has others. Its tempting to leave the resulting class cluttered with these soft concerns. I propose a solution using composition that allows for easier maintenance ongoing.

Comments are closed.