Software engineering sometimes seems like a struggle against spaghetti. Without lots of care, modern projects risk becoming an unwieldy tangle of closely-coupled code whose behaviour and dependencies are mostly unknowable. OSGi can help keep the complexity at bay, but until recently OSGi didn’t play very well with modern enterprise programming models such as dependency injection, WARs, JPA, and application deployment. The Enterprise OSGi programming model is changing all this, and can help keep your applications from descending into a noodly mess. This session will discuss the basics of OSGi modularity, and demo the build tools, middleware, and architectural principles which can be used to turn a chunky WAR into a lean, mean, extensible OSGi web application.