Taking it step-by-step

As mentioned earlier, we will construct this target application in small steps from the bottom up. At every step, the functionality related to OSGi and to Felix will be introduced and explained, thus constructing your knowledge base progressively.

In the previous chapters, you took a dive into the OSGi world and got your environment ready for development by installing the Felix Framework Distribution. Also, you quickly covered an introduction to the Felix Gogo shell. Your system is thus set.

Here, we've established the scope of work and defined the application blueprint. The rest of the book will take you through the implementation and testing of the application.

For the first integration with the OSGi framework, to understand how a bundle interacts with it using bundle activators and the bundle context, we start with the inventory bundles in Chapter 5, The Book Inventory bundle. Those require no interaction with other bundles and will be a good start.

Chapter 5 will also cover how to use the Maven build mechanism to simplify the development of OSGi bundles. It will take you through the definition of a POM for the bundle, the structure of the project contents, and the execution of the build lifecycle to deploy it.

Then, after learning about the OBR service, in Chapter 6, Using the OSGi Bundle Repository, you'll install and start the inventory bundles on the Felix framework and quickly test them.

By then, you would have covered a complete develop-to-test cycle; it's the long "Hello world" that covers all that you need for a fully validated environment.

As you have no interface to interact with the bundle service yet, the testing is done as part of the bundle startup in the bundle activator code. This is later removed when shell commands are implemented for the application in Chapter 8,

The next step is to learn how to interact with other bundles in the framework. In Chapter 7, you will implement the bookshelf service, which constitutes the business layer. Then in Chapter 8, you will add the shell commands of the presentation layer.

The end of Chapter 7 is a milestone in the case study. By that point, you would have covered most of the OSGi core specification material that's in scope for this book.

By the end of Chapter 8, you would be ready to move to more advanced concepts. In Chapter 9, dependency injection is introduced with iPOJO. This adds a layer of separation between our bundles and the framework.

The last part of the book goes into the graphical interface world. It deals with building a simple servlet in Chapter 11, while introducing the OSGi Http Service and its Felix implementation.

In Chapter 13, you will learn about OSGi Web Containers, which allow the deployment of Web Application Bundles (WABs) and Web Archives (WARs) and look at the Pax Web services to provide this functionality.

You will also cover a quick tour of the Felix Web Management Console in Chapter 12, which provides a graphical management interface to the Felix framework and some of its common services. We will also look at the iPOJO Web Console Plugins service.

The last chapter, Chapter 14, Pitfalls and Troubleshooting looks into some of the common pitfalls while developing bundles and ways to troubleshoot and resolve them.

For reference, Appendix A guides you through the use of some of the available tools that would simplify the development process. We will look at how to use Eclipse, an Integrated Development Environment (IDE), along with Maven, to develop and debug bundles on the Felix framework. We will cover how to connect to a remote Felix instance as well as how to embed a Felix instance into Eclipse.

Finally, Appendix B will give you a few leads on additional interesting topics that you may choose to follow after having completed this case study.

But before we get started, let's lay down the naming conventions that will be used for the bundle projects.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.144.17.128