Table of Contents

 

Copyright

Brief Table of Contents

Table of Contents

Preface

Acknowledgments

About this Book

About the Authors

About the Cover Illustration

1. Programming beyond Hello World

Chapter 1. OSGi and the enterprise—why now?

1.1. Java’s missing modularity

1.1.1. Thinking about modularity

1.1.2. Enterprise Java and modularity—even worse!

1.2. OSGi to the rescue

1.2.1. Modularity, versioning, and compatibility

1.2.2. Dynamism and lifecycle management

1.2.3. Why isn’t everyone using OSGi?

1.2.4. Why OSGi and Java EE don’t work together

1.3. Programming with enterprise OSGi

1.3.1. Enterprise OSGi and OSGi in the enterprise

1.3.2. Dependency injection

1.3.3. Java EE integration

1.4. Summary

Chapter 2. Developing a simple OSGi-based web application

2.1. The development sandbox

2.1.1. Introducing Apache Aries

2.1.2. My first enterprise OSGi runtime

2.2. Writing an OSGi web application

2.2.1. Building a simple OSGi web application bundle

2.2.2. Deploying and testing

2.2.3. A familiar feeling—and important differences

2.2.4. Spicing things up with fragments

2.3. Decoupling with dependency injection

2.3.1. Inversion of control

2.3.2. Introducing the Blueprint service

2.3.3. Coupling two components with Blueprint

2.4. Bridging JNDI and OSGi

2.5. Summary

Chapter 3. Persistence pays off

3.1. Java and persistence

3.1.1. Making persistence easy

3.1.2. The problems with traditional persistence in OSGi

3.2. Building a persistent application