An issue that recently gave me something to gnaw on was that of auto-starting an EJB: I wanted to achieve the effect that an EJB within a Java enterprise application would become active (and in that special case, connect to another component on another machine) as soon as it was deployed (or the container was started). If possible, I wanted the solution to be container independent. After a lot of googling and trying, I found a solution that works, but it is probably one of the most awkward hacks to solve a problem that sounds as simple as this.